Gravatar for sathis.k.durairaj@accenture.com

Question by Sathis, Oct 30, 2015 7:01 AM

Coveo Search REST Endpoint () not found(404)

In CoveoDiagnosticPage i am getting below error message on Coveo Search REST Endpoint ().

The remote server returned an error: (404) Not Found. (Hide details)
System.Net.WebException: The remote server returned an error: (404) Not Found.
   at System.Net.HttpWebRequest.GetResponse()
   at Coveo.SearchProvider.Applications.StateVerifier.<>c__DisplayClassd.<GetRestEndpointState>b__c()
   at Coveo.SearchProvider.Applications.BaseVerifier.VerifyComponent(Func`1 p_VerifyMethod, String p_ComponentName)

Below steps i verified.

  1. http://localhost:52810/7.0/CoveoSearchService?wsdl is working
  2. http://localhost:8088/rest/search?q=test coveo search API is working
  3. All other Coveo services are and running.

any help is much appreciated.

Gravatar for jflheureux@coveo.com

Comment by Jean-François L'Heureux, Oct 30, 2015 7:39 AM

Can you paste your coveo.searchprovider.rest.config configuration? Is the url use port 8088?

Gravatar for sathis.k.durairaj@accenture.com

Comment by Sathis, Oct 30, 2015 7:56 AM

Content of the file:

<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/">
  <sitecore>
    <pipelines>
      <!-- Pipeline used to customize the JSON response of the search REST endpoint. -->
      <coveoProcessRestJsonResponse>
        <processor type="Coveo.SearchProvider.Rest.Processors.CoveoProcessRestJsonResponse.ParseJsonRestSearchResponseProcessor, Coveo.SearchProvider.Rest" />
      </coveoProcessRestJsonResponse>
      <!-- Pipeline used to customize the information returned by the REST endpoint. -->
      <coveoProcessParsedRestResponse>
        <!-- This processor resolves the REST results clickUri field in the context of the current site using the Sitecore LinkManager. -->
        <processor type="Coveo.SearchProvider.Rest.Processors.CoveoProcessParsedRestResponse.ResolveResultClickableUriProcessor, Coveo.SearchProvider.Rest" />
      </coveoProcessParsedRestResponse>
      <httpRequestBegin>
        <!-- This processor is required to ensure that requests targeting the REST endpoint are not handled by Sitecore. -->
        <processor patch:before="processor[@type = 'Sitecore.Pipelines.HttpRequest.ItemResolver, Sitecore.Kernel']" type="Coveo.SearchProvider.Rest.Processors.HttpRequestBegin.TransferCoveoRestSearchRequest, Coveo.SearchProvider.Rest" />
      </httpRequestBegin>
    </pipelines>
    <contentSearch>
      <configuration>
        <!-- Coveo Rest endpoint search settings -->
        <restEndpointConfiguration type="Coveo.Framework.Configuration.RestEndpointConfiguration, Coveo.Framework">
          <!-- The secret key must be configured in the search api service as well. This way, the search api service can trust the application. -->
          <ApplicationSecret>***removed</ApplicationSecret>
          <!-- The timeout period for requests going through the search api proxy.-->
          <RequestTimeout>00:00:30</RequestTimeout>
          <!-- Defines the location of the REST endpoint in the website. -->
          <RestEndpointPath>/coveo/rest</RestEndpointPath>
          <!-- The period while the search token is valid. -->
          <SearchTokenExpiration>01:00:00</SearchTokenExpiration>
          <!-- The URI to connect to the search api service. -->
          <SearchApiUri>http://localhost:8088/</SearchApiUri>
        </restEndpointConfiguration>
      </configuration>
    </contentSearch>
  </sitecore>
</configuration>
Gravatar for sathis.k.durairaj@accenture.com

Comment by Sathis, Oct 30, 2015 7:57 AM

yes correct it is running on 8088

Gravatar for lbergeron@coveo.com

Comment by Luc Bergeron, Oct 30, 2015 8:24 AM

The configuration seems fine. Did you try to browse to http:///coveo/rest ? When the call works, it returns a JSON response. In your cas, it will most likely throw an error. Maybe the error will be a little more detailed.

Also, could you take a look at the Search API logs and see if there is any error that could be related. The default location for these logs is C:\Program Files\Coveo Search API 8\logs.

Gravatar for sathis.k.durairaj@accenture.com

Comment by Sathis, Nov 3, 2015 11:31 AM

I am getting below error message. when i try to access coveo/rest .

{
    "executionReport": {
        "childs": [
            {
                "childs": [],
                "description": "Resolve pipeline",
                "duration": 15,
                "result": "None",
                "type": "QueryPipelineReport"
            },
            {
                "childs": [],
                "description": "Resolve identities",
                "duration": 2,
                "result": "ArrayBuffer(UserId(sitecore\\admin,Sitecore Security Provider for **** ,User,None,None))",
                "type": "QueryPipelineReport"
            },
            {
                "childs": [],
                "description": "Preprocess Query",
                "duration": 34,
                "logs": [
                    {
                        "message": "Applied ranking statements: .",
                        "severity": "INFO",
                        "timestamp": "+7"
                    },
                    {
                        "message": "Applied top statements: .",
                        "severity": "INFO",
                        "timestamp": "+12"
                    },
                    {
                        "message": "Applied reveal statements: .",
                        "severity": "INFO",
                        "timestamp": "+33"
                    }
                ],
                "result": "Query(null,null,null,null,null,List(relevancy),[],[],null,null,null,5,false,true,false,false,false,false,0,10,200,0,false,false,[])",
                "type": "QueryPipelineReport"
            }
        ],
        "description": "",
        "duration": 2446,
        "result": "(com.coveo.search.api.pipeline.PipelineContext@df41cbb,Query(null,null,null,null,null,List(relevancy),[],[],null,null,null,5,false,true,false,false,false,false,0,10,200,0,false,false,[]))",
        "type": "RootReport"
    },
    "message": "Call returned SOAP fault: class CES::SearchServerException: No user has been provided for the search request.",
    "statusCode": 400,
    "type": "ServerReturnedSoapFaultException"
}

I understand this issue should be resolved once we rebuild the index. Even index rebuild is not updating the index in CES. Below is the error message i am seeing in CES console.

The security provider "Sitecore Security Provider for ****" has encountered an exception: class CSP::SecurityInvalidUserGroupException: Unable to convert '<Member name="sitecore\ServicesAPI" type="User" />' into SID. Error message: class CGLWindows::WindowsInvalidUserGroupException: (ServicesAPI): LookupAccountNameW(sitecore\ServicesAPI) failed: No mapping between account names and security IDs was done. [0x00000534] | LookupAccountNameW(ServicesAPI@sitecore) failed: No mapping between account names and security IDs was done. [0x00000534] | LookupAccountNameW(sitecore , ServicesAPI) failed: The RPC server is unavailable. [0x000006ba].
Gravatar for jflheureux@coveo.com

Comment by Jean-François L'Heureux, Nov 5, 2015 3:48 PM

This second error is being investigated in a separate question: https://answers.coveo.com/questions/4884/coveo-for-sitecore-index-crawling-issue

Gravatar for jflheureux@coveo.com

Comment by Jean-François L'Heureux, Nov 9, 2015 9:55 AM

Hi Sathis,

Do you still have this Coveo Search REST Endpoint error after we fixed your security provider problem in your other question?

Gravatar for sathis.k.durairaj@accenture.com

Comment by Sathis, Nov 9, 2015 9:59 AM

Thanks… This one also resolved.

1 Reply
Gravatar for jflheureux@coveo.com

Answer by Jean-François L'Heureux, Nov 9, 2015 10:29 AM

Issue resolved after fixing the security provider issue in a separate post: https://answers.coveo.com/questions/4884/coveo-for-sitecore-index-crawling-issue

Ask a question