This content has been marked as final. Show 2 replies
did you copy and paste the wrong information? Or why is there a mismatch between the ID you got in the response for your search request and your request for the iterator? Your snippets show an ID of "7" within the response but the request has an ID of "6"
<spmlsearch:resultsIterator xmlns='urn:oasis:names:tc:SPML:2:0' xmlns:spmlsearch='urn:oasis:names:tc:SPML:2:0:search' ID='7'/>
<spmlsearch:iterateRequest xmlns='urn:oasis:names:tc:SPML:2:0' xmlns:spmlsearch='urn:oasis:names:tc:SPML:2:0:search' executionMode='synchronous'>
OPPs my mistake, to give the example here I mix two Iterator.
Well my problem got solved, issue was with maintaing the conncetion after fetching th erequest first time and iterator was not working as it lost the connection, so to reolve this we have to maintain the session cookie.
I used the separate connection of HttpURLConnection and get the cookie value like String sessionCookie = connection.getHeaderField("Set-Cookie");
and make new connection for iterator everytime and pass the store coookie value like below.