Hi Sagara,

I understand that according to specs this is a clean approach.
Unfortunatelly no major database vendor does implement java.util.Calendar,
MySQL, Oracle and Co. they just cut the timezone info if you pass a
java.util.Calendar object to the database. Ugly ... but true.
I think JDBC does map java.util.Date and java.util.Calendar to the same
types:
http://openjpa.apache.org/builds/1.0.2/apache-openjpa-1.0.2/docs/manual/jpa_overview_mapping_field.html#jpa_overview_mapping_temporal
There is just no TemporalType.Calendar
or anything that relates to timezone aware Temporal types.

So there is no additional value in using java.util.Calendar compared to
java.util.Date practically. I would even say its kind of inconsistent
implementing java.util.Calendar while knowing this java.util.Calendar can
NEVER contain any timezone info as soon as it is loaded from a database.

However we will investigate what kind of practical solution there is.

Sebastian

2012/3/4 Sagara Gunathunga <sagara.gunathu...@gmail.com>

>
>
> On Sun, Mar 4, 2012 at 6:41 PM, seba.wag...@gmail.com <
> seba.wag...@gmail.com> wrote:
>
>> I have updated to Version 1.7.0 Snapshot and it works now :)
>> We will do some more test ...
>>
>> BTW: Starting with version 1.6 (or 1.5) java.util.Date gets mapped as
>> yyyy-mm-dd (in previous versions of Axis2 it was yyyy-mm-dd hh:mm:ss).
>> Is there a way of defining an output filter or something like that to
>> change the format Axis2 uses for rendering java.util.Date?
>>
>
>  In Axis2 java.util.Date is map to XSD : date type that does not contains
> hour, minutes or seconds portions. According to the spec[1]
>
>  "date uses the date/timeSevenPropertyModel, with *·hour·*, *·minute·*,
> and *·second·* required to be *absent*.  *·timezoneOffset·* remains ·
> optional·."
>
>  you may use Java Calendar type that maps to xsd:dateTime
>
> [1] - http://www.w3.org/TR/xmlschema11-2/#date
>
> Thanks !
>
>
>
>> Thanks!
>> Sebastian
>>
>>
>> 2012/3/4 Sagara Gunathunga <sagara.gunathu...@gmail.com>
>>
>>> Hi Sebastian,
>>>
>>> There were number of issues related to List and Map processing / schema
>>> generation. Most of them have been fixed in the trunk targeting 1.7.0
>>> release. Could you test with 1.7.0-SNAPSHOT version and let us know your
>>> results.
>>>
>>> Thanks !
>>>
>>> On Sun, Mar 4, 2012 at 12:22 AM, seba.wag...@gmail.com <
>>> seba.wag...@gmail.com> wrote:
>>>
>>>> Hi,
>>>>
>>>> we face some problems with Objects that are deeply nested in each other
>>>> and that have a List<TypeXYZ> somewhere.
>>>> Axis2 cannot find a mapping for that Class.
>>>>
>>>> WSDL generate by Axis2: http://pastebin.com/pL6D31Rz
>>>>
>>>> Have a look at the attribute:
>>>> <xs:element minOccurs="0" name="organisation_users" nillable="true"
>>>> type="xs:anyType"/>
>>>>
>>>> Why "anyType" ?
>>>>
>>>> Users.java is here:
>>>>
>>>> https://svn.apache.org/repos/asf/incubator/openmeetings/trunk/singlewebapp/src/app/org/openmeetings/app/persistence/beans/user/Users.java
>>>>
>>>> private List<Organisation_Users> organisation_users = new
>>>> ArrayList<Organisation_Users>();
>>>>
>>>> Why does Axis2 not map Organization_Users to a correct type ?
>>>> Is there a way of registering classes programmatically that Axis2 does
>>>> not find natively ?
>>>> Is there a special config in Axis2 that influences how deep nested
>>>> objects can be in Axis2 ?
>>>>
>>>> This is the Service the WSDL is generated by Axis2:
>>>>
>>>> https://svn.apache.org/repos/asf/incubator/openmeetings/trunk/singlewebapp/src/calendarservice/org/openmeetings/axis/services/CalendarWebServiceFacade.java
>>>>
>>>> This is Axis 1.6.1.
>>>>
>>>> Thanks!
>>>> Sebastian
>>>>
>>>> --
>>>> Sebastian Wagner
>>>> http://www.openmeetings.de
>>>> http://incubator.apache.org/openmeetings/
>>>> http://www.webbase-design.de
>>>> http://www.wagner-sebastian.com
>>>> seba.wag...@gmail.com
>>>>
>>>
>>>
>>>
>>> --
>>> Sagara Gunathunga
>>>
>>> Blog      - http://ssagara.blogspot.com
>>> Web      - http://people.apache.org/~sagara/
>>> LinkedIn - http://www.linkedin.com/in/ssagara
>>>
>>
>>
>>
>> --
>> Sebastian Wagner
>> http://www.openmeetings.de
>> http://incubator.apache.org/openmeetings/
>> http://www.webbase-design.de
>> http://www.wagner-sebastian.com
>> seba.wag...@gmail.com
>>
>
>
>
> --
> Sagara Gunathunga
>
> Blog      - http://ssagara.blogspot.com
> Web      - http://people.apache.org/~sagara/
> LinkedIn - http://www.linkedin.com/in/ssagara
>



-- 
Sebastian Wagner
http://www.openmeetings.de
http://incubator.apache.org/openmeetings/
http://www.webbase-design.de
http://www.wagner-sebastian.com
seba.wag...@gmail.com

Reply via email to