← Back to team overview

dhis2-devs team mailing list archive

Re: [Branch ~dhis2-devs-core/dhis2/trunk] Rev 19296: WIP proper error reporting on failed GML parsing during import

 

Oh, and for the record: the stack overflow was caused by cirular calls to
toString between AttributeValue and Attribute, respectively.

2015-07-04 0:56 GMT+02:00 Halvdan Grelland <halvdanhg@xxxxxxxxx>:

> Yes, that is the plan, ultimately.
> It's a pretty major change though, making it non-trivial to port the fix
> (it's more of a refactor). I'll look into it after the weekend (or during
> the weekend if the sun stops shining in Oslo).
>
> I did make (and backport) some changes which fix the stack overflow issue,
> however. In practice this means that GML import should work for you on the
> latest 2.19, but any attribute values will unfortunately be deleted in the
> process (!), or you might even experience the importer halting if there are
> attribute values for the orgunits. Not ideal, in other words, and something
> you should be aware of.
>
> Halvdan
>
> 2015-07-03 18:55 GMT+02:00 Calle Hedberg <calle.hedberg@xxxxxxxxx>:
>
>> Halvdan,
>>
>> I see you have committed a significant fix to 2.20 trunk - which I hope
>> will also fix my GML import issue.
>>
>> Will you port this fix to 2.19 also, please?
>>
>> Regards
>> Calle
>>
>> On 1 July 2015 at 15:01, Halvdan Grelland <halvdanhg@xxxxxxxxx> wrote:
>>
>>> Ok, so I've looked further into this. The only issue I am able to
>>> consistently reproduce happens only in the GML import process. The stack
>>> trace can be found here
>>> <https://gist.github.com/grelland/45acadfbe475422889ec>
>>> Note that this might be unrelated to the looping/recursion issue.,
>>>
>>> This does not happen if I pre-stage the meta data payload (ie write it
>>> to a file and import using the metadata importer). My suspicion that the
>>> conflict occurs because of the clear/re-add of attributevalues in the
>>> orgunit.mergeWith() method (which I'm using to merge geodata updates into
>>> the orgunit), which happens within a transactional scope. I'm gonna have to
>>> experiment further to find a solution. Any suggestions are much appreciated.
>>>
>>>
>>> 2015-07-01 14:39 GMT+02:00 Bob Jolliffe <bobjolliffe@xxxxxxxxx>:
>>>
>>>> Morten this is a long shot, but do you think there is any possibility
>>>> the removal of xerces exclusions in 2.19 might be causing these
>>>> strange unpredictable problems?  Weird StackOverflowErrors and Xerces
>>>> problems seem to go hand in hand - google the two terms :-(  I guess
>>>> the nub is that it becomes unpredictable which xercesimpl the
>>>> classloader uses.
>>>>
>>>> The original reason for adding the xercesImpl exclusions was that it
>>>> seemed to make the java xml parsing more stable.  I am not sure how it
>>>> easy it would be test this as you'd have to build without openid4java
>>>> .. which is the library which caused us to remove the exclusions.
>>>>
>>>> On 1 July 2015 at 10:16, Morten Olav Hansen <mortenoh@xxxxxxxxx> wrote:
>>>> >
>>>> > On Wed, Jul 1, 2015 at 4:12 PM, Bob Jolliffe <bobjolliffe@xxxxxxxxx>
>>>> wrote:
>>>> >>
>>>> >> Having said that, this stack overflow business might carry some clue.
>>>> >> @Morten you mention elsewhere in this thread  "It seems to be
>>>> looping in
>>>> >> Attribute.toString()".  Are you sure it is looping or is there
>>>> something
>>>> >> recursive going on here?  (note that xslt with very large nodesets
>>>> could
>>>> >> indeed also cause recursion problems)
>>>> >
>>>> >
>>>> > Well, it reminded me of an earlier issue we had, but that have since
>>>> been
>>>> > fixed.
>>>> >
>>>> > As I can import the sample XML file from Halvdan without any issues
>>>> in 2.19
>>>> > / 2.20 (but he could not...) I might not be reproducing it properly,
>>>> so I'm
>>>> > waiting for input from him.
>>>> >
>>>> > --
>>>> > Morten
>>>>
>>>> _______________________________________________
>>>> Mailing list: https://launchpad.net/~dhis2-devs
>>>> Post to     : dhis2-devs@xxxxxxxxxxxxxxxxxxx
>>>> Unsubscribe : https://launchpad.net/~dhis2-devs
>>>> More help   : https://help.launchpad.net/ListHelp
>>>>
>>>
>>>
>>> _______________________________________________
>>> Mailing list: https://launchpad.net/~dhis2-devs
>>> Post to     : dhis2-devs@xxxxxxxxxxxxxxxxxxx
>>> Unsubscribe : https://launchpad.net/~dhis2-devs
>>> More help   : https://help.launchpad.net/ListHelp
>>>
>>>
>>
>>
>> --
>>
>> *******************************************
>>
>> Calle Hedberg
>>
>> 46D Alma Road, 7700 Rosebank, SOUTH AFRICA
>>
>> Tel/fax (home): +27-21-685-6472
>>
>> Cell: +27-82-853-5352
>>
>> Iridium SatPhone: +8816-315-19274
>>
>> Email: calle.hedberg@xxxxxxxxx
>>
>> Skype: calle_hedberg
>>
>> *******************************************
>>
>>
>

Follow ups

References