Gravatar for sjef.jenniskens@achmea.nl

Question by Sjef Jenniskens, Feb 10, 2017 5:15 AM

Rebuilding Index - StopRebuildException - HTTP 503

Currently I am trying to run a Coveo Cloud Trial installation. I have installe the following package: Coveo for Sitecore 80 4.0 (895).zip. I am serving my local instance over https. I am using SOLR as Searchprovider.

I have added the following lines to the Coveo.SearchProvider.Custom.Config to prevent warnings in the log:

<defaultIndexConfiguration>
  <skipSiteNameValidation>true</skipSiteNameValidation>
  <securityConfiguration>
    <skipSitecoreLoginCheck>true</skipSitecoreLoginCheck>
  </securityConfiguration>
</defaultIndexConfiguration>

I needed to add a to my web.config file of my local instance such that my Sitecore instance can make a connection to https://platform.cloud.coveo.com/.

I am using the following guide: https://developers.coveo.com/display/public/SitecoreV4/Installing+Coveo+for+Sitecore

At step 14 I have to rebuild the indexes, but the rebuilding of the indexes fail with the following exception:

Job started: Index_Update_IndexName=Coveo_master_index|#Exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> Coveo.CloudPlatformClient.Exceptions.StopRebuildException: An error occurred while querying indexed documents. ---> System.Net.WebException: The remote server returned an error: (503) Server Unavailable.
   at System.Net.HttpWebRequest.GetRequestStream(TransportContext& context)
   at System.Net.HttpWebRequest.GetRequestStream()
   at Coveo.Framework.Utils.Rest.HttpClient.CreateRequest(String p_Method, String p_Url, String p_Body, Boolean p_PreserveMethodOnRedirect)
   at Coveo.Framework.Utils.Rest.HttpClient.<>c__DisplayClass17.<PostRaw>b__16(String p_RequestUrl)
   at Coveo.Framework.Utils.Rest.HttpClient.ExecuteRequest(String p_Url, Func`2 p_CreateRequest, Int64 p_CallId)
   at Coveo.Framework.Utils.Rest.HttpClient.PostRaw(String p_Url, String p_Body)
   at Coveo.Framework.Utils.Rest.HttpClient.Post(String p_Url, String p_Body)
   at Coveo.SearchServiceProvider.Rest.SearchQueryHelper.ExecuteQuery(QueryParams p_QueryParams, String p_Username)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ExecuteQuery(QueryParams p_QueryParams)
   --- End of inner exception stack trace ---
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ExecuteQuery(QueryParams p_QueryParams)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.<>c__DisplayClass46.<CreateAddedDocumentsPoller>b__43(IIncrementingPollerController controller)
   at Coveo.Framework.Synchronization.IncrementingPoller.WaitUntilComplete()
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ProcessStopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.StopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentIndexer.StopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.Communication.CloudPlatformCommunication.StopRebuild(RebuildContext p_Context)
   at Coveo.SearchProvider.ProviderIndexBase.PerformRebuild(IProviderUpdateContext p_Context, Action`1 p_CrawlerAction)
   at Coveo.SearchProvider.ProviderIndexBase.Rebuild(IndexingOptions p_IndexingOptions, IProviderUpdateContext p_Context, Action`1 p_CrawlerAction)
   at Coveo.SearchProvider.ProviderIndex.TryPerformIndexingOperation(IndexingOptions p_IndexingOptions, Action p_Action)
   at Coveo.SearchProvider.ProviderIndex.Rebuild()
   --- End of inner exception stack trace ---
   at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
   at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
   at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at Sitecore.Reflection.ReflectionUtil.InvokeMethod(MethodInfo method, Object[] parameters, Object obj)
   at Sitecore.Jobs.JobRunner.RunMethod(JobArgs args)
   at (Object , Object[] )
   at Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args)
   at Sitecore.Jobs.Job.ThreadEntry(Object state)

The following is logged in the logfile:

ManagedPoolThread #6 10:11:10 INFO  [ Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler ProcessStopRebuild] [Rebuilding source "Coveo_master_index - {local-sitecore-instance}"] Waiting for documents to be uploaded to Coveo Cloud...
5360 10:11:10 INFO  [ Coveo.CloudPlatformClient.DocumentManagement.IndexableDocumentBatcher CommitBatch] Uploading document batch file to Coveo_master_index - {local-sitecore-instance} (2916487 bytes) (10 AddOrUpdate documents and 0 Delete documents).
5032 10:11:10 INFO  [ Coveo.CloudPlatformClient.DocumentManagement.IndexableDocumentBatcher CommitBatch] Uploading document batch file to Coveo_master_index - {local-sitecore-instance} (1042804 bytes) (10 AddOrUpdate documents and 0 Delete documents).
ManagedPoolThread #10 10:11:14 INFO  [ Sitecore.Diagnostics.Log Info] Job started: Sitecore.ListManagement.Analytics.UnlockContactListsAgent
ManagedPoolThread #10 10:11:14 INFO  [ Sitecore.Diagnostics.Log Info] Job ended: Sitecore.ListManagement.Analytics.UnlockContactListsAgent (units processed: )
ManagedPoolThread #6 10:11:16 INFO  [ Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler ProcessStopRebuild] [Rebuilding source "Coveo_master_index - {local-sitecore-instance}"] Documents are uploaded.
ManagedPoolThread #6 10:11:16 INFO  [ Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler ProcessStopRebuild] [Rebuilding source "Coveo_master_index - {local-sitecore-instance}"] Waiting for organization to be provisioned...
ManagedPoolThread #6 10:11:16 INFO  [ Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler ProcessStopRebuild] [Rebuilding source "Coveo_master_index - {local-sitecore-instance}"] Organization is provisioned.
ManagedPoolThread #6 10:11:16 INFO  [ Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler ProcessStopRebuild] [Rebuilding source "Coveo_master_index - {local-sitecore-instance}"] Waiting for documents to be searchable...
ManagedPoolThread #6 10:11:17 ERROR [ Coveo.SearchProvider.ProviderIndexBase PerformRebuild] [Rebuilding source "Coveo_master_index - {local-sitecore-instance}"] An error occurred while rebuilding index "Coveo_master_index".
Exception: Coveo.CloudPlatformClient.Exceptions.StopRebuildException
Message: An error occurred while querying indexed documents.
Source: Coveo.CloudPlatformClient
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ExecuteQuery(QueryParams p_QueryParams)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.<>c__DisplayClass46.<CreateAddedDocumentsPoller>b__43(IIncrementingPollerController controller)
   at Coveo.Framework.Synchronization.IncrementingPoller.WaitUntilComplete()
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ProcessStopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.StopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentIndexer.StopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.Communication.CloudPlatformCommunication.StopRebuild(RebuildContext p_Context)
   at Coveo.SearchProvider.ProviderIndexBase.PerformRebuild(IProviderUpdateContext p_Context, Action`1 p_CrawlerAction)

Nested Exception

Exception: System.Net.WebException
Message: The remote server returned an error: (503) Server Unavailable.
Source: System
   at System.Net.HttpWebRequest.GetRequestStream(TransportContext& context)
   at System.Net.HttpWebRequest.GetRequestStream()
   at Coveo.Framework.Utils.Rest.HttpClient.CreateRequest(String p_Method, String p_Url, String p_Body, Boolean p_PreserveMethodOnRedirect)
   at Coveo.Framework.Utils.Rest.HttpClient.<>c__DisplayClass17.<PostRaw>b__16(String p_RequestUrl)
   at Coveo.Framework.Utils.Rest.HttpClient.ExecuteRequest(String p_Url, Func`2 p_CreateRequest, Int64 p_CallId)
   at Coveo.Framework.Utils.Rest.HttpClient.PostRaw(String p_Url, String p_Body)
   at Coveo.Framework.Utils.Rest.HttpClient.Post(String p_Url, String p_Body)
   at Coveo.SearchServiceProvider.Rest.SearchQueryHelper.ExecuteQuery(QueryParams p_QueryParams, String p_Username)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ExecuteQuery(QueryParams p_QueryParams)


ManagedPoolThread #6 10:11:17 ERROR [ Coveo.SearchProvider.ProviderIndexBase Rebuild] An error while rebuilding occurred
Exception: Coveo.CloudPlatformClient.Exceptions.StopRebuildException
Message: An error occurred while querying indexed documents.
Source: Coveo.CloudPlatformClient
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ExecuteQuery(QueryParams p_QueryParams)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.<>c__DisplayClass46.<CreateAddedDocumentsPoller>b__43(IIncrementingPollerController controller)
   at Coveo.Framework.Synchronization.IncrementingPoller.WaitUntilComplete()
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ProcessStopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.StopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentIndexer.StopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.Communication.CloudPlatformCommunication.StopRebuild(RebuildContext p_Context)
   at Coveo.SearchProvider.ProviderIndexBase.PerformRebuild(IProviderUpdateContext p_Context, Action`1 p_CrawlerAction)
   at Coveo.SearchProvider.ProviderIndexBase.Rebuild(IndexingOptions p_IndexingOptions, IProviderUpdateContext p_Context, Action`1 p_CrawlerAction)

Nested Exception

Exception: System.Net.WebException
Message: The remote server returned an error: (503) Server Unavailable.
Source: System
   at System.Net.HttpWebRequest.GetRequestStream(TransportContext& context)
   at System.Net.HttpWebRequest.GetRequestStream()
   at Coveo.Framework.Utils.Rest.HttpClient.CreateRequest(String p_Method, String p_Url, String p_Body, Boolean p_PreserveMethodOnRedirect)
   at Coveo.Framework.Utils.Rest.HttpClient.<>c__DisplayClass17.<PostRaw>b__16(String p_RequestUrl)
   at Coveo.Framework.Utils.Rest.HttpClient.ExecuteRequest(String p_Url, Func`2 p_CreateRequest, Int64 p_CallId)
   at Coveo.Framework.Utils.Rest.HttpClient.PostRaw(String p_Url, String p_Body)
   at Coveo.Framework.Utils.Rest.HttpClient.Post(String p_Url, String p_Body)
   at Coveo.SearchServiceProvider.Rest.SearchQueryHelper.ExecuteQuery(QueryParams p_QueryParams, String p_Username)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ExecuteQuery(QueryParams p_QueryParams)


ManagedPoolThread #6 10:11:17 ERROR [ Sitecore.Diagnostics.Log Error] Exception
Exception: System.Reflection.TargetInvocationException
Message: Exception has been thrown by the target of an invocation.
Source: mscorlib
   at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
   at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
   at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at Sitecore.Reflection.ReflectionUtil.InvokeMethod(MethodInfo method, Object[] parameters, Object obj)
   at Sitecore.Jobs.JobRunner.RunMethod(JobArgs args)
   at (Object , Object[] )
   at Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args)
   at Sitecore.Jobs.Job.ThreadEntry(Object state)

Nested Exception

Exception: Coveo.CloudPlatformClient.Exceptions.StopRebuildException
Message: An error occurred while querying indexed documents.
Source: Coveo.CloudPlatformClient
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ExecuteQuery(QueryParams p_QueryParams)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.<>c__DisplayClass46.<CreateAddedDocumentsPoller>b__43(IIncrementingPollerController controller)
   at Coveo.Framework.Synchronization.IncrementingPoller.WaitUntilComplete()
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ProcessStopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.StopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentIndexer.StopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.Communication.CloudPlatformCommunication.StopRebuild(RebuildContext p_Context)
   at Coveo.SearchProvider.ProviderIndexBase.PerformRebuild(IProviderUpdateContext p_Context, Action`1 p_CrawlerAction)
   at Coveo.SearchProvider.ProviderIndexBase.Rebuild(IndexingOptions p_IndexingOptions, IProviderUpdateContext p_Context, Action`1 p_CrawlerAction)
   at Coveo.SearchProvider.ProviderIndex.TryPerformIndexingOperation(IndexingOptions p_IndexingOptions, Action p_Action)
   at Coveo.SearchProvider.ProviderIndex.Rebuild()

Nested Exception

Exception: System.Net.WebException
Message: The remote server returned an error: (503) Server Unavailable.
Source: System
   at System.Net.HttpWebRequest.GetRequestStream(TransportContext& context)
   at System.Net.HttpWebRequest.GetRequestStream()
   at Coveo.Framework.Utils.Rest.HttpClient.CreateRequest(String p_Method, String p_Url, String p_Body, Boolean p_PreserveMethodOnRedirect)
   at Coveo.Framework.Utils.Rest.HttpClient.<>c__DisplayClass17.<PostRaw>b__16(String p_RequestUrl)
   at Coveo.Framework.Utils.Rest.HttpClient.ExecuteRequest(String p_Url, Func`2 p_CreateRequest, Int64 p_CallId)
   at Coveo.Framework.Utils.Rest.HttpClient.PostRaw(String p_Url, String p_Body)
   at Coveo.Framework.Utils.Rest.HttpClient.Post(String p_Url, String p_Body)
   at Coveo.SearchServiceProvider.Rest.SearchQueryHelper.ExecuteQuery(QueryParams p_QueryParams, String p_Username)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ExecuteQuery(QueryParams p_QueryParams)

As a comparison; on a clean Sitecore instance with the defaultProxy config setting added and serving over http using Lucene as SearchProvier, I get the following error while rebuilding the index:

Job started: Index_Update_IndexName=Coveo_master_index|#Exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> Coveo.CloudPlatformClient.Exceptions.StopRebuildException: An error occurred while querying indexed documents. ---> Coveo.Framework.Utils.Rest.HttpClientException: Failed to obtain resource located at 'http://sc80rev150812/coveo/rest?pipeline='.

System.Net.WebException: The remote server returned an error: (404) Not Found.
   at System.Net.HttpWebRequest.GetResponse()
   at Coveo.Framework.Utils.Rest.HttpClient.ExecuteRequest(String p_Url, Func`2 p_CreateRequest, Int64 p_CallId)
   --- End of inner exception stack trace ---
   at Coveo.Framework.Utils.Rest.HttpClient.HandleResponseException(WebException p_Exception, String p_Url, Int64 p_CallId)
   at Coveo.Framework.Utils.Rest.HttpClient.ExecuteRequest(String p_Url, Func`2 p_CreateRequest, Int64 p_CallId)
   at Coveo.Framework.Utils.Rest.HttpClient.PostRaw(String p_Url, String p_Body)
   at Coveo.Framework.Utils.Rest.HttpClient.Post(String p_Url, String p_Body)
   at Coveo.SearchServiceProvider.Rest.SearchQueryHelper.ExecuteQuery(QueryParams p_QueryParams, String p_Username)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ExecuteQuery(QueryParams p_QueryParams)
   --- End of inner exception stack trace ---
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ExecuteQuery(QueryParams p_QueryParams)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.<>c__DisplayClass46.<CreateAddedDocumentsPoller>b__43(IIncrementingPollerController controller)
   at Coveo.Framework.Synchronization.IncrementingPoller.WaitUntilComplete()
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.ProcessStopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentsHandler.StopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.DocumentManagement.CloudPlatformDocumentIndexer.StopRebuild(RebuildContext p_Context)
   at Coveo.CloudPlatformClient.Communication.CloudPlatformCommunication.StopRebuild(RebuildContext p_Context)
   at Coveo.SearchProvider.ProviderIndexBase.PerformRebuild(IProviderUpdateContext p_Context, Action`1 p_CrawlerAction)
   at Coveo.SearchProvider.ProviderIndexBase.Rebuild(IndexingOptions p_IndexingOptions, IProviderUpdateContext p_Context, Action`1 p_CrawlerAction)
   at Coveo.SearchProvider.ProviderIndex.TryPerformIndexingOperation(IndexingOptions p_IndexingOptions, Action p_Action)
   at Coveo.SearchProvider.ProviderIndex.Rebuild()
   --- End of inner exception stack trace ---
   at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
   at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
   at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at Sitecore.Reflection.ReflectionUtil.InvokeMethod(MethodInfo method, Object[] parameters, Object obj)
   at Sitecore.Jobs.JobRunner.RunMethod(JobArgs args)
   at (Object , Object[] )
   at Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args)
   at Sitecore.Jobs.Job.ThreadEntry(Object state)
Gravatar for flguillemette@coveo.com

Comment by François Lachance-Guillemette, Feb 10, 2017 7:43 AM

Could you check if there are any errors in the diagnostic page?

It looks like your /coveo/rest endpoint returns a 503. This is the local endpoint we use to query the Coveo index.

Could you try to access it like http://YOUR_INSTANCE_NAME/coveo/rest ?

Gravatar for sjef.jenniskens@achmea.nl

Comment by Sjef Jenniskens, Feb 10, 2017 10:31 AM

Hello flguillemette ♦♦, I have answered your questions below.

2 Replies
Gravatar for sjef.jenniskens@achmea.nl

Answer by Sjef Jenniskens, Feb 10, 2017 10:30 AM

Yes, there are 503 errors on the diagnostic page.

Accessing my instance at /coveo/rest returns the following JSON:

{
    "totalCount": 31963,
    "totalCountFiltered": 31963,
    "duration": 108,
    "indexDuration": 43,
    "requestDuration": 72,
    "searchUid": "0467cabe-f96f-485d-b6c8-96654f786f5c",
    "pipeline": "default",
    "apiVersion": 2,
    "basicExpression": null,
    "advancedExpression": null,
    "largeExpression": null,
    "constantExpression": null,
    "disjunctionExpression": null,
    "mandatoryExpression": null,
    "userIdentities": [{
        "name": "sitecore\\admin",
        "provider": "Expanded Sitecore Security Provider for {local-sitecore-instance}",
        "type": "User"
    }, {
        "name": "anonymous@anonymous",
        "provider": "Email Security Provider",
        "type": "User"
    }],
    "rankingExpressions": [],
    "topResults": [],
    "index": "{sitename}-wjin2imdjulz6vz5muahebcl2y-Indexer-1-uikklcbnli26pupymlvczu2imu",
    "executionReport": {
        "duration": 119,
        "children": [{
            "description": "Perform authentication",
            "duration": 0,
            "configured": {
                "primary": "CloudToken",
                "secondary": [],
                "mandatory": []
            },
            "result": {
                "userIds": [{
                    "name": "sitecore\\admin",
                    "kind": "User",
                    "provider": "Expanded Sitecore Security Provider for {local-sitecore-instance}",
                    "infos": {}
                }, {
                    "name": "anonymous@anonymous",
                    "kind": "User",
                    "provider": "Email Security Provider",
                    "infos": {}
                }],
                "roles": ["queryExecutor"],
                "queryRestrictions": {
                    "pipeline": null,
                    "filter": null
                }
            },
            "children": [{
                "description": "Resolve authentication of provider: CloudToken",
                "duration": 0,
                "result": {
                    "userIds": [{
                        "name": "sitecore\\admin",
                        "kind": "User",
                        "provider": "Expanded Sitecore Security Provider for {local-sitecore-instance}",
                        "infos": {}
                    }, {
                        "name": "anonymous@anonymous",
                        "kind": "User",
                        "provider": "Email Security Provider",
                        "infos": {}
                    }],
                    "roles": ["queryExecutor"],
                    "queryRestrictions": {
                        "pipeline": null,
                        "filter": null
                    }
                }
            }, {
                "description": "Merge authentications (if needed)",
                "duration": 0,
                "result": {
                    "userIds": [{
                        "name": "sitecore\\admin",
                        "kind": "User",
                        "provider": "Expanded Sitecore Security Provider for {local-sitecore-instance}",
                        "infos": {}
                    }, {
                        "name": "anonymous@anonymous",
                        "kind": "User",
                        "provider": "Email Security Provider",
                        "infos": {}
                    }],
                    "roles": ["queryExecutor"],
                    "queryRestrictions": {
                        "pipeline": null,
                        "filter": null
                    }
                }
            }]
        }, {
            "description": "Resolve context",
            "duration": 1,
            "result": {
                "userAgent": {
                    "raw": "Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36",
                    "browser": ["chrome"],
                    "device": ["desktop", "pc", "windows"],
                    "os": ["windows"]
                },
                "expressions": {
                    "q": {
                        "original": "",
                        "parsed": null
                    },
                    "aq": {
                        "original": "",
                        "parsed": null
                    },
                    "cq": {
                        "original": "",
                        "parsed": null
                    },
                    "dq": {
                        "original": "",
                        "parsed": null
                    }
                },
                "enableDuplicateFiltering": false,
                "filterField": null,
                "filterFieldRange": 5,
                "parentField": null,
                "childField": null,
                "searchHub": null,
                "tab": null,
                "recommendation": null,
                "locale": null,
                "lowercaseOperators": false,
                "context": {},
                "sortCriteria": ["relevancy"]
            }
        }, {
            "description": "Resolve pipeline",
            "duration": 0,
            "result": {
                "pipeline": "default",
                "splitTest": null
            }
        }, {
            "description": "Resolve context",
            "duration": 1,
            "result": {
                "userAgent": {
                    "raw": "Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36",
                    "browser": ["chrome"],
                    "device": ["desktop", "pc", "windows"],
                    "os": ["windows"]
                },
                "expressions": {
                    "q": {
                        "original": "",
                        "parsed": null
                    },
                    "aq": {
                        "original": "",
                        "parsed": null
                    },
                    "cq": {
                        "original": "",
                        "parsed": null
                    },
                    "dq": {
                        "original": "",
                        "parsed": null
                    }
                },
                "enableDuplicateFiltering": false,
                "filterField": null,
                "filterFieldRange": 5,
                "parentField": null,
                "childField": null,
                "searchHub": null,
                "tab": null,
                "recommendation": null,
                "locale": null,
                "lowercaseOperators": false,
                "context": {},
                "sortCriteria": ["relevancy"]
            }
        }, {
            "description": "Apply \u0027queryParamOverride\u0027 rules",
            "duration": 0,
            "applied": []
        }, {
            "description": "Resolve context",
            "duration": 0,
            "result": {
                "userAgent": {
                    "raw": "Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36",
                    "browser": ["chrome"],
                    "device": ["desktop", "pc", "windows"],
                    "os": ["windows"]
                },
                "expressions": {
                    "q": {
                        "original": "",
                        "parsed": null
                    },
                    "aq": {
                        "original": "",
                        "parsed": null
                    },
                    "cq": {
                        "original": "",
                        "parsed": null
                    },
                    "dq": {
                        "original": "",
                        "parsed": null
                    }
                },
                "enableDuplicateFiltering": false,
                "filterField": null,
                "filterFieldRange": 5,
                "parentField": null,
                "childField": null,
                "searchHub": null,
                "tab": null,
                "recommendation": null,
                "locale": null,
                "lowercaseOperators": false,
                "context": {},
                "sortCriteria": ["relevancy"]
            }
        }, {
            "description": "Preprocess query",
            "duration": 31,
            "result": {
                "in": {
                    "q": null,
                    "aq": null,
                    "lq": null,
                    "cq": null,
                    "dq": null,
                    "mq": null,
                    "timezone": null,
                    "parentField": null,
                    "childField": null,
                    "filterField": null,
                    "filterFieldRange": 5,
                    "enableDuplicateFiltering": false,
                    "enableWildcards": false,
                    "enableQuestionMark": false,
                    "enableDidYouMean": false,
                    "enableCollaborativeRanking": false,
                    "enableRankingInformation": true,
                    "retrieveFirstSentences": false,
                    "firstResult": 0,
                    "numberOfResults": 10,
                    "excerptLength": 200,
                    "summaryLength": 0,
                    "includedFields": null,
                    "excludedFields": null,
                    "queryFunctions": [],
                    "rankingFunctions": [],
                    "sortCriteria": ["relevancy"],
                    "rankingExpressions": [],
                    "rankingOverrides": [],
                    "groupByRequests": []
                },
                "out": {
                    "q": null,
                    "aq": null,
                    "lq": null,
                    "cq": null,
                    "dq": null,
                    "mq": null,
                    "timezone": null,
                    "parentField": null,
                    "childField": null,
                    "filterField": null,
                    "filterFieldRange": 5,
                    "enableDuplicateFiltering": false,
                    "enableWildcards": false,
                    "enableQuestionMark": false,
                    "enableDidYouMean": false,
                    "enableCollaborativeRanking": false,
                    "enableRankingInformation": true,
                    "retrieveFirstSentences": false,
                    "firstResult": 0,
                    "numberOfResults": 10,
                    "excerptLength": 200,
                    "summaryLength": 0,
                    "includedFields": null,
                    "excludedFields": null,
                    "queryFunctions": [],
                    "rankingFunctions": [],
                    "sortCriteria": ["relevancy"],
                    "rankingExpressions": [],
                    "rankingOverrides": [],
                    "groupByRequests": []
                }
            },
            "children": [{
                "description": "Apply \u0027filter\u0027 rules",
                "duration": 0,
                "applied": []
            }, {
                "description": "Apply \u0027ranking\u0027 rules",
                "duration": 0,
                "applied": []
            }, {
                "description": "Apply \u0027top\u0027 rules",
                "duration": 0,
                "applied": []
            }, {
                "description": "Apply \u0027topClicks\u0027 rules",
                "duration": 0,
                "result": "TopClicksConfig(true,,,,P3M,P1D,P1W,250,false,true,false,5,PT10S,List(),Map())"
            }, {
                "description": "Calling \u0027topClicks\u0027 reveal service",
                "duration": 31,
                "config": {
                    "model": "generated_290c06d003169650be0797a5d073f2a5",
                    "engineVersion": "~2|~3",
                    "modifier": 250,
                    "maxResults": 5,
                    "matchQuery": false,
                    "matchAdvancedQuery": true
                },
                "basicQueryKeywords": [],
                "largeQueryKeywords": [],
                "userId": "sitecore\\admin",
                "actionHistories": [],
                "userContext": [],
                "response": {
                    "source": "reveal",
                    "predictions": [],
                    "refinedQueries": []
                }
            }, {
                "description": "Evaluate \u0027topClicks\u0027 reveal response",
                "duration": 0,
                "topResults": [],
                "refinedQueries": []
            }, {
                "description": "Apply \u0027recommendation\u0027 rules",
                "duration": 0,
                "result": "RecommendationConfig(false,,,,1000,P1W,PT0S,P1W,5,PT10S,true,List(),Map())"
            }, {
                "description": "Apply \u0027rankingweight\u0027 rules",
                "duration": 0,
                "applied": []
            }]
        }, {
            "description": "Send query to index",
            "duration": 76,
            "result": {
                "in": {
                    "BasicExpression": "@uri",
                    "AdvancedExpression": null,
                    "ConstantExpression": null,
                    "DisjunctionExpression": null,
                    "FirstResult": 0,
                    "NumberOfResults": 10,
                    "SortBy": "Relevancy",
                    "SortByFields": [],
                    "CustomFilter": null,
                    "CustomFilterRange": 5,
                    "ExcerptLength": 200,
                    "SummaryLength": 0,
                    "TimeZoneOffset": null,
                    "EnableWildcards": false,
                    "EnableQuestionMark": false,
                    "EnableDidYouMean": false,
                    "EnableCollaborativeRanking": false,
                    "DisableLogging": false,
                    "ParentFieldName": null,
                    "ChildFieldName": null,
                    "EnableDuplicateFiltering": false,
                    "ExtractFirstSentences": false,
                    "LoadTagsOnResults": true,
                    "EnableRankingInformation": true,
                    "TimeZone": null,
                    "RankingExpressions": [],
                    "RankingOverrides": [],
                    "Facets": []
                },
                "out": {
                    "exceptionCode": null,
                    "exceptionContext": null,
                    "logEntryId": "212353356672510857",
                    "serverTime": 43,
                    "requestTime": 72,
                    "totalCount": 31963,
                    "totalCountFiltered": 31963
                }
            }
        }, {
            "description": "Postprocess results",
            "duration": 0
        }, {
            "description": "Resolve triggers",
            "duration": 0,
            "children": [{
                "description": "Apply \u0027trigger\u0027 rules",
                "duration": 0,
                "applied": []
            }]
        }]
    },
    "triggers": [],
    "termsToHighlight": {},
    "phrasesToHighlight": {},
    "queryCorrections": [],
    "groupByResults": [],
    "results": [{

…left results out…

On both Coveo Search REST Endpoint and Coveo Security Service I am getting "The remote server returned an error: (503) Server Unavailable." at /sitecore%20modules/Web/Coveo/Admin/CoveoDiagnosticPage.aspx This is what my log says:

8136 16:24:58 ERROR [4be9086a-f1ba-46a3-8c15-a4c9e7c8061d Coveo.SearchProvider.Applications.BaseVerifier VerifyComponent] StateVerifier has encountered an error while verifying the component "Coveo Search REST Endpoint".
Exception: Coveo.SearchProvider.Applications.StateVerifierException
Message: The remote server returned an error: (503) Server Unavailable.
Source: Coveo.SearchProvider.Applications
   at Coveo.SearchProvider.Applications.CommonStateVerifier.GetResponseWhenPossible(WebRequest p_Request)
   at Coveo.SearchProvider.Applications.CommonStateVerifier.<>c__DisplayClassb.<GetRestEndpointState>b__a()
   at Coveo.SearchProvider.Applications.BaseVerifier.VerifyComponent(Func`1 p_VerifyMethod, String p_ComponentName)

8136 16:24:58 ERROR [4be9086a-f1ba-46a3-8c15-a4c9e7c8061d Coveo.SearchProvider.Applications.BaseVerifier VerifyComponent] StateVerifier has encountered an error while verifying the component "Coveo Security Service".
Exception: System.Net.WebException
Message: The remote server returned an error: (503) Server Unavailable.
Source: System
   at System.Net.HttpWebRequest.GetResponse()
   at Coveo.SearchProvider.Applications.CommonStateVerifier.<>c__DisplayClasse.<GetWebServiceState>b__d()
   at Coveo.SearchProvider.Applications.BaseVerifier.VerifyComponent(Func`1 p_VerifyMethod, String p_ComponentName)
Gravatar for flguillemette@coveo.com

Comment by François Lachance-Guillemette, Feb 13, 2017 7:47 AM

Since it is working when directly accessing the URL in your browser, we must find what is the difference between this call and the one we do from the diagnostic page.

Do you have a redirection rule for POST requests but not for GET requests?

Could you try with PostMan to do a POST request to /coveo/rest?

Gravatar for sjef.jenniskens@achmea.nl

Comment by Sjef Jenniskens, Feb 13, 2017 9:39 AM

I have tried both GET and POST request with PostMan, unfortunately no differences or clues leading to the error. There is no redirection rule for POST requests.

Gravatar for flguillemette@coveo.com

Comment by François Lachance-Guillemette, Feb 13, 2017 10:09 AM

Could you try adding ?pipeline= at the end of your GET call, and {pipeline:""} in your POST request? It is the only different thing I observed.

Gravatar for sjef.jenniskens@achmea.nl

Comment by Sjef Jenniskens, Feb 14, 2017 4:57 AM

Thanks for your help and suggestions sofar.

I have tried your suggestion but I am observing no differences that could help us in our quest.

GET https://{local-sitecore-instance}/coveo/rest?pipeline=

{
  "totalCount": 31963,
  "totalCountFiltered": 31963,
  "duration": 16,
  "indexDuration": 15,
  "requestDuration": 1,
  "searchUid": "e7ec8ba7-b37c-4c11-82a5-32fb316fbc7f",
  "pipeline": "empty",
  "apiVersion": 2,
  "triggers": [],
  "termsToHighlight": {},
  "phrasesToHighlight": {},
  "queryCorrections": [],
  "groupByResults": [],
  "results": [
    { ... }],  "refinedKeywords": []
}

POST https://{local-sitecore-instance}/coveo/rest with { "pipeline: ""} added to body.

{
  "totalCount": 31963,
  "totalCountFiltered": 31963,
  "duration": 7,
  "indexDuration": 15,
  "requestDuration": 2,
  "searchUid": "5491bd41-7a6f-4508-93a8-952323e8927a",
  "pipeline": "empty",
  "apiVersion": 2,
  "triggers": [],
  "termsToHighlight": {},
  "phrasesToHighlight": {},
  "queryCorrections": [],
  "groupByResults": [],
  "results": [
    { ... }], "refinedKeywords": []
}
Gravatar for sjef.jenniskens@achmea.nl

Answer by Sjef Jenniskens, Feb 17, 2017 8:55 AM

Ultimately this was an internal problem. Thank you for your time!

Gravatar for flguillemette@coveo.com

Comment by François Lachance-Guillemette, Feb 17, 2017 9:27 AM

Could you share us what the internal problem was?

Ask a question