Publish time on the Blog.CategoryRss

Hey everyone,

I’m trying to read the blog rss (or notification rss) feed with power automate so I can post Adaptive Cards message ( See the Designer if you want to see about the possibilities) in teams (or mail specific users based on the category) when items are added to a blog. I estimate this functionality will improve adaptation and help the actual reading of information (opposed to just mailing updates all the time) through xwiki.

Testing is already proving some usable results! I’m using the Nieuws/Categories/Algemeen?xpage=plain&sheet=Blog.CategoryRss feed with basic authentication

https://USERNAME:PW@URLHERE

My only issue currently is that the rss is producing a publishdate in 12 hour notation

image

so an item posted today at 13:42 is showing as <dc:date>2023-12-20T01:42:26+01:00</dc:date> :

</items>
</channel>
<item rdf:about="https://URL.nl/Nieuws/RSS%20Test?language=nl">
<title>RSS Test</title>
<link>https://URL.nl/Nieuws/RSS%20Test?language=nl</link>
<description>&#60;p&#62;samenvatting&#60;/p&#62;</description>
<dc:subject>&#123;&#123;html clean=&#34;false&#34; wiki=&#34;false&#34;}}Algemeen &#38;gt; Mededelingen&#60;br /&#62;Disciplines &#38;gt; Automatisering&#123;&#123;/html}}</dc:subject>
<dc:date>2023-12-20T01:42:26+01:00</dc:date>
<dc:creator>Me</dc:creator>
<xwiki:image type="image/gif" length="818244">https://URL/download/Nieuws/RSS%20Test/boos_typen.gif?rev=1.1</xwiki:image>
</item>

Which means the trigger and time handling of power automate gets wonky, now I’ve looked all over but can’t find where to change this to a 24 hour notation!

I have an alternative using the notification macro which uses the admin panels time for its publishdate notation;

image

which is also great for other similiar setups I plan to implement) but the fact that the blogrss generates various properties as subject / image out of the box is appealing so I’d like to use it!

Does anyone know how I can adjust the Blog.CategoryRss Publishdate RSS?

Thank you in advance for any trouble to be taken!

So the code is modifiable in the Blog.RssCode wiki page, see Macros for displaying Blog-related RSS feeds

The default formatter is defined at Macros for displaying Blog-related RSS feeds & Macros for displaying Blog-related RSS feeds

The RSS 1.0 specification doesn’t define a publish date, see http://purl.org/rss/1.0/spec

However, this was added by the Dublin Core extension, see RDF Site Summary 1.0 Modules: Dublin Core. It points to Date and Time Formats which defines the format for the date/time.

Indeed it does say to use YYYY-MM-DDThh:mm:ssTZD:

hh = two digits of hour (00 through 23) (am/pm NOT allowed)

We use yyyy-MM-dd'T'hh:mm:ssZZ but in Java hh means 0-12 hour format (see Java SimpleDateFormat - Java Date Format | DigitalOcean), and thus it seems that the Blog app is wrong and it should use HH, i.e. yyyy-MM-dd'T'HH:mm:ssZZ

Could you open an issue at Blog Application - XWiki.org JIRA ?

PS: We’ll need to move to RSS 2.0 at some point (which also uses 0-23 hours, see RFC 822 - STANDARD FOR THE FORMAT OF ARPA INTERNET TEXT MESSAGES ). Search for pubDate at RSS 2.0 Specification (Current)

1 Like

Coming out of the holiday spirits to Thank you @vmassol , I’ll add the issue when I’m online again! ( I’ll be sure to update this post)

Xwiki (and your contributions to it) have given me a lot of energy in the professional sphere in 2023.
Wishing you and the xwiki team the best of years :fireworks: for 2024 from a cold and rainy Netherlands.

1 Like

Well that holiday just flew by (Like they usually do :roll_eyes:)

I made a jira ticket on [BLOG-214] Blog.CategoryRss feed generates RSS publish dates in 12-hour notation - XWiki.org JIRA

A bit of a continuance on this… I was thinking of writing out my setup after it’s deployed (a how-to of sorts) … is there a particular part of the forums or some other place such write-ups can go?