OAI-PMH response not using localtime on responseDate

27 views
Skip to first unread message

jatnikonm

unread,
Feb 20, 2019, 11:41:29 AM2/20/19
to AtoM Users
Hi AtoM Community

I tried to request using OAI-PMH verb identify but i get responseDate not in localtime of my country

How to get responseDate to localtime when OAI-PMH request?

Thanks very much for your answer
oaiResponse.png

Dan Gillean

unread,
Feb 20, 2019, 12:20:01 PM2/20/19
to ICA-AtoM Users
Hi there, 

There are two places I would recommend looking. 

First, there is a configuration file where you can set your timezone - the file is located at apps/qubit/config/settings.yml. You will see a place where you can set the correct timezone. 

apps-qubit-config-yml.png

You can find a list of supported timezone names here: 
If you make changes, be sure to restart PHP-FPM, memcached, and clear the application cache before testing again. On Ubuntu 16.04 you could use the following commands to do so: 
  • sudo systemctl restart php7.0-fpm
  • sudo systemctl restart memcached
  • php symfony cc
If that doesn't work, there is also a place you can set a default timezone in your PHP configuration file. See this doc for instructions on how to locate the file: 
Once you find and access it, if you scroll waaaaaay down to about line 925, you will see a section called Module settings. There is a default timezone setting here. 

php-ini-timezone.png

You will need to remove the semi-colon at the beginning of the line (which currently comments out the line so it is ignored), and then add your timezone, using the same list linked above. Again, after making changes, be sure to restart PHP-FPM, memcached, and clear the application cache before testing again.

Let us know if that works! 

Dan Gillean, MAS, MLIS
AtoM Program Manager
Artefactual Systems, Inc.
604-527-2056
@accesstomemory


--
You received this message because you are subscribed to the Google Groups "AtoM Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ica-atom-user...@googlegroups.com.
To post to this group, send email to ica-ato...@googlegroups.com.
Visit this group at https://groups.google.com/group/ica-atom-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/ica-atom-users/976dbbc9-bb7d-498a-ac5e-0e9506d8235a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

jatnikonm

unread,
Feb 20, 2019, 1:25:41 PM2/20/19
to AtoM Users
I was change date.timezone on /etc/php/7.0/fpm/php.ini but the result not change



and i don't forget
  • sudo systemctl restart php7.0-fpm
  • sudo systemctl restart memcached
  • php symfony cc

Dan Gillean

unread,
Feb 20, 2019, 3:39:32 PM2/20/19
to ICA-AtoM Users
Hi again, 

Did you also make the change in apps/qubit/config/settings.yml? Because this is an AtoM configuration file, it is possible it is overriding the default PHP settings, so I would make the change in both places. Let us know if that helps. 

Cheers, 

Dan Gillean, MAS, MLIS
AtoM Program Manager
Artefactual Systems, Inc.
604-527-2056
@accesstomemory

Karl Goetz

unread,
Feb 20, 2019, 4:56:56 PM2/20/19
to ica-ato...@googlegroups.com
Please note that AtoM is behaving according to the standard which says

For all responses, the first two children of the root element are: 
  • responseDate -- a UTCdatetime indicating the time and date that the response was sent. This must be expressed in UTC.
  • request -- indicating the protocol request that generated this response.




If you proceed with changing the zone of that date you may impact on your harvesters which will likely assume UTC.

For completeness of answer:

$date is set in this XML file

It comes from getDate() here

And is populated in here

Tl;dr:
If you don’t want to use UTC you will need to edit one of the top two files to add timezone offset.


Karl.

--
You received this message because you are subscribed to the Google Groups "AtoM Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ica-atom-user...@googlegroups.com.
To post to this group, send email to ica-ato...@googlegroups.com.
Visit this group at https://groups.google.com/group/ica-atom-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/ica-atom-users/976dbbc9-bb7d-498a-ac5e-0e9506d8235a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
<oaiResponse.png>

-- 
Karl Goetz,  Senior Library Officer (Library Systems)
University of Tasmania, Private Bag 25, Hobart 7001
Available Tuesday, Wednesday, Thursday



University of Tasmania Electronic Communications Policy (December, 2014).
This email is confidential, and is for the intended recipient only. Access, disclosure, copying, distribution, or reliance on any of it by anyone outside the intended recipient organisation is prohibited and may be a criminal offence. Please delete if obtained in error and email confirmation to the sender. The views expressed in this email are not necessarily the views of the University of Tasmania, unless clearly intended otherwise.

jatnikonm

unread,
Feb 21, 2019, 9:52:58 PM2/21/19
to AtoM Users
thank you very much
Karl.

To post to this group, send email to ica-at...@googlegroups.com.

-- 
Karl Goetz,  Senior Library Officer (Library Systems)
University of Tasmania, Private Bag 25, Hobart 7001
Available Tuesday, Wednesday, Thursday

Reply all
Reply to author
Forward
0 new messages