HiI have created a ticket for thishttps://issues.apache.org/jira/projects/CAMEL/issues/CAMEL-17181?filter=reportedbyme/M On fre, nov. 12, 2021 at 09:37, Claus Ibsen skrev: On Fri, Nov 12, 2021 at 8:03 AM Mikael Andersson Wigander wrote:> Ok thanks.>> But the outcome is
Hi
I have found the bug, so no need for a re-producer.
On Fri, Nov 12, 2021 at 9:37 AM Claus Ibsen wrote:
>
>
> On Fri, Nov 12, 2021 at 8:03 AM Mikael Andersson Wigander
> wrote:
>
>> Ok thanks.
>>
>> But the outcome is very obvious when I analyse the heapdump.
>> The pool.clear() is never
On Fri, Nov 12, 2021 at 8:03 AM Mikael Andersson Wigander
wrote:
> Ok thanks.
>
> But the outcome is very obvious when I analyse the heapdump.
> The pool.clear() is never executed and the memory is filled with the
> orphaned pool.
> If the pool is to be used as a placeholder for the expressions
Ok thanks. But the outcome is very obvious when I analyse the heapdump. The pool.clear() is never executed and the memory is filled with the orphaned pool. If the pool is to be used as a placeholder for the expressions then why is not only 10 items in the pool? My pool after importing records
Hi
Mind about evaluating xpath in Java is not thread safe so you end up having
to create an instance of XPathExpression per xpath you want to execute.
And your bean have 10 xpaths, so that is 10 per message, so you end up with
10 XPathExpression instances in the memory.
And all legacy XML from
into memory at once. When you need
millisecond performance this is a good option.
Alex Mattern
From: Siano, Stephan
Sent: Tuesday, November 9, 2021 12:41 AM
To: users@camel.apache.org
Subject: [EXTERNAL SENDER:] RE: How to make a bean thread safe?
Hi
I don’t think that this issue is related
I think I know now what's going on.
The XPathBuilder.class is using a pool to store all @XPath() expressions and it
keeps adds to the pool but it never clears the pool.
In class there's a method doStop() which runs pool.clear() and
poolLogNamespaces.clear();
but it is never called,
Hi
I see what you mean but still there must be a leak somewhere…
The payload is small
DE000C3JALS0
EAA3 SI 20211220 CS
EEX/EUAA P AUCTION SPOT
ITNXXX
EUR
false
529900J0JGLSFDWNFC20
XEER
false
2015-03-25T06:00:00Z
2031-12-30T23:59:59Z
500
ENVR
EMIS
EUAA
OTHR
EXOF
DE
2021-03-18
Hi
I don’t think that this issue is related to thread safety. XPath as such is a
very expensive operation as it requires parsing the document into a DOM. You
have 10 of those XPath parameters and the heap dump shows 10 XPath builders
that are consuming a lot of memory. You’d probably better