hi,
See my comments inline

On Fri, Jul 11, 2008 at 5:38 AM, Sanjaya Karunasena <[EMAIL PROTECTED]> wrote:
> Well, I didn't mean to say the original design is bad. It just what we will
> end up if we stick to what is given by java.

is it not the idea when we use Java in the first place ?

>
> If you look at some simple design elements like;
>
> - Time, Date and Duration/Interval/Period get maps to a Date.
> - DateTime and Timestamp get maps to a Calendar.
>
> Now my domain model is gone. Can I get it back, during the reverse
> execution? I don't think so.
>
> Interestingly, your have taken data integrity very lightly :-).
Not really.

The case here is that the moment you decided to put a an XML messaging
layer in the middle you did take the risk of
losing some of your data integrity. None of the current languages (to
be safe I suppose I should say 'only a handful') can do  a lossless
type conversion from XML or to XML. The current mappings are designed
to be an optimal (in function and usability) transfer from XML
-> Java and Java -> XML. If you really want serious data integrity you
can easily switch to something like XMLBeans as the data binding
framework and (hopefully) not lose a thing. If that does not work then
you can customize and get your own bindings and Axis2 is flexible
enough to provide that.

Again I was somewhat mislead with the JDBC example earlier. ADB was
designed with XML in mind and it was meant to be an efficient XML <->
java converter. I suppose its doing fine at the moment in that regard.

>
> So, if the majority think using Axis2's extensibility to overcome this issue
> is the way to go, I will have to respect that. :-)

Well the thing is that the use case presented is an exotic one. From
the millions of people who use Axis2 how many of them would have such
a set up and how many anticipate running into a problem like that ? If
they do they can customize Axis2 and cook up their own solution while
the rest keeps cruising along. The idea of making things flexible is
exactly to give such freedom to users.

BTW I did write a detailed mail regarding my reasons to not change anything

Ajith
>
> /Sanjaya
>
>
> ----- Original Message ----
> From: Ajith Ranabahu <[EMAIL PROTECTED]>
> To: axis-dev@ws.apache.org
> Sent: Friday, July 11, 2008 12:40:15 PM
> Subject: Re: Representing a Birthday in a distributed scenario
>
> On Fri, Jul 11, 2008 at 2:59 AM, Eran Chinthaka
> <[EMAIL PROTECTED]> wrote:
>> Hi,
>>
>> On Thu, Jul 10, 2008 at 10:41 PM, Sanjaya Karunasena <[EMAIL PROTECTED]>
>> wrote:
>>>
>>> I am happy! Finally there is some one who is interested in this topic :-)
>>
>> Hmm, I know there are some more people interested in these issues. It is
>> just that they are much busier than me ;)
>>
>>
>> I think I can understand the issue  ( I guess so). DateTime within Java
>> might have a problem, as explained by you. But don't you have to live with
>> it, if you select to use it.
>>
>> When some one associates a type with it, he should know the limitations of
>> it and select the proper one. So if you think Java DateTime is not
>> appropriate, there are two options I can see for this problem.
>>
>> 1.. Define your own type with the level of accuracy you want and associate
>> it as the type
>> 2.  Pass your own type mapping to the system, with your util library date
>> time util mapping to xsd:datetime.
>>
>> You agree that, this is a use case, which is rare. So I think asking the
>> users to provide their own type mapping is a fare deal.
>
> Yep. We have enough flexibility in the system to allow users customize
> their code generation. I suppose we even have some documentation as
> part of the standard doc release of how to go about doing that. So if
> they really want custom times they can change the type mapping to
> change their own types.
>
>>
>> This is not a design problem, within Axis2, as I see. If you are not
>> comfortable with the type mapping, we have the extensibility to provide a
>> different one (Ajith and Amila, please correct me if I'm wrong). So it is
>> a
>> good design we have I guess ;)
>
> No need for correction :) In fact  AFAIR the typemapper is completely
> separated so that when you want to generate code for a different
> language (say C) all you need is to replace the typemapper and the
> templates (might have to do a bit of tweaking of other components as
> well but they won't be huge)
>
>>
>>
>> --
>> With Mettha,
>> Eran Chinthaka
>>
>> --------------------------------------------------------------------
>> Health is the greatest gift; contentment is the greatest wealth; trusting
>> is
>> the best relationship; nirvana is the highest joy. - Dhammapada
>
>
>
> --
> Ajith Ranabahu
>
> Reading, after a certain age, diverts the mind too much from its
> creative pursuits. Any man who reads too much and uses his own brain
> too little falls into lazy habits of thinking - Albert Einstein
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>



-- 
Ajith Ranabahu

Reading, after a certain age, diverts the mind too much from its
creative pursuits. Any man who reads too much and uses his own brain
too little falls into lazy habits of thinking - Albert Einstein

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to