[LISPMAP-109] NPE while removing mapping Created: 30/Mar/16  Updated: 14/Nov/17  Resolved: 18/Apr/16

Status: Resolved
Project: lispflowmapping
Component/s: Northbound
Affects Version/s: Beryllium
Fix Version/s: None

Type: Bug
Reporter: Jozef Gloncak 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


External issue ID: 5624

 Description   

hello team,

I encountered following problem.

I tried to call method IMappingService.removeMapping(Norhtbound, eid) [1]. Eid parameter was specified as instanceof SourceDestKey.
Method [1] calls DataStoreBackEnd.removeMapping(mapping) [2] method. Input parameter mapping is constructed through util method DSBEInputUtil.toMapping() [3] which returns Mapping instance where mappingRecord field isnt' set.
Then in method [2] there is call mapping.getMappingRecord().getEid() which will cause NullPointerException because getMappingRecord returns null.



 Comments   
Comment by Lori Jakab [ 30/Mar/16 ]

Can you please add the stack trace to the bug?

Comment by Jozef Gloncak [ 30/Mar/16 ]

testMultiSiteScenario(org.opendaylight.lispflowmapping.integrationtest.MappingServiceIntegrationTest) Time elapsed: 36.402 sec <<< ERROR!
java.lang.NullPointerException: null
at org.opendaylight.lispflowmapping.implementation.mdsal.DataStoreBackEnd.removeMapping(DataStoreBackEnd.java:103)
at org.opendaylight.lispflowmapping.implementation.MappingService.removeMapping(MappingService.java:390)
at org.opendaylight.lispflowmapping.integrationtest.MultiSiteScenario.deleteNorthMapingOneWay(MultiSiteScenario.java:240)
at org.opendaylight.lispflowmapping.integrationtest.MultiSiteScenario.deleteNorthMappingBidirect(MultiSiteScenario.java:233)
at org.opendaylight.lispflowmapping.integrationtest.MappingServiceIntegrationTest.testMultiSiteScenario(MappingServiceIntegrationTest.java:454)

Comment by Lori Jakab [ 30/Mar/16 ]

Fix proposed: https://git.opendaylight.org/gerrit/#/c/36880/

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