You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@aries.apache.org by "Veselin (Jira)" <ji...@apache.org> on 2020/04/27 15:27:00 UTC
[jira] [Comment Edited] (ARIES-1979) NPE while refreshing chain
[ https://issues.apache.org/jira/browse/ARIES-1979?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17093631#comment-17093631 ]
Veselin edited comment on ARIES-1979 at 4/27/20, 3:26 PM:
----------------------------------------------------------
Ok I just dug a little deeper into the the newer version 1.0.8 and found out that
{code:java}
org.apache.aries.jax.rs.whiteboard.internal.Registry.waitForService(){code}
synchs the calls to the afore mentioned methods. Do other other call paths to the methods of Whlteboard exits or is Registry the only gateway into the whiteboard bundle?
was (Author: markov):
Ok I just dug a little deeper into the the newer version 1.0.8 and found out that org.apache.aries.jax.rs.whiteboard.internal.Registry.waitForService() synchs the calls to the afore mentioned methods. Do other other call paths to the methods of Whlteboard exits or is Registry the only gateway into the whiteboard bundle?
> NPE while refreshing chain
> --------------------------
>
> Key: ARIES-1979
> URL: https://issues.apache.org/jira/browse/ARIES-1979
> Project: Aries
> Issue Type: Bug
> Components: jax-rs-whiteboard
> Affects Versions: jax-rs-whiteboard-1.0.4
> Reporter: Veselin
> Priority: Major
> Labels: NullPointerException
> Attachments: stacktrace.txt
>
>
> I get a NullPointerException when registering some chain filters or endpoints. I could trace the problem back to the refresh() method of ServiceTuple. After the AtomicReference _service is set to null and before the new value is set later on, a call to getService() occurs in another thread which causes the NPE.
> This leads to the problem that a filter in my chain filter is being skipped sometimes while the my application starts which causes bugs.
>
> P.S. I had to change the code a bit to get the stack trace. It seems the logging in Whiteboard:895 can be improved a bit to log stack traces.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)