Source code of test application is attached to this ticket.
Import the 'Test' class and create some objects of it.
root@SC-1:~# immcfg -f test_class.xml
root@SC-1:~# immpopulate -p 10 Test
Run the OI. The OI has a sleep of 7 seconds in SaImmOiRtAttrUpdateCallbackT.
root@SC-1:~# ./test_oi &
Try to read all objects of 'Test' class
root@SC-1:~# ./test_search
IMMND crashes when receiving respose from the OI.
Apr 22 11:27:51 SC-2 osafimmnd[431]: immnd_evt.c:1080: search_req_continue: Assertion 'strncmp((const char )rsp->objectName.buf, (const char )reply->runtimeAttrs.objectName.buf, rsp->objectName.size) == 0' failed.
Analysis:
When the upcall to OI is timed out, IMMND erases the Continuation from the sSearchReqContinuationMap but it still keeps the search-node (and the searchOp).
On the search client, after getting timeout, it doesn't finalize the search handle and continues to do SearchNext().
That makes the searchOp in IMMND pop out a new object and store it to mLastResult.
When the response from OI arrives at IMMND, it fails to assert because a new object in searchOp has been popped out.
default (5.1) [staging:5aff16]
changeset: 7553:5aff16370234
user: Hung Nguyen hung.d.nguyen@dektech.com.au
date: Tue Apr 26 12:42:04 2016 +0700
summary: imm: Finalize search node if there are errors when fetching pure rt attributes [#1776]
opensaf-5.0.x [staging:860c6d]
changeset: 7554:860c6d50a286
branch: opensaf-5.0.x
parent: 7551:87acd648e1d1
user: Hung Nguyen hung.d.nguyen@dektech.com.au
date: Tue Apr 26 12:42:04 2016 +0700
summary: imm: Finalize search node if there are errors when fetching pure rt attributes [#1776]
opensaf-4.7.x [staging:2b506c]
changeset: 7555:2b506c41f13e
branch: opensaf-4.7.x
parent: 7550:a2741c56f904
user: Hung Nguyen hung.d.nguyen@dektech.com.au
date: Tue Apr 26 12:42:04 2016 +0700
summary: imm: Finalize search node if there are errors when fetching pure rt attributes [#1776]
opensaf-4.6.x [staging:616b9b]
changeset: 7556:616b9b0902d8
branch: opensaf-4.6.x
parent: 7549:dfab16919d9f
user: Hung Nguyen hung.d.nguyen@dektech.com.au
date: Tue Apr 26 12:42:04 2016 +0700
summary: imm: Finalize search node if there are errors when fetching pure rt attributes [#1776]
Related
Commit: [2b506c]
Commit: [5aff16]
Commit: [616b9b]
Commit: [860c6d]
Tickets:
#1776Diff: