• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Knute Snortum
  • Bear Bibeault
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Ganesh Patekar
Bartenders:
  • Frits Walraven
  • Carey Brown
  • Tim Holloway

Difference in TimeZone between JAX-RPC and JAX-WS

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm migrating a web-service from jax-rpc to jax-ws (for Websphere AppServer), where I observed a following difference for a field with calendar Datatype

JAX-RPC :

<CalendarValue> 2019-01-21T09:15:14.633ZDifference in TimeZone between JAX-RPC and JAX-WS </CalendarValue>     (UTC)

JAX-WS :

<CalendarValue> 2019-01-21T16:12:37+07:00 </CalendarValue>  (Server-TimeZone)

I observed that when jax-b is used with JAX-WS, the Calendar Datatype is converted to XMLGregorianCalendar which is expected in jax-ws. But a difference in time-zone is observed with this migration where the time-zone was not normalized to UTC.

Also following are the references that says XSD 1.1 dataTime datatypes retain the Server time-zone information unlike converting to UTC in XSD 1.0.
1.https://www.w3.org/TR/xmlschema11-2/#equality
2.https://www.w3.org/TR/xmlschema-2/#dateTime

I'm trying to generate a wsdl using Websphere specific wsgen tool which has the xsd version as 1.0 . I'm curious to know why the XSD 1.0 dateTime datatype retaining the server time-zone.

In-order to verify whether Websphere tools support XSD 1.1 ,I've tried to compile a schema containing xsd 1.1 datatypes which resulted in an error. https://blogs.oracle.com/rammenon/xml-schema-11-ndash-what-you-need-to-know

Can someone suggest on this? Is this difference specific to Websphere?
 
Sheriff
Posts: 21759
102
Eclipse IDE Spring VI Editor Chrome Java Ubuntu Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the Ranch!

I'm wondering if this really matters. These two times are the same, they are just represented differently. 2019-01-21T09:15:14.633Z is the same as 2019-01-21T09:15:14.633+00:00 which is the same as 2019-01-21T16:15:14.633+07:00. Any well functioning client will treat the two as the same value.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!