Find webservice not working with SDK4J
PostPosted:Fri Sep 19, 2014 1:26 pm
Hi ,
I am using SDK4J version 1.0 and trying to perform full text search with 'Find' webservice to return documents containing the search text. Following is the code snippet I have used.
Please let me know if I am missing anything here.
I have tried with 'FindByContent' and that is also failing.
I am using SDK4J version 1.0 and trying to perform full text search with 'Find' webservice to return documents containing the search text. Following is the code snippet I have used.
Code: Select all
The search text used returns valid result if I perform the same search using OpenKM repository GUI. But when I perform the same search through our application, using the above code, it is returning empty result. This used to work with Open KM 6.2 without SDK4J. But after replacing with SDK4J, the full text search using 'Find' webservice is not working. public List<QueryResult> searchDocs(String searchText) throws Exception{
OKMWebservices okmWebservices = OKMWebservicesFactory.newInstance(OKM_ENDPOINT_URL, FileHandlingPropertiesUtil.getProperty("USERNAME"),
FileHandlingPropertiesUtil.getProperty("PASSWORD"));
List<QueryResult> resultList = null;
QueryParams queryParams = new QueryParams();
try{
String docPath = "/okm:root/Integ/Award_Integ/";
queryParams.setPath(docPath);
queryParams.setContent(searchText);
queryParams.setDomain(1);
resultList = okmWebservices.find(queryParams);
} catch (Exception e) {
log.error("Exception : "+ CommonUtil.writeErrorLog(e));
}
return resultList;
}Please let me know if I am missing anything here.
I have tried with 'FindByContent' and that is also failing.