Re: [Dev] [ESB] DataMapper issue

2016-07-22 Thread Godwin Shrimal
Jira [1] created.

[1] https://wso2.org/jira/browse/DEVTOOLESB-644


Thanks
Godwin


On Fri, Jul 22, 2016 at 9:07 AM, Viraj Rajaguru  wrote:

> Hi Godwin,
>
> We do not have a Jira for this improvement. Please create a Jira.
>
> Thanks,
> Viraj.
>
> On Tue, Jul 19, 2016 at 7:28 PM, Godwin Shrimal  wrote:
>
>> Hi Viraj,
>>
>> This is not a blocking thing and we can move forward by changing it from
>> the graphical view. But I think we need to figure out the proper way to fix
>> it. Do we have a jira for this already ?
>>
>>
>> Thanks
>> Godwin
>>
>>
>> On Mon, Jul 18, 2016 at 11:47 PM, Viraj Rajaguru  wrote:
>>
>>> Hi Godwin,
>>>
>>> In this use case, JSON schema generator will consider all the datatypes,
>>> but it will get the datatype of the last value of the array. See the below
>>> JSON representation of the XML
>>>
>>> {
>>>"employees":{
>>>   "firstname":"Demo",
>>>   "lastname":"Demo",
>>>   "addresses":{
>>>  "address":[
>>> {
>>>"add1":"No 827/B",
>>>"add2":"Gemunu Mawatha"
>>> },
>>> {
>>>"add1":321,
>>>"add2":"Mount Lavinia"
>>> }
>>>  ]
>>>   }
>>>}
>>> }
>>>
>>> Since the datatype of last "add1" is a NUMBER it will take that for the
>>> JSON schema. Hence we see it in the graphical tree.
>>>
>>> Issue is we have to select one of the datatypes among all the datatypes
>>> for the schema. Currently the convention is to get the last datatype. But
>>> as a fix, we can set high priority to STRING when we have to select one
>>> from multiple datatypes.
>>>
>>> Until we figure out that conventional issue, you can change the datatype
>>> of "add1" from the graphical view. Right click on the "add1" element from
>>> the tree --> Click "Edit Field" and then change the Schema type.
>>>
>>> Thanks,
>>> Viraj.
>>>
>>> On Tue, Jul 19, 2016 at 9:02 AM, Nuwan Pallewela 
>>> wrote:
>>>
 Adding Sohani

 On Tue, Jul 19, 2016 at 12:42 AM, Godwin Shrimal 
 wrote:

> Hi All,
>
> When load following xml file in to data mapper (input/output), the
> add1 data type takes as NUMBER as in screenshot . It looks when there is 
> at
> least one record in the array with NUMBER it takes as NUMBER. I think It
> should consider all the values in the array.
>
> 
> Demo
> Demo
>
> 
>   
>   *No 827/B*
> Gemunu Mawatha
>   
>   
> *321*
> Mount Lavinia
>   
> 
> 
>
> [image: Inline image 2]
> Thanks
> Godwin
>
> --
> *Godwin Amila Shrimal*
> Senior Software Engineer
> WSO2 Inc.; http://wso2.com
> lean.enterprise.middleware
>
> mobile: *+94772264165*
> linkedin: *http://lnkd.in/KUum6D *
> twitter: https://twitter.com/godwinamila
> 
>



 --
 --

 *Nuwan Chamara Pallewela*


 *Software Engineer*

 *WSO2, Inc. *http://wso2.com
 *lean . enterprise . middleware*

 Email   *nuw...@wso2.com *
 Mobile  *+94719079739 <%2B94719079739>@*



>>>
>>>
>>> --
>>> Viraj Rajaguru
>>> Associate Technical Lead
>>> WSO2 Inc. : http://wso2.com
>>>
>>> Mobile: +94 77 3683068
>>>
>>>
>>>
>>>
>>
>>
>> --
>> *Godwin Amila Shrimal*
>> Senior Software Engineer
>> WSO2 Inc.; http://wso2.com
>> lean.enterprise.middleware
>>
>> mobile: *+94772264165*
>> linkedin: *http://lnkd.in/KUum6D *
>> twitter: https://twitter.com/godwinamila
>> 
>>
>
>
>
> --
> Viraj Rajaguru
> Associate Technical Lead
> WSO2 Inc. : http://wso2.com
>
> Mobile: +94 77 3683068
>
>
>
>


-- 
*Godwin Amila Shrimal*
Senior Software Engineer
WSO2 Inc.; http://wso2.com
lean.enterprise.middleware

mobile: *+94772264165*
linkedin: *http://lnkd.in/KUum6D *
twitter: https://twitter.com/godwinamila

___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [ESB] DataMapper issue

2016-07-22 Thread Viraj Rajaguru
Hi Godwin,

We do not have a Jira for this improvement. Please create a Jira.

Thanks,
Viraj.

On Tue, Jul 19, 2016 at 7:28 PM, Godwin Shrimal  wrote:

> Hi Viraj,
>
> This is not a blocking thing and we can move forward by changing it from
> the graphical view. But I think we need to figure out the proper way to fix
> it. Do we have a jira for this already ?
>
>
> Thanks
> Godwin
>
>
> On Mon, Jul 18, 2016 at 11:47 PM, Viraj Rajaguru  wrote:
>
>> Hi Godwin,
>>
>> In this use case, JSON schema generator will consider all the datatypes,
>> but it will get the datatype of the last value of the array. See the below
>> JSON representation of the XML
>>
>> {
>>"employees":{
>>   "firstname":"Demo",
>>   "lastname":"Demo",
>>   "addresses":{
>>  "address":[
>> {
>>"add1":"No 827/B",
>>"add2":"Gemunu Mawatha"
>> },
>> {
>>"add1":321,
>>"add2":"Mount Lavinia"
>> }
>>  ]
>>   }
>>}
>> }
>>
>> Since the datatype of last "add1" is a NUMBER it will take that for the
>> JSON schema. Hence we see it in the graphical tree.
>>
>> Issue is we have to select one of the datatypes among all the datatypes
>> for the schema. Currently the convention is to get the last datatype. But
>> as a fix, we can set high priority to STRING when we have to select one
>> from multiple datatypes.
>>
>> Until we figure out that conventional issue, you can change the datatype
>> of "add1" from the graphical view. Right click on the "add1" element from
>> the tree --> Click "Edit Field" and then change the Schema type.
>>
>> Thanks,
>> Viraj.
>>
>> On Tue, Jul 19, 2016 at 9:02 AM, Nuwan Pallewela  wrote:
>>
>>> Adding Sohani
>>>
>>> On Tue, Jul 19, 2016 at 12:42 AM, Godwin Shrimal 
>>> wrote:
>>>
 Hi All,

 When load following xml file in to data mapper (input/output), the add1
 data type takes as NUMBER as in screenshot . It looks when there is at
 least one record in the array with NUMBER it takes as NUMBER. I think It
 should consider all the values in the array.

 
 Demo
 Demo

 
   
   *No 827/B*
 Gemunu Mawatha
   
   
 *321*
 Mount Lavinia
   
 
 

 [image: Inline image 2]
 Thanks
 Godwin

 --
 *Godwin Amila Shrimal*
 Senior Software Engineer
 WSO2 Inc.; http://wso2.com
 lean.enterprise.middleware

 mobile: *+94772264165*
 linkedin: *http://lnkd.in/KUum6D *
 twitter: https://twitter.com/godwinamila
 

>>>
>>>
>>>
>>> --
>>> --
>>>
>>> *Nuwan Chamara Pallewela*
>>>
>>>
>>> *Software Engineer*
>>>
>>> *WSO2, Inc. *http://wso2.com
>>> *lean . enterprise . middleware*
>>>
>>> Email   *nuw...@wso2.com *
>>> Mobile  *+94719079739 <%2B94719079739>@*
>>>
>>>
>>>
>>
>>
>> --
>> Viraj Rajaguru
>> Associate Technical Lead
>> WSO2 Inc. : http://wso2.com
>>
>> Mobile: +94 77 3683068
>>
>>
>>
>>
>
>
> --
> *Godwin Amila Shrimal*
> Senior Software Engineer
> WSO2 Inc.; http://wso2.com
> lean.enterprise.middleware
>
> mobile: *+94772264165*
> linkedin: *http://lnkd.in/KUum6D *
> twitter: https://twitter.com/godwinamila
> 
>



-- 
Viraj Rajaguru
Associate Technical Lead
WSO2 Inc. : http://wso2.com

Mobile: +94 77 3683068
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [ESB] DataMapper issue

2016-07-19 Thread Godwin Shrimal
Hi Viraj,

This is not a blocking thing and we can move forward by changing it from
the graphical view. But I think we need to figure out the proper way to fix
it. Do we have a jira for this already ?


Thanks
Godwin


On Mon, Jul 18, 2016 at 11:47 PM, Viraj Rajaguru  wrote:

> Hi Godwin,
>
> In this use case, JSON schema generator will consider all the datatypes,
> but it will get the datatype of the last value of the array. See the below
> JSON representation of the XML
>
> {
>"employees":{
>   "firstname":"Demo",
>   "lastname":"Demo",
>   "addresses":{
>  "address":[
> {
>"add1":"No 827/B",
>"add2":"Gemunu Mawatha"
> },
> {
>"add1":321,
>"add2":"Mount Lavinia"
> }
>  ]
>   }
>}
> }
>
> Since the datatype of last "add1" is a NUMBER it will take that for the
> JSON schema. Hence we see it in the graphical tree.
>
> Issue is we have to select one of the datatypes among all the datatypes
> for the schema. Currently the convention is to get the last datatype. But
> as a fix, we can set high priority to STRING when we have to select one
> from multiple datatypes.
>
> Until we figure out that conventional issue, you can change the datatype
> of "add1" from the graphical view. Right click on the "add1" element from
> the tree --> Click "Edit Field" and then change the Schema type.
>
> Thanks,
> Viraj.
>
> On Tue, Jul 19, 2016 at 9:02 AM, Nuwan Pallewela  wrote:
>
>> Adding Sohani
>>
>> On Tue, Jul 19, 2016 at 12:42 AM, Godwin Shrimal  wrote:
>>
>>> Hi All,
>>>
>>> When load following xml file in to data mapper (input/output), the add1
>>> data type takes as NUMBER as in screenshot . It looks when there is at
>>> least one record in the array with NUMBER it takes as NUMBER. I think It
>>> should consider all the values in the array.
>>>
>>> 
>>> Demo
>>> Demo
>>>
>>> 
>>>   
>>>   *No 827/B*
>>> Gemunu Mawatha
>>>   
>>>   
>>> *321*
>>> Mount Lavinia
>>>   
>>> 
>>> 
>>>
>>> [image: Inline image 2]
>>> Thanks
>>> Godwin
>>>
>>> --
>>> *Godwin Amila Shrimal*
>>> Senior Software Engineer
>>> WSO2 Inc.; http://wso2.com
>>> lean.enterprise.middleware
>>>
>>> mobile: *+94772264165*
>>> linkedin: *http://lnkd.in/KUum6D *
>>> twitter: https://twitter.com/godwinamila
>>> 
>>>
>>
>>
>>
>> --
>> --
>>
>> *Nuwan Chamara Pallewela*
>>
>>
>> *Software Engineer*
>>
>> *WSO2, Inc. *http://wso2.com
>> *lean . enterprise . middleware*
>>
>> Email   *nuw...@wso2.com *
>> Mobile  *+94719079739 <%2B94719079739>@*
>>
>>
>>
>
>
> --
> Viraj Rajaguru
> Associate Technical Lead
> WSO2 Inc. : http://wso2.com
>
> Mobile: +94 77 3683068
>
>
>
>


-- 
*Godwin Amila Shrimal*
Senior Software Engineer
WSO2 Inc.; http://wso2.com
lean.enterprise.middleware

mobile: *+94772264165*
linkedin: *http://lnkd.in/KUum6D *
twitter: https://twitter.com/godwinamila

___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [ESB] DataMapper issue

2016-07-18 Thread Viraj Rajaguru
Hi Godwin,

In this use case, JSON schema generator will consider all the datatypes,
but it will get the datatype of the last value of the array. See the below
JSON representation of the XML

{
   "employees":{
  "firstname":"Demo",
  "lastname":"Demo",
  "addresses":{
 "address":[
{
   "add1":"No 827/B",
   "add2":"Gemunu Mawatha"
},
{
   "add1":321,
   "add2":"Mount Lavinia"
}
 ]
  }
   }
}

Since the datatype of last "add1" is a NUMBER it will take that for the
JSON schema. Hence we see it in the graphical tree.

Issue is we have to select one of the datatypes among all the datatypes for
the schema. Currently the convention is to get the last datatype. But as a
fix, we can set high priority to STRING when we have to select one from
multiple datatypes.

Until we figure out that conventional issue, you can change the datatype of
"add1" from the graphical view. Right click on the "add1" element from the
tree --> Click "Edit Field" and then change the Schema type.

Thanks,
Viraj.

On Tue, Jul 19, 2016 at 9:02 AM, Nuwan Pallewela  wrote:

> Adding Sohani
>
> On Tue, Jul 19, 2016 at 12:42 AM, Godwin Shrimal  wrote:
>
>> Hi All,
>>
>> When load following xml file in to data mapper (input/output), the add1
>> data type takes as NUMBER as in screenshot . It looks when there is at
>> least one record in the array with NUMBER it takes as NUMBER. I think It
>> should consider all the values in the array.
>>
>> 
>> Demo
>> Demo
>>
>> 
>>   
>>   *No 827/B*
>> Gemunu Mawatha
>>   
>>   
>> *321*
>> Mount Lavinia
>>   
>> 
>> 
>>
>> [image: Inline image 2]
>> Thanks
>> Godwin
>>
>> --
>> *Godwin Amila Shrimal*
>> Senior Software Engineer
>> WSO2 Inc.; http://wso2.com
>> lean.enterprise.middleware
>>
>> mobile: *+94772264165*
>> linkedin: *http://lnkd.in/KUum6D *
>> twitter: https://twitter.com/godwinamila
>> 
>>
>
>
>
> --
> --
>
> *Nuwan Chamara Pallewela*
>
>
> *Software Engineer*
>
> *WSO2, Inc. *http://wso2.com
> *lean . enterprise . middleware*
>
> Email   *nuw...@wso2.com *
> Mobile  *+94719079739 <%2B94719079739>@*
>
>
>


-- 
Viraj Rajaguru
Associate Technical Lead
WSO2 Inc. : http://wso2.com

Mobile: +94 77 3683068
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [ESB] DataMapper issue

2016-07-18 Thread Susinda Perera
Yes, In that case it should be string (when we have multiple data types).
This issue is may be due to that we check the data type from json. Fix
should go in that place i believe.

On Tue, Jul 19, 2016 at 9:02 AM, Nuwan Pallewela  wrote:

> Adding Sohani
>
> On Tue, Jul 19, 2016 at 12:42 AM, Godwin Shrimal  wrote:
>
>> Hi All,
>>
>> When load following xml file in to data mapper (input/output), the add1
>> data type takes as NUMBER as in screenshot . It looks when there is at
>> least one record in the array with NUMBER it takes as NUMBER. I think It
>> should consider all the values in the array.
>>
>> 
>> Demo
>> Demo
>>
>> 
>>   
>>   *No 827/B*
>> Gemunu Mawatha
>>   
>>   
>> *321*
>> Mount Lavinia
>>   
>> 
>> 
>>
>> [image: Inline image 2]
>> Thanks
>> Godwin
>>
>> --
>> *Godwin Amila Shrimal*
>> Senior Software Engineer
>> WSO2 Inc.; http://wso2.com
>> lean.enterprise.middleware
>>
>> mobile: *+94772264165*
>> linkedin: *http://lnkd.in/KUum6D *
>> twitter: https://twitter.com/godwinamila
>> 
>>
>
>
>
> --
> --
>
> *Nuwan Chamara Pallewela*
>
>
> *Software Engineer*
>
> *WSO2, Inc. *http://wso2.com
> *lean . enterprise . middleware*
>
> Email   *nuw...@wso2.com *
> Mobile  *+94719079739 <%2B94719079739>@*
>
>
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
*Susinda Perera*
Software Engineer
B.Sc.(Eng), M.Sc(Computer Science), AMIE(SL)
Mobile:(+94)716049075
Blog: susinda.blogspot.com
WSO2 Inc. http://wso2.com/
Tel : 94 11 214 5345 Fax :94 11 2145300
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [ESB] DataMapper issue

2016-07-18 Thread Nuwan Pallewela
Adding Sohani

On Tue, Jul 19, 2016 at 12:42 AM, Godwin Shrimal  wrote:

> Hi All,
>
> When load following xml file in to data mapper (input/output), the add1
> data type takes as NUMBER as in screenshot . It looks when there is at
> least one record in the array with NUMBER it takes as NUMBER. I think It
> should consider all the values in the array.
>
> 
> Demo
> Demo
>
> 
>   
>   *No 827/B*
> Gemunu Mawatha
>   
>   
> *321*
> Mount Lavinia
>   
> 
> 
>
> [image: Inline image 2]
> Thanks
> Godwin
>
> --
> *Godwin Amila Shrimal*
> Senior Software Engineer
> WSO2 Inc.; http://wso2.com
> lean.enterprise.middleware
>
> mobile: *+94772264165*
> linkedin: *http://lnkd.in/KUum6D *
> twitter: https://twitter.com/godwinamila
> 
>



-- 
--

*Nuwan Chamara Pallewela*


*Software Engineer*

*WSO2, Inc. *http://wso2.com
*lean . enterprise . middleware*

Email   *nuw...@wso2.com *
Mobile  *+94719079739@*
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev