cancel
Showing results for 
Search instead for 
Did you mean: 

Runtime Exception while searching metadata

ashwanth
Champ in-the-making
Champ in-the-making
Hi,
I am developing a webscript that should search a folder for nodes with the property set to a particular value. Following is the code and I have also copied the metadata of on the nodes for reference. While trying to execute this webscript, I am getting the error copied below. I can send the post the full stacktrace if necessary. Can someone please help me identify the issue? Thank you.

Error:
<response>
<status>
500

<name>Internal Error</name>
<description>An error inside the HTTP server which prevented it from fulfilling the request.</description>
</status>
<message>00150009 Wrapped Exception (with status template): 00150052 Failed to execute script 'classpath*:alfresco/templates/webscripts/gov/iowaworkforcedevelopment/tradeact/getTAAStatus.post.js': 00150051 Failed to execute search: @cm\Smiley TonguearticipantProfileID:"39b1e07af0b806b0aebeb95e0b20f00e"</message><exception>org.springframework.extensions.webscripts.WebScriptException - 00150009 Wrapped Exception (with status template): 00150052 Failed to execute script 'classpath*:alfresco/templates/webscripts/gov/iowaworkforcedevelopment/tradeact/getTAAStatus.post.js': 00150051 Failed to execute search: @cm\Smiley TonguearticipantProfileID:"39b1e07af0b806b0aebeb95e0b20f00e"</exception><callstack>
      org.alfresco.error.AlfrescoRuntimeException: 00150050 No solr query support for store workspace://SpacesStore/fdd97119-0dd7-438c-895e-a7e06ee58a88
         org.alfresco.repo.search.impl.solr.SolrQueryHTTPClient.executeQuery(SolrQueryHTTPClient.java:224)
         org.alfresco.repo.search.impl.solr.SolrQueryLanguage.executeQuery(SolrQueryLanguage.java:49)
         org.alfresco.repo.search.impl.solr.SolrSearchService.query(SolrSearchService.java:348)
         org.alfresco.repo.search.SearcherComponent.query(SearcherComponent.java:78)
         sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
         sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
         java.lang.reflect.Method.invoke(Method.java:606)

Code:
if(participantId == '' || participantId == null){
   logger.log('TAA does not have participant id:' + participantId);
   ret.error.errorMessage = 'Participant ID - ' + participantId + ', does not exist.';
} else {
   logger.log('Participant id:' + participantId + " is available");
   var partcipantFolder = companyhome.childByNamePath("iwdtaapart");
   var participantFolderNodeRef = partcipantFolder.nodeRef;
   var node = search.luceneSearch(participantFolderNodeRef, "@cm\\Smiley TonguearticipantProfileID:\"" + participantId + "\"");

   var participantStatus = node.properties["ParticipantStatus"];
   returnXml.status = participantStatus;
}

Metadata:
{"mimetype":"application/octet-stream","aspects":["{http://www.alfresco.org/model/content/1.0}auditable','{http://www.alfresco.org/model/system/1.0}refe..."],"nodeRef":"workspace://SpacesStore/6292d6b0-c058-41a8-8136-c944bf395242","properties":{…"{http://www.iowaworkforce.com/model/Participant/1.0}ParticipantStatus':'In Progress",…"{http://www.iowaworkforce.com/model/Participant/1.0}ParticipantProfileID':'39b1e07af0b806b0aebeb95e0b..."}
1 REPLY 1

mlagneaux
Champ on-the-rise
Champ on-the-rise
Hello,

Your search seems to be executed on a store that is not indexed by SolR.
Could you tell us which node the nodeRef workspace://SpacesStore/fdd97119-0dd7-438c-895e-a7e06ee58a88 refers to?
Does your search work correctly when executed from the node browser?