SaaS CMS has officially launched! Learn more now.

sheider
Apr 15, 2024
  795
(1 votes)

.Net Core Timezone ID's Windows vs Linux

Hey all,

First post here and I would like to talk about Timezone ID's and How Windows and Linux systems use different IDs.

We currently run a .NET Core site with Opti CMS and Customized Commerce (B2B Commerce) all hosted in DXC. And with our solution we had an automated process of what would be a scheduled publish of our commerce items.

We identified we had issues where our commerce items would publish early. Our investigation found that if you are using Timzezone ID's or just using the OOB TimeZoneInfo, the results you get will vary from your local development in windows to where its deployed to, in our case DXC (Linux).

With this in mind, we had to find a conversion nuget that would allow us to enter a windows timezone ID and allow it to auto convert it based on the environment it was deployed to.

https://github.com/mattjohnsonpint/TimeZoneConverter is the conversion nuget we use.

**Notes to those on .net 6+ from that Repository listed above:

.NET 6 has built-in support for IANA and Windows time zones in a cross-platform manner, somewhat reducing the need for this library. It relies on .NET's ICU integration to perform this functionality. See the .NET blog for details.

I Hope this information is useful to those of you who are working in .Net Core and are having issues with scheduled publish discrepencies.

Cheers,

Sean Heider

Apr 15, 2024

Comments

Please login to comment.
Latest blogs
Optimizely SaaS CMS Concepts and Terminologies

Whether you're a new user of Optimizely CMS or a veteran who have been through the evolution of it, the SaaS CMS is bringing some new concepts and...

Patrick Lam | Jul 15, 2024

How to have a link plugin with extra link id attribute in TinyMce

Introduce Optimizely CMS Editing is using TinyMce for editing rich-text content. We need to use this control a lot in CMS site for kind of WYSWYG...

Binh Nguyen Thi | Jul 13, 2024

Create your first demo site with Optimizely SaaS/Visual Builder

Hello everyone, We are very excited about the launch of our SaaS CMS and the new Visual Builder that comes with it. Since it is the first time you'...

Patrick Lam | Jul 11, 2024

Integrate a CMP workflow step with CMS

As you might know Optimizely has an integration where you can create and edit pages in the CMS directly from the CMP. One of the benefits of this i...

Marcus Hoffmann | Jul 10, 2024