This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Timezone of the OIM Web Portal

Dear Community,

can someone tell me how the timezone of a user session is determined?

I have the problem that columns template is not calculating correct values if the trigger comes from a change made in the web portal.

If the same person makes that change in the ObjectBrowser or Manager the calculation is fine.

So I think that the Web Portal uses the wrong timezone in the users session.

Inside the users data Germany is selected as country (Person.UID_DialogCountry)

and the country is is correctly linked to the correct timezone "Berlin" (DialogCountryHasTimeZone)

  • Hi Florian<

    What is the version?  What change is being made?  Can you provide an example?

    Thanks

  • The Version is 8.02.

    The Attribute bering changes is Person.ExitDate with just a Date ie. 2018-11-23

    This Attribute triggers a Template on Person.DateLastWorked that adds a day and subtracts a minute resulting in 2018-11-23 23:59.

  • Hi Florian,

    Check the web application logs and look for entries like this one to determine if the application calculates the correct time zone.

    2018-11-19 16:29:53.0044 DEBUG (    WebLog of32tnuhmluzotrzdcfa1qjf) : Got time zone info 2015,3,29,60,120;2015,10,25,120,60;. 
    2018-11-19 16:29:53.1503 DEBUG (    WebLog of32tnuhmluzotrzdcfa1qjf) : Found matching zone: (UTC+01:00) Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna (W. Europe Standard Time) 
    
    

    Hope this helps

    Hanno

  • The main part of the template does the following:

    Value = $ExitDate:Date$.Date.AddMinutes(-1).AddDays(1)

    If I change the ExirtDate in the Manager or ObjectBrowser the resulting Database-Value is "2018-11-23 22:59:00" (The correct UTC value) Display in the Tools is "2018-11-23 23:59:00"

    If I make that change in the Web-Portal (Same User) the resulting Database-Value is "2018-11-23 23:59:00" (Not correct) and the Display in all Tools is "2018-11-24 00:59:00"

    My theory is that in the Fat-Clients the computers timezone is used to calculate values in column templates
    and in web maybe the users time-zone is used and fallback is utc. So what attribute is used to get the users timezone?

  • Sadly our projects webadmin is not available this week and I'm unsure how to get the dubugging information logged.
    I have tried to publish the web-project in debug-mode. But that didn't help to get any debug information in the IIS Log.
    In the web.config I also can't find an attribute to control the loglevel.
    Is debugging information for the webportal also controlled by the globallog.config?

  • Hi Florian,

    Locate the nlog.config file in the web application folder. There should be a line like this one:

    <logger name="*" minlevel="Warn" writeTo="logFile" />

    If you set the minlevel to "Debug" then you will get debug-level log messages.

    HTH

    Hanno

  • Ok i have some some log entries now:

    ...
    2018-12-04 09:26:52.9300 DEBUG ( ObjectLog nwsr4eopsivvuhatxme1zlaa) : 	Check and execute column format Enforce UTC date with 12/31/2018 7:26:08 AM 
    2018-12-04 09:26:52.9300 DEBUG ( ObjectLog nwsr4eopsivvuhatxme1zlaa) : 	Person.ExitDate = 12/31/2018 7:26:08 AM 
    ...
    2018-12-04 09:26:52.9300 DEBUG ( ObjectLog nwsr4eopsivvuhatxme1zlaa) : 	Executing template for Person.ExitDate. 
    2018-12-04 09:26:52.9300 DEBUG ( ObjectLog nwsr4eopsivvuhatxme1zlaa) : 		Value has not changed. 
    2018-12-04 09:26:52.9300 DEBUG ( ObjectLog nwsr4eopsivvuhatxme1zlaa) : 	Executing template for Person.DateLastWorked. 
    2018-12-04 09:26:52.9300 DEBUG ( ObjectLog nwsr4eopsivvuhatxme1zlaa) : 		Result: 12/31/2018 9:59:00 PM 
    ...
    2018-12-04 09:26:52.9456 DEBUG ( ObjectLog nwsr4eopsivvuhatxme1zlaa) : 	Customizer SetValueAsync 
    2018-12-04 09:26:52.9456 DEBUG ( ObjectLog nwsr4eopsivvuhatxme1zlaa) : 		Action on DateLastWorked MinLen depends on ExitDate 
    2018-12-04 09:26:52.9456 DEBUG ( ObjectLog nwsr4eopsivvuhatxme1zlaa) : 		Result: DateLastWorked MinLen = 1 
    ...
    2018-12-04 09:26:52.9456 DEBUG ( ObjectLog nwsr4eopsivvuhatxme1zlaa) : 	Check and execute column format Enforce UTC date with 12/31/2018 9:59:00 PM 
    2018-12-04 09:26:52.9456 DEBUG ( ObjectLog nwsr4eopsivvuhatxme1zlaa) : 	Person.DateLastWorked = 12/31/2018 9:59:00 PM 
    2018-12-04 09:26:52.9456 DEBUG ( ObjectLog nwsr4eopsivvuhatxme1zlaa) : 	Executing template for Person.DateLastWorked. 
    2018-12-04 09:26:52.9456 DEBUG ( ObjectLog nwsr4eopsivvuhatxme1zlaa) : 		Value has not changed.
    ...

    What's interesting is the "Enforce UTC date" part. I dont unterstand what is enforcing utc here.

  • Hello Florian,

    the new or existing value for "Last working day" in your local datetime-format will be converted into UTC to get a standardized datetime which will be in your example saved in the database at Person.DateLastWorked .

    Did you had look in the log of the webapplication where the time zone was determined? Is everything as expected?
    Hanno has given an example how a "Got time zone info" could be logged.

    cheers
    Michael