[CONTROLLER-1258] Clustering: RPC failing in clustering data store integration tests Created: 17/Apr/15 Updated: 05/May/15 Resolved: 05/May/15 |
|
| Status: | Resolved |
| Project: | controller |
| Component/s: | mdsal |
| Affects Version/s: | Post-Helium |
| Fix Version/s: | None |
| Type: | Bug | ||
| Reporter: | Phillip Shea | Assignee: | Harman Singh |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Operating System: All |
||
| External issue ID: | 3016 |
| Description |
|
I'm running /suites/clustering/datastore/020_crud_on_leader.txt. The Keywords that are failing are: Purchase cars on Leader What's happening is that the RPCs to "buy a car" only work when executed against one of the three controllers. Strangely it's note even the car-people shard leader. Tom Pantelis is running these test in Brocade's lab on Helium and they are passing. This bug is unique to Lithium. Procedure: Pull the latest stable Lithium Release. I pulled distribution-karaf-0.3.0-20150414.220637-1140.zip Use the python cluster deploy script. Let the test run. The shards configured themselves in this way: car shard {'member1': 'Follower', 'member2': 'Leader', 'member3': 'Follower'}people shard {'member1': 'Follower', 'member2': 'Follower', 'member3': 'Leader'}car-people shard {'member1': 'Leader', 'member2': 'Follower', 'member3': 'Follower'}After the test completes, use ReST RPCs to purchase a car on member1, member2, and member2. URL: JSON: } For the first two members, there will be a 500 error in Postman, and nothing in the karaf log (there will be a separate bug addressing the log and error messages). Member3 gets a nice “200 OK” in Postman and I see an acknowledgement of the car purchase in the karaf log. RPCs are not working on two out of the three controllers. |
| Comments |
| Comment by Harman Singh [ 30/Apr/15 ] |
|
Tony, I investigated this issue before and to fix it, you have to change serialization in This serialization works fine in unit tests, but with routed rpc, I made following changes, then it was working fine, 1. make ImmutableList<PathArgument> legacyPath volatile private transient volatile ImmutableList<PathArgument> legacyPath = null; 2. Change readObject, add following line - legacyPath = ImmutableList.copyOf((Collection<PathArgument>)inputStream.readObject()); 3. Change writeObject to following - ImmutableList<PathArgument> pathArguments = getLegacyPath(); outputStream.defaultWriteObject(); |
| Comment by Tony Tkacik [ 30/Apr/15 ] |
|
Harman could you provide patch to yangtools? |
| Comment by Moiz Raja [ 30/Apr/15 ] |
|
If I recall right this happened due to some Class Loader issue where the code that was deserializing did not have access to Guava or something. This may be tricky to reproduce in a simple unit test. |
| Comment by Harman Singh [ 30/Apr/15 ] |
|
Here is the patch - https://git.opendaylight.org/gerrit/#/c/19415/ Yes Moiz, this is the same issue and we see following exception - |