[YANGTOOLS-466] Delete case in AdjRibsOut emits NPE Created: 11/Jun/15  Updated: 10/Apr/22  Due: 17/Jun/15  Resolved: 15/Jun/15

Status: Resolved
Project: yangtools
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug
Reporter: Dana Kutenicsova Assignee: Unassigned
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Operating System: All
Platform: All


Issue Links:
Duplicate
is duplicated by CONTROLLER-1371 RIB attribute is {"attributes":{"upto... Resolved
External issue ID: 3674

 Description   

It seems that in case of DELETE, the only thing we get from the datastore is DataTreeCandidateNode identifier, no dataBefore or dataAfter, therefore the log (dataBefore().get()) emits NPE.



 Comments   
Comment by Robert Varga [ 11/Jun/15 ]

Needs to be fixed before Lithium goes out.

Comment by Dana Kutenicsova [ 12/Jun/15 ]

2015-06-12 09:09:32,179 | ERROR | lt-dispatcher-15 | DataTreeChangeListenerActor | 169 - org.opendaylight.controller.sal-distributed-datastore - 1.2.0.SNAPSHOT | Error notifying listener org.opendaylight.protocol.bgp.rib.impl.AdjRibOutListener@669749ec
java.lang.IllegalStateException: Optional.get() cannot be called on an absent value
at com.google.common.base.Absent.get(Absent.java:47)[51:com.google.guava:18.0.0]
at org.opendaylight.protocol.bgp.rib.impl.AdjRibOutListener.onDataTreeChanged(AdjRibOutListener.java:76)[227:org.opendaylight.bgpcep.bgp-rib-impl:0.4.0.SNAPSHOT]
at org.opendaylight.controller.cluster.datastore.DataTreeChangeListenerActor.dataChanged(DataTreeChangeListenerActor.java:53)[169:org.opendaylight.controller.sal-distributed-datastore:1.2.0.SNAPSHOT]
at org.opendaylight.controller.cluster.datastore.DataTreeChangeListenerActor.handleReceive(DataTreeChangeListenerActor.java:37)[169:org.opendaylight.controller.sal-distributed-datastore:1.2.0.SNAPSHOT]
at org.opendaylight.controller.cluster.common.actor.AbstractUntypedActor.onReceive(AbstractUntypedActor.java:34)[161:org.opendaylight.controller.sal-clustering-commons:1.2.0.SNAPSHOT]
at akka.actor.UntypedActor$$anonfun$receive$1.applyOrElse(UntypedActor.scala:167)[154:com.typesafe.akka.actor:2.3.10]
at akka.actor.Actor$class.aroundReceive(Actor.scala:467)[154:com.typesafe.akka.actor:2.3.10]
at akka.actor.UntypedActor.aroundReceive(UntypedActor.scala:97)[154:com.typesafe.akka.actor:2.3.10]
at akka.actor.ActorCell.receiveMessage(ActorCell.scala:516)[154:com.typesafe.akka.actor:2.3.10]
at akka.actor.ActorCell.invoke(ActorCell.scala:487)[154:com.typesafe.akka.actor:2.3.10]
at akka.dispatch.Mailbox.processMailbox(Mailbox.scala:254)[154:com.typesafe.akka.actor:2.3.10]
at akka.dispatch.Mailbox.run(Mailbox.scala:221)[154:com.typesafe.akka.actor:2.3.10]
at akka.dispatch.Mailbox.exec(Mailbox.scala:231)[154:com.typesafe.akka.actor:2.3.10]
at scala.concurrent.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260)[151:org.scala-lang.scala-library:2.10.4.v20140209-180020-VFINAL-b66a39653b]
at scala.concurrent.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339)[151:org.scala-lang.scala-library:2.10.4.v20140209-180020-VFINAL-b66a39653b]
at scala.concurrent.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979)[151:org.scala-lang.scala-library:2.10.4.v20140209-180020-VFINAL-b66a39653b]
at scala.concurrent.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107)[151:org.scala-lang.scala-library:2.10.4.v20140209-180020-VFINAL-b66a39653b]

Comment by Dana Kutenicsova [ 12/Jun/15 ]

As it turns out, in this case, the delete without dataBefore shouldn't be issued as DELETE, but as UNMODIFIED. Moved to yangtools.

Comment by Dana Kutenicsova [ 12/Jun/15 ]

https://git.opendaylight.org/gerrit/#/c/22471/

Generated at Wed Feb 07 20:53:19 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.