Committed the patch then.

2013/8/26 Vinay Agrawal <[email protected]>:
> Thanks for explanation Kasper.
>
> +1 for this change
>
> Regards
>
> Vinay Agrawal* Senior Consultant
> Xebia IT Architects India Private Limited
> 612 * BPTP Park Centra * Sector 30 * Gurgaon 122002 * Haryana * INDIA
> mobile* 9958600483 Email*[email protected]
>
> ________________________________________
> From: Kasper Sørensen [[email protected]]
> Sent: Sunday, August 25, 2013 11:09 PM
> To: [email protected]
> Subject: Re: [PATCH] Fix for bug in Salesforce DATE object formatting/parsing
>
> Hi Vinay,
>
> Ah yes good points to address. I would agree if this had anything to
> do with the user's perspective on the data - then Locale should be
> externalized. But the changes with adding Locale to the
> SimpleDateFormats used in the salesforce module are applied not to the
> users data, but to the data that is interchanged with Salesforce. The
> reason is that Salesforce sends and recieves date values as strings,
> and these strings are formatted in a particular format - and using
> english locale for e.g. weekday and month names. So the hardcoded
> Locale is hardcoded specifically because we are formatting and parsing
> date strings at the protocol layer, which is "behind the curtains" for
> a MetaModel user.
>
> 2013/8/23 Vinay Agrawal <[email protected]>:
>> Hi Kasper,
>>
>>
>> My only concern with this fix is that we are restricting users to use Locale 
>> as English . We rather should have a way for a user to set the locale for 
>> the complete metamodel ( e.g. dataContext.setLocale(Locale.XYZ) ) and then 
>> we can use that Locale over here. Also default
>> Locale can be set as Locale.english
>>
>> Thoughts ?
>>
>> Thanks
>>
>> Vinay Agrawal* Senior Consultant
>> Xebia IT Architects India Private Limited
>> 612 * BPTP Park Centra * Sector 30 * Gurgaon 122002 * Haryana * INDIA
>> mobile* 9958600483 Email*[email protected]
>>
>> ________________________________________
>> From: Kasper Sørensen [[email protected]]
>> Sent: Friday, August 23, 2013 7:06 PM
>> To: [email protected]
>> Subject: Re: [PATCH] Fix for bug in Salesforce DATE object formatting/parsing
>>
>> Forgot to add - please review and vote if you agree on the patch :-)
>>
>> 2013/8/23 Kasper Sørensen <[email protected]>:
>>> Here's a patch for the issue with DATE objects, just mentioned [1]:
>>> https://gist.github.com/kaspersorensen/6319391
>>>
>>> [1] Email thread "Date format to insert in salesforce":
>>>
>>> "In the salesforce module we always convert incoming Date values
>>> using a SimpleDateFormat with the UTC timezone. This is because SF
>>> saves the dates in UTC, so we have to ensure we don't wrongly send a
>>> date in the wrong format. All well. But a problem is that we also do
>>> this (apply timezone) for DATE columns, which are columns that don't
>>> have any time-of-day information (like a birthdate). In such scenarios
>>> we should not apply a timezone since it may change the actual date
>>> that we're submitting to SF. This is a bug which I'll post a patch for
>>> shortly."

Reply via email to