Hi Rahul,
On 2017-11-21 12:53, Rahul wrote:
> Hi Woonsan,
>
> Thanks for the reply. I am able to fix the earlier issue but now i am
> stuck at new one. This time it is more specific to hippo. I am facing
> class not found exception for "javaURLContextFactory".
Accidentally I was investigating a similar error today and discovered
the cause.
If you look at the root of your stacktrace, you'll see this is triggered
from the Java System FinalizerThread, which invokes the Jackrabbit
SessionImpl.finalize method.
Within that method Jackrabbit logs a warning if a session was
created but not properly logged out.
So far so good.
But the log4j2-dev.xml, which is by default has a logger to actually
log the above warning, also uses a special LookupFilter for "context
based logging" see: [1].
And that LookupFilter tries to lookup the current context from JNDI.
Here the problem arises: while normally this works just fine in Tomcat,
when fails when invoked from the System FinalizerThread.
Reason: the FinalizerThread doesn't have the right contextClassloader
(actually: it has none, its contextClassLoader is null!), which causes
the ClassNotFoundException.
I already have a local fix ready (by temporarily setting the
contextClassLoader), and this therefore probably will be fixed in
the next maintenance release (which can be expected soon), see: [2].
For the time being, you can workaround *this* specific error by
temporarily adjusting your log4j2-dev.xml as follows:
Find and replace the following logger definition in log4j2-dev.xml
(by default it is the first defined logger in the file):
<Logger name="org.apache.jackrabbit.core" level="warn"/>
with:
<Logger name="org.apache.jackrabbit.core" level="warn"
additivity="false">
<AppenderRef ref="console"/>
</Logger>
This will ensure the actual warning from Jackrabbit gets properly logged
to your console (only), bypassing the problem with the LookupFilter
which is configured on the "cms" and "site" appenders.
And of course, you then should investigate where the culprit Jackrabbit
session was created but not properly logged out.
Once the problem with the LookupFilter is fixed in the next maintenance
release you should revert the above change, so you then will get these
warnings also logged again to either the hippo-cms.log or hippo-site.log
file.
HTH,
Ate
[1]
https://www.onehippo.org/library/deployment/context-based-logging.html
[2]
https://issues.onehippo.com/browse/CMS-10991
> I have added dependecy to CMS pom for that but it doesn't work. I have
> also tried by adding required jars to tomcat shared lib, but it doesn't
> work. Can you please help me here.
>
> PFA screenshot of the error i am getting.
>
> Thanks
> Rahul
>
> On Saturday, November 18, 2017 at 1:56:38 PM UTC-6, woonsan.ko wrote:
>
> Hi Rahul,
>
> Sorry but, would you mind posting your question to
>
us...@jackrabbit.apache.org <javascript:> [1] again?
> On Nov 17, 2017, at 1:42 PM, Rahul <
cp....@gmail.com <javascript:>>
>> <
https://groups.google.com/group/hippo-community>.
>> <
https://groups.google.com/d/optout>.
>>
>>
>>
>>
>> --
>>
>> Saimir Muço
>>
>> Software Engineer
>>
>> email-sig-logo.png <
http://www.bloomreach.com/>
>>
>> ____________________________________________________________________________
>>
>>
>> WCM-MQ-leader-e-mail-signature.png
>> <
http://go.bloomreach.com/gartner-magic-quadrant-for-web-content-management-2017.html>
>>
>>
>> --
>> Hippo Community Group: The place for all discussions and
>> announcements about Hippo CMS (and HST, repository etc. etc.)
>>
>> To post to this group, send email to
hippo-c...@googlegroups.com
>> <javascript:>
>> RSS:
>>
https://groups.google.com/group/hippo-community/feed/rss_v2_0_msgs.xml?num=50
>> send an email to
hippo-communi...@googlegroups.com <javascript:>.
>> <
https://groups.google.com/group/hippo-community>.
>> <
https://groups.google.com/d/optout>.
>> <s3error.png>
> <mailto:
hippo-communi...@googlegroups.com>.
--
Ate Douma
Principal Product Architect BloomReach Experience, Platform Team, Amsterdam
mailto:
ate....@bloomreach.com or mailto:
hippo...@bloomreach.com
https://www.bloomreach.com https://www.onehippo.com
https://www.onehippo.org
_______________________________________________________________________________
This e-mail may be privileged and/or confidential, and the sender does not
waive any related rights and obligations. Any distribution, use or
copying of
this e-mail or the information it contains by other than an intended
recipient
is unauthorized. If you received this e-mail in error, please advise me (by
return e-mail or otherwise) immediately.