Date format change

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

Date format change

jamesburn
Hi

How does one go about changing the date format in ServiceMix (I'm using 5.1.1)?

I changed the system (Centos 6.5) clock from BST to UTC and want ServiceMix to work with UTC going forwards.

However, ServiceMix still returns its logs in BST. I've restarted the system and and looked through the <SM>/etc setup files, but the logs are still in BST.

I'm guessing ServiceMix gets the date format from the OS when initially started, but how can I change this going forwards.

Cheers

James

Reply | Threaded
Open this post in threaded view
|

Re: Date format change

Łukasz Dywicki
Hey,
In etc/system.properties you need this option:

karaf.override.user.timezone=UTC

Cheers,
Lukasz


2014-09-04 14:11 GMT+02:00 BURN, James <[hidden email]>:

> Hi
>
> How does one go about changing the date format in ServiceMix (I'm using
> 5.1.1)?
>
> I changed the system (Centos 6.5) clock from BST to UTC and want
> ServiceMix to work with UTC going forwards.
>
> However, ServiceMix still returns its logs in BST. I've restarted the
> system and and looked through the <SM>/etc setup files, but the logs are
> still in BST.
>
> I'm guessing ServiceMix gets the date format from the OS when initially
> started, but how can I change this going forwards.
>
> Cheers
>
> James
>
>
Reply | Threaded
Open this post in threaded view
|

RE: Date format change

jamesburn
Thanks Lukasz. I'll have a go with that.
I'm rather puzzled why there isn't already a line which says

XXX.user.timezone=BST

anywhere at the moment though.

James

-----Original Message-----
From: Łukasz Dywicki [mailto:[hidden email]]
Sent: 04 September 2014 15:35
To: [hidden email]
Subject: Re: Date format change

Hey,
In etc/system.properties you need this option:

karaf.override.user.timezone=UTC

Cheers,
Lukasz


2014-09-04 14:11 GMT+02:00 BURN, James <[hidden email]>:

> Hi
>
> How does one go about changing the date format in ServiceMix (I'm
> using 5.1.1)?
>
> I changed the system (Centos 6.5) clock from BST to UTC and want
> ServiceMix to work with UTC going forwards.
>
> However, ServiceMix still returns its logs in BST. I've restarted the
> system and and looked through the <SM>/etc setup files, but the logs
> are still in BST.
>
> I'm guessing ServiceMix gets the date format from the OS when
> initially started, but how can I change this going forwards.
>
> Cheers
>
> James
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Date format change

Gert Vanthienen
Administrator
L.S.,


The karaf.override. prefix is used to override the default system
properties - in this case, you're overriding the default value of the
user.timezone Java system property. You're right that it would be good
if we would document this feature in the system.properties file or on
the website - I raised
https://issues.apache.org/jira/browse/KARAF-3208 to get this addressed
for a future Karaf release.


Regards,

Gert Vanthienen


On Fri, Sep 5, 2014 at 1:47 PM, BURN, James <[hidden email]> wrote:

> Thanks Lukasz. I'll have a go with that.
> I'm rather puzzled why there isn't already a line which says
>
> XXX.user.timezone=BST
>
> anywhere at the moment though.
>
> James
>
> -----Original Message-----
> From: Łukasz Dywicki [mailto:[hidden email]]
> Sent: 04 September 2014 15:35
> To: [hidden email]
> Subject: Re: Date format change
>
> Hey,
> In etc/system.properties you need this option:
>
> karaf.override.user.timezone=UTC
>
> Cheers,
> Lukasz
>
>
> 2014-09-04 14:11 GMT+02:00 BURN, James <[hidden email]>:
>
>> Hi
>>
>> How does one go about changing the date format in ServiceMix (I'm
>> using 5.1.1)?
>>
>> I changed the system (Centos 6.5) clock from BST to UTC and want
>> ServiceMix to work with UTC going forwards.
>>
>> However, ServiceMix still returns its logs in BST. I've restarted the
>> system and and looked through the <SM>/etc setup files, but the logs
>> are still in BST.
>>
>> I'm guessing ServiceMix gets the date format from the OS when
>> initially started, but how can I change this going forwards.
>>
>> Cheers
>>
>> James
>>
>>
Regards,

Gert Vanthienen
------------------------
Open Source SOA: http://fusesource.com
Blog: http://gertvanthienen.blogspot.com/
Reply | Threaded
Open this post in threaded view
|

Re: Date format change

Jean-Baptiste Onofré
Good point guys, indeed, the documentation is missing about that ;)

We will add that ;)

Regards
JB

On 09/05/2014 10:27 PM, Gert Vanthienen wrote:

> L.S.,
>
>
> The karaf.override. prefix is used to override the default system
> properties - in this case, you're overriding the default value of the
> user.timezone Java system property. You're right that it would be good
> if we would document this feature in the system.properties file or on
> the website - I raised
> https://issues.apache.org/jira/browse/KARAF-3208 to get this addressed
> for a future Karaf release.
>
>
> Regards,
>
> Gert Vanthienen
>
>
> On Fri, Sep 5, 2014 at 1:47 PM, BURN, James <[hidden email]> wrote:
>> Thanks Lukasz. I'll have a go with that.
>> I'm rather puzzled why there isn't already a line which says
>>
>> XXX.user.timezone=BST
>>
>> anywhere at the moment though.
>>
>> James
>>
>> -----Original Message-----
>> From: Łukasz Dywicki [mailto:[hidden email]]
>> Sent: 04 September 2014 15:35
>> To: [hidden email]
>> Subject: Re: Date format change
>>
>> Hey,
>> In etc/system.properties you need this option:
>>
>> karaf.override.user.timezone=UTC
>>
>> Cheers,
>> Lukasz
>>
>>
>> 2014-09-04 14:11 GMT+02:00 BURN, James <[hidden email]>:
>>
>>> Hi
>>>
>>> How does one go about changing the date format in ServiceMix (I'm
>>> using 5.1.1)?
>>>
>>> I changed the system (Centos 6.5) clock from BST to UTC and want
>>> ServiceMix to work with UTC going forwards.
>>>
>>> However, ServiceMix still returns its logs in BST. I've restarted the
>>> system and and looked through the <SM>/etc setup files, but the logs
>>> are still in BST.
>>>
>>> I'm guessing ServiceMix gets the date format from the OS when
>>> initially started, but how can I change this going forwards.
>>>
>>> Cheers
>>>
>>> James
>>>
>>>

--
Jean-Baptiste Onofré
[hidden email]
http://blog.nanthrax.net
Talend - http://www.talend.com
Reply | Threaded
Open this post in threaded view
|

RE: Date format change

jamesburn
In reply to this post by Gert Vanthienen
Many thanks for the clarification Gert.

James

-----Original Message-----
From: Gert Vanthienen [mailto:[hidden email]]
Sent: 05 September 2014 21:27
To: [hidden email]
Subject: Re: Date format change

L.S.,


The karaf.override. prefix is used to override the default system properties - in this case, you're overriding the default value of the user.timezone Java system property. You're right that it would be good if we would document this feature in the system.properties file or on the website - I raised
https://issues.apache.org/jira/browse/KARAF-3208 to get this addressed for a future Karaf release.


Regards,

Gert Vanthienen


On Fri, Sep 5, 2014 at 1:47 PM, BURN, James <[hidden email]> wrote:

> Thanks Lukasz. I'll have a go with that.
> I'm rather puzzled why there isn't already a line which says
>
> XXX.user.timezone=BST
>
> anywhere at the moment though.
>
> James
>
> -----Original Message-----
> From: Łukasz Dywicki [mailto:[hidden email]]
> Sent: 04 September 2014 15:35
> To: [hidden email]
> Subject: Re: Date format change
>
> Hey,
> In etc/system.properties you need this option:
>
> karaf.override.user.timezone=UTC
>
> Cheers,
> Lukasz
>
>
> 2014-09-04 14:11 GMT+02:00 BURN, James <[hidden email]>:
>
>> Hi
>>
>> How does one go about changing the date format in ServiceMix (I'm
>> using 5.1.1)?
>>
>> I changed the system (Centos 6.5) clock from BST to UTC and want
>> ServiceMix to work with UTC going forwards.
>>
>> However, ServiceMix still returns its logs in BST. I've restarted the
>> system and and looked through the <SM>/etc setup files, but the logs
>> are still in BST.
>>
>> I'm guessing ServiceMix gets the date format from the OS when
>> initially started, but how can I change this going forwards.
>>
>> Cheers
>>
>> James
>>
>>
Reply | Threaded
Open this post in threaded view
|

RE: Date format change

jamesburn
Hmm. Not quite there yet...

I added karaf.override.user.timezone=UTC to etc/system.properties and restarted ServiceMix but still got date in BST.

This was using the wrapper to run ServiceMix as a service.

When I start SM directly from the command line date is now in UTC.

So I re-ran the wrapper setup feature from
http://servicemix.apache.org/docs/5.x/users-guide/wrapper.html

by removing the files wrapper created then doing
karaf@root>wrapper:install -s AUTO_START -n KARAF -d Karaf -D "Karaf Service"

but when I start the ServiceMix service from
$ service KARAF-service start
the date is still in BST.

It would appear that wrapper gets and overrides the timezone from somewhere else.

Any thoughts?

James




-----Original Message-----
From: BURN, James [mailto:[hidden email]]
Sent: 08 September 2014 10:20
To: [hidden email]
Subject: RE: Date format change

Many thanks for the clarification Gert.

James

-----Original Message-----
From: Gert Vanthienen [mailto:[hidden email]]
Sent: 05 September 2014 21:27
To: [hidden email]
Subject: Re: Date format change

L.S.,


The karaf.override. prefix is used to override the default system properties - in this case, you're overriding the default value of the user.timezone Java system property. You're right that it would be good if we would document this feature in the system.properties file or on the website - I raised
https://issues.apache.org/jira/browse/KARAF-3208 to get this addressed for a future Karaf release.


Regards,

Gert Vanthienen


On Fri, Sep 5, 2014 at 1:47 PM, BURN, James <[hidden email]> wrote:

> Thanks Lukasz. I'll have a go with that.
> I'm rather puzzled why there isn't already a line which says
>
> XXX.user.timezone=BST
>
> anywhere at the moment though.
>
> James
>
> -----Original Message-----
> From: Łukasz Dywicki [mailto:[hidden email]]
> Sent: 04 September 2014 15:35
> To: [hidden email]
> Subject: Re: Date format change
>
> Hey,
> In etc/system.properties you need this option:
>
> karaf.override.user.timezone=UTC
>
> Cheers,
> Lukasz
>
>
> 2014-09-04 14:11 GMT+02:00 BURN, James <[hidden email]>:
>
>> Hi
>>
>> How does one go about changing the date format in ServiceMix (I'm
>> using 5.1.1)?
>>
>> I changed the system (Centos 6.5) clock from BST to UTC and want
>> ServiceMix to work with UTC going forwards.
>>
>> However, ServiceMix still returns its logs in BST. I've restarted the
>> system and and looked through the <SM>/etc setup files, but the logs
>> are still in BST.
>>
>> I'm guessing ServiceMix gets the date format from the OS when
>> initially started, but how can I change this going forwards.
>>
>> Cheers
>>
>> James
>>
>>
Reply | Threaded
Open this post in threaded view
|

RE: Date format change

jamesburn
Hello

As this seems to be entwined with the Karaf wrapper component, should I bounce this query to the Karaf user list?

James

-----Original Message-----
From: BURN, James [mailto:[hidden email]]
Sent: 08 September 2014 11:34
To: [hidden email]
Subject: RE: Date format change

Hmm. Not quite there yet...

I added karaf.override.user.timezone=UTC to etc/system.properties and restarted ServiceMix but still got date in BST.

This was using the wrapper to run ServiceMix as a service.

When I start SM directly from the command line date is now in UTC.

So I re-ran the wrapper setup feature from http://servicemix.apache.org/docs/5.x/users-guide/wrapper.html

by removing the files wrapper created then doing karaf@root>wrapper:install -s AUTO_START -n KARAF -d Karaf -D "Karaf Service"

but when I start the ServiceMix service from $ service KARAF-service start the date is still in BST.

It would appear that wrapper gets and overrides the timezone from somewhere else.

Any thoughts?

James




-----Original Message-----
From: BURN, James [mailto:[hidden email]]
Sent: 08 September 2014 10:20
To: [hidden email]
Subject: RE: Date format change

Many thanks for the clarification Gert.

James

-----Original Message-----
From: Gert Vanthienen [mailto:[hidden email]]
Sent: 05 September 2014 21:27
To: [hidden email]
Subject: Re: Date format change

L.S.,


The karaf.override. prefix is used to override the default system properties - in this case, you're overriding the default value of the user.timezone Java system property. You're right that it would be good if we would document this feature in the system.properties file or on the website - I raised
https://issues.apache.org/jira/browse/KARAF-3208 to get this addressed for a future Karaf release.


Regards,

Gert Vanthienen


On Fri, Sep 5, 2014 at 1:47 PM, BURN, James <[hidden email]> wrote:

> Thanks Lukasz. I'll have a go with that.
> I'm rather puzzled why there isn't already a line which says
>
> XXX.user.timezone=BST
>
> anywhere at the moment though.
>
> James
>
> -----Original Message-----
> From: Łukasz Dywicki [mailto:[hidden email]]
> Sent: 04 September 2014 15:35
> To: [hidden email]
> Subject: Re: Date format change
>
> Hey,
> In etc/system.properties you need this option:
>
> karaf.override.user.timezone=UTC
>
> Cheers,
> Lukasz
>
>
> 2014-09-04 14:11 GMT+02:00 BURN, James <[hidden email]>:
>
>> Hi
>>
>> How does one go about changing the date format in ServiceMix (I'm
>> using 5.1.1)?
>>
>> I changed the system (Centos 6.5) clock from BST to UTC and want
>> ServiceMix to work with UTC going forwards.
>>
>> However, ServiceMix still returns its logs in BST. I've restarted the
>> system and and looked through the <SM>/etc setup files, but the logs
>> are still in BST.
>>
>> I'm guessing ServiceMix gets the date format from the OS when
>> initially started, but how can I change this going forwards.
>>
>> Cheers
>>
>> James
>>
>>
Reply | Threaded
Open this post in threaded view
|

Re: Date format change

Raúl Kripalani
There should be a wrapper .conf file inside $SMX_HOME/etc. This is the
Tanuki wrapper configuration file.

You can add a system property to boot by adding a line like this:

    wrapper.java.additional.<n>=-Duser.timezone=UTC

where <n> is substituted with a sequential number, as explained in [1].

[1]
http://wrapper.tanukisoftware.com/doc/english/prop-java-additional-n.html

Regards,

*Raúl Kripalani*
Apache Camel PMC Member & Committer | Enterprise Architect, Open Source
Integration specialist
http://about.me/raulkripalani | http://www.linkedin.com/in/raulkripalani
http://blog.raulkr.net | twitter: @raulvk

On Wed, Sep 10, 2014 at 11:43 AM, BURN, James <[hidden email]> wrote:

> Hello
>
> As this seems to be entwined with the Karaf wrapper component, should I
> bounce this query to the Karaf user list?
>
> James
>
> -----Original Message-----
> From: BURN, James [mailto:[hidden email]]
> Sent: 08 September 2014 11:34
> To: [hidden email]
> Subject: RE: Date format change
>
> Hmm. Not quite there yet...
>
> I added karaf.override.user.timezone=UTC to etc/system.properties and
> restarted ServiceMix but still got date in BST.
>
> This was using the wrapper to run ServiceMix as a service.
>
> When I start SM directly from the command line date is now in UTC.
>
> So I re-ran the wrapper setup feature from
> http://servicemix.apache.org/docs/5.x/users-guide/wrapper.html
>
> by removing the files wrapper created then doing karaf@root>wrapper:install
> -s AUTO_START -n KARAF -d Karaf -D "Karaf Service"
>
> but when I start the ServiceMix service from $ service KARAF-service start
> the date is still in BST.
>
> It would appear that wrapper gets and overrides the timezone from
> somewhere else.
>
> Any thoughts?
>
> James
>
>
>
>
> -----Original Message-----
> From: BURN, James [mailto:[hidden email]]
> Sent: 08 September 2014 10:20
> To: [hidden email]
> Subject: RE: Date format change
>
> Many thanks for the clarification Gert.
>
> James
>
> -----Original Message-----
> From: Gert Vanthienen [mailto:[hidden email]]
> Sent: 05 September 2014 21:27
> To: [hidden email]
> Subject: Re: Date format change
>
> L.S.,
>
>
> The karaf.override. prefix is used to override the default system
> properties - in this case, you're overriding the default value of the
> user.timezone Java system property. You're right that it would be good if
> we would document this feature in the system.properties file or on the
> website - I raised
> https://issues.apache.org/jira/browse/KARAF-3208 to get this addressed
> for a future Karaf release.
>
>
> Regards,
>
> Gert Vanthienen
>
>
> On Fri, Sep 5, 2014 at 1:47 PM, BURN, James <[hidden email]> wrote:
> > Thanks Lukasz. I'll have a go with that.
> > I'm rather puzzled why there isn't already a line which says
> >
> > XXX.user.timezone=BST
> >
> > anywhere at the moment though.
> >
> > James
> >
> > -----Original Message-----
> > From: Łukasz Dywicki [mailto:[hidden email]]
> > Sent: 04 September 2014 15:35
> > To: [hidden email]
> > Subject: Re: Date format change
> >
> > Hey,
> > In etc/system.properties you need this option:
> >
> > karaf.override.user.timezone=UTC
> >
> > Cheers,
> > Lukasz
> >
> >
> > 2014-09-04 14:11 GMT+02:00 BURN, James <[hidden email]>:
> >
> >> Hi
> >>
> >> How does one go about changing the date format in ServiceMix (I'm
> >> using 5.1.1)?
> >>
> >> I changed the system (Centos 6.5) clock from BST to UTC and want
> >> ServiceMix to work with UTC going forwards.
> >>
> >> However, ServiceMix still returns its logs in BST. I've restarted the
> >> system and and looked through the <SM>/etc setup files, but the logs
> >> are still in BST.
> >>
> >> I'm guessing ServiceMix gets the date format from the OS when
> >> initially started, but how can I change this going forwards.
> >>
> >> Cheers
> >>
> >> James
> >>
> >>
>
Reply | Threaded
Open this post in threaded view
|

RE: Date format change

jamesburn
Thanks Raúl

That works a treat.

Cheers

James



-----Original Message-----
From: Raul Kripalani [mailto:[hidden email]]
Sent: 10 September 2014 12:29
To: [hidden email]
Subject: Re: Date format change

There should be a wrapper .conf file inside $SMX_HOME/etc. This is the Tanuki wrapper configuration file.

You can add a system property to boot by adding a line like this:

    wrapper.java.additional.<n>=-Duser.timezone=UTC

where <n> is substituted with a sequential number, as explained in [1].

[1]
http://wrapper.tanukisoftware.com/doc/english/prop-java-additional-n.html

Regards,

*Raúl Kripalani*
Apache Camel PMC Member & Committer | Enterprise Architect, Open Source Integration specialist http://about.me/raulkripalani | http://www.linkedin.com/in/raulkripalani
http://blog.raulkr.net | twitter: @raulvk

On Wed, Sep 10, 2014 at 11:43 AM, BURN, James <[hidden email]> wrote:

> Hello
>
> As this seems to be entwined with the Karaf wrapper component, should
> I bounce this query to the Karaf user list?
>
> James
>
> -----Original Message-----
> From: BURN, James [mailto:[hidden email]]
> Sent: 08 September 2014 11:34
> To: [hidden email]
> Subject: RE: Date format change
>
> Hmm. Not quite there yet...
>
> I added karaf.override.user.timezone=UTC to etc/system.properties and
> restarted ServiceMix but still got date in BST.
>
> This was using the wrapper to run ServiceMix as a service.
>
> When I start SM directly from the command line date is now in UTC.
>
> So I re-ran the wrapper setup feature from
> http://servicemix.apache.org/docs/5.x/users-guide/wrapper.html
>
> by removing the files wrapper created then doing
> karaf@root>wrapper:install -s AUTO_START -n KARAF -d Karaf -D "Karaf Service"
>
> but when I start the ServiceMix service from $ service KARAF-service
> start the date is still in BST.
>
> It would appear that wrapper gets and overrides the timezone from
> somewhere else.
>
> Any thoughts?
>
> James
>
>
>
>
> -----Original Message-----
> From: BURN, James [mailto:[hidden email]]
> Sent: 08 September 2014 10:20
> To: [hidden email]
> Subject: RE: Date format change
>
> Many thanks for the clarification Gert.
>
> James
>
> -----Original Message-----
> From: Gert Vanthienen [mailto:[hidden email]]
> Sent: 05 September 2014 21:27
> To: [hidden email]
> Subject: Re: Date format change
>
> L.S.,
>
>
> The karaf.override. prefix is used to override the default system
> properties - in this case, you're overriding the default value of the
> user.timezone Java system property. You're right that it would be good
> if we would document this feature in the system.properties file or on
> the website - I raised
> https://issues.apache.org/jira/browse/KARAF-3208 to get this addressed
> for a future Karaf release.
>
>
> Regards,
>
> Gert Vanthienen
>
>
> On Fri, Sep 5, 2014 at 1:47 PM, BURN, James <[hidden email]> wrote:
> > Thanks Lukasz. I'll have a go with that.
> > I'm rather puzzled why there isn't already a line which says
> >
> > XXX.user.timezone=BST
> >
> > anywhere at the moment though.
> >
> > James
> >
> > -----Original Message-----
> > From: Łukasz Dywicki [mailto:[hidden email]]
> > Sent: 04 September 2014 15:35
> > To: [hidden email]
> > Subject: Re: Date format change
> >
> > Hey,
> > In etc/system.properties you need this option:
> >
> > karaf.override.user.timezone=UTC
> >
> > Cheers,
> > Lukasz
> >
> >
> > 2014-09-04 14:11 GMT+02:00 BURN, James <[hidden email]>:
> >
> >> Hi
> >>
> >> How does one go about changing the date format in ServiceMix (I'm
> >> using 5.1.1)?
> >>
> >> I changed the system (Centos 6.5) clock from BST to UTC and want
> >> ServiceMix to work with UTC going forwards.
> >>
> >> However, ServiceMix still returns its logs in BST. I've restarted
> >> the system and and looked through the <SM>/etc setup files, but the
> >> logs are still in BST.
> >>
> >> I'm guessing ServiceMix gets the date format from the OS when
> >> initially started, but how can I change this going forwards.
> >>
> >> Cheers
> >>
> >> James
> >>
> >>
>