aries-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "John Ross (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (ARIES-1498) NullPointerException NPE Blueprint Container AbstractServiceReferenceRecipe setSatisfied
Date Mon, 29 Feb 2016 19:28:18 GMT

    [ https://issues.apache.org/jira/browse/ARIES-1498?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15172442#comment-15172442
] 

John Ross commented on ARIES-1498:
----------------------------------

Line 419 is where the satisfactionListener is accessed. This is an unprotected, mutable object
variable. It is set in the start method, unset in the stop method, and operated on in the
setSatisfied method.

There certainly appears to be a visibility issue here unless there is some protection offered
higher up the stack that I'm not seeing. This could have occurred, therefore, after the start
method had been called on one thread followed by the setSatisfied method on another.

Another, and probably more concerning, possibility would be that the setSatisfied method was
called after the stop method. I'm not familiar enough with blueprint to know whether this
is possible or not.

> NullPointerException NPE Blueprint Container AbstractServiceReferenceRecipe setSatisfied
> ----------------------------------------------------------------------------------------
>
>                 Key: ARIES-1498
>                 URL: https://issues.apache.org/jira/browse/ARIES-1498
>             Project: Aries
>          Issue Type: Bug
>          Components: Blueprint
>    Affects Versions: blueprint-core-1.5.0
>            Reporter: John Ross
>
> [2/28/16 6:12:25:150 EST] 00000010 LogService-115-BPCompWABClient                   
           E CWWKE0701E: FrameworkEvent ERROR Bundle:BPCompWABClient(id=115) java.lang.NullPointerException
> 	at org.apache.aries.blueprint.container.AbstractServiceReferenceRecipe.setSatisfied(AbstractServiceReferenceRecipe.java:419)
> 	at org.apache.aries.blueprint.container.AbstractServiceReferenceRecipe.serviceAdded(AbstractServiceReferenceRecipe.java:361)
> 	at org.apache.aries.blueprint.container.AbstractServiceReferenceRecipe.serviceChanged(AbstractServiceReferenceRecipe.java:341)
> 	at org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:109)
> 	at org.eclipse.osgi.internal.framework.BundleContextImpl.dispatchEvent(BundleContextImpl.java:915)
> 	at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
> 	at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
> 	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:862)
> 	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:801)
> 	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:127)
> 	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:225)
> 	at org.eclipse.osgi.internal.framework.BundleContextImpl.registerService(BundleContextImpl.java:464)
> 	at org.apache.aries.blueprint.container.BlueprintContainerImpl.registerService(BlueprintContainerImpl.java:485)
> 	at org.apache.aries.blueprint.container.ServiceRecipe.register(ServiceRecipe.java:193)
> 	at org.apache.aries.blueprint.container.BlueprintContainerImpl.registerServices(BlueprintContainerImpl.java:739)
> 	at org.apache.aries.blueprint.container.BlueprintContainerImpl.doRun(BlueprintContainerImpl.java:406)
> 	at org.apache.aries.blueprint.container.BlueprintContainerImpl.run(BlueprintContainerImpl.java:275)
> 	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:483)
> 	at java.util.concurrent.FutureTask.run(FutureTask.java:274)
> 	at org.apache.aries.blueprint.container.ExecutorServiceWrapper.run(ExecutorServiceWrapper.java:106)
> 	at org.apache.aries.blueprint.utils.threading.impl.DiscardableRunnable.run(DiscardableRunnable.java:48)
> 	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:483)
> 	at java.util.concurrent.FutureTask.run(FutureTask.java:274)
> 	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:190)
> 	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304)
> 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1157)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:627)
> 	at java.lang.Thread.run(Thread.java:798)
>  Event:org.osgi.framework.FrameworkEvent[source=BPCompWABClient_1.0.0 [115]] 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message