Gravatar for johann@sidewalk.be

Question by joba, Jun 17, 2016 6:32 AM

Issue with the REST API

Hi,

I'm trying to install Coveo locally with Sitecore but I'm getting issue with the rest API (On-premise solution).

I've change the default port from 8080 to 9090 but impossible to make it work … I'm getting a 408 Server is Unavailable

I can go to : http://localhost:9090/ which is showing me a page with the message "This search page is not configured yet" (if i click on the button create a search configuration, it says that i don't have the permission …)

But i cannot go to : http://localhost:9090/rest/search

I've change the port in :

  • config.yml (by adding http: port: 9090)
  • Coveo.SearchProvider.Rest.config
  • Coveo.SearchProvider.Rest.Custom.config
  • In Iis the binding of Coveo Entreprise Search 7 Admin to :9090 (I don't th

No more idea where I need to change it to make it works or if there is another place where i need to configure it.

Everything else seems to work, I can index, go to the admin.

Thanks!

2 Replies
Gravatar for jflheureux@coveo.com

Answer by Jean-François L'Heureux, Jun 17, 2016 7:58 AM

Hi Joba,

I think you are close to a working setup. The config.yml change with http: port: 9090 is perfect. Same thing for the Coveo.SearchProvider.Rest.Custom.config file.

However, you should avoid modifying the Coveo for Sitecore configuration files that do not end with ".Custom.config" like Coveo.SearchProvider.Rest.config as those files will be overwritten at the next Coveo for Sitecore upgrade you will perform. Please revert your modification to this file.

The IIS website for "Coveo Enterprise Search 7" is not related at all to the Coveo Search API REST endpoint. It is only used for the CES7 Administration Tool. You should also revert your modification to this IIS website and set back its port to 8081.

Since your http://localhost:9090 is correctly configured, maybe the only thing that is missing is the "allowImpersonate: true" in your config.yml. This line is automatically added when you check the "This installation is part of a Sitecore integration" checkbox when installing Coveo Search API. If it is not present, have a look at a standard config.yml file example.

By the way, it is normal that http://localhost:9090/rest/search asks you for Windows credentials because when accessing it without an application secret, it uses the configured authentication methods to know who is the user trying to query the index. When Coveo for Sitecore accesses this URL, it passes the application secret and the Sitecore user to the REST endpoint.

I hope this helps,

Jeff

Gravatar for johann@sidewalk.be

Comment by joba, Jun 17, 2016 8:21 AM

Hey,

Thank you for you quick answer.

Good to know ;) I'll modify the config and the IIS website.

I've already the "allowImpersonate: true"

Here is my yml without the "standalone" requirements:

http: port: 9090

server: uri: https://localhost:52810 serverCertificatePath: clientCertificatePath:

applications:

  • name: Sample Application secret: mN7UZ7nhUTe61mCYb59riFQ3ubaiGbh4ROr6umenspeCd2TDOhHKtgQQ7eAY6fKTMkom5HEY1U93AoZCrHDyDGJK8L9qWqrnOu13 allowImpersonate: true

http://localhost:9090/rest/search does not ask me for my windows credentials, he's not displaying anything, he just say that "The site can't be reached".

When I go to : http://localhost:9090/ it's showing me the "This search page is not configured"

If I'm going to http://MyInstance/coveo/rest, I'm getting this error :

{"statusCode":408,"message":"Server is unavailable: (not specified,null)","type":"ServerUnavailableException","executionReport":[{"duration":4,"children":[{"description":"Perform authentication","duration":1,"configured":{"trust":null,"primary":["SearchToken","Windows"],"secondary":[],"admin":"NobodyAllowed","fallback":null,"mandatory":[]},"result":{"userIds":[{"name":"sitecore\admin","kind":"User","provider":"Sitecore Security Provider for W8-020031-CLIENTPOC","infos":{}}],"roles":["queryExecutor"],"queryRestrictions":{"pipeline":null,"filter":null,"scope":null}},"children":[{"description":"Resolve trust authentication","duration":0,"result":null},{"description":"Resolve authentication of provider: SearchToken","duration":0,"result":{"userIds":[{"name":"sitecore\admin","kind":"User","provider":"Sitecore Security Provider for W8-020031-CLIENTPOC","infos":{}}],"roles":["queryExecutor"],"queryRestrictions":{"pipeline":null,"filter":null,"scope":null}}},{"description":"Resolve authentication of provider: Windows","duration":0,"result":null},{"description":"Merge authentications (if needed)","duration":0,"result":{"userIds":[{"name":"sitecore\admin","kind":"User","provider":"Sitecore Security Provider for W8-020031-CLIENTPOC","infos":{}}],"roles":["queryExecutor"],"queryRestrictions":{"pipeline":null,"filter":null,"scope":null}}},{"description":"Resolve fallback (if needed)","duration":0,"result":{"userIds":[{"name":"sitecore\admin","kind":"User","provider":"Sitecore Security Provider for W8-020031-CLIENTPOC","infos":{}}],"roles":["queryExecutor"],"queryRestrictions":{"pipeline":null,"filter":null,"scope":null}}}]},{"description":"Resolve context","duration":0,"result":{"scope":-1,"userAgent":{"raw":"Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.84 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,"language":null,"lowercaseOperators":false,"context":{},"sortCriteria":["relevancy"]}},{"description":"Resolve pipeline","duration":0,"result":{"pipeline":"default","splitTest":null}},{"description":"Resolve identities","duration":0,"result":[{"name":"sitecore\admin","type":"User","provider":"Sitecore Security Provider for W8-020031-CLIENTPOC","infos":{}}]},{"description":"Resolve context","duration":1,"result":{"scope":-1,"userAgent":{"raw":"Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.84 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,"language":null,"lowercaseOperators":false,"context":{},"sortCriteria":["relevancy"]}},{"description":"Preprocess query","duration":0,"result":{"in":{"q":null,"aq":null,"cq":null,"dq":null,"mq":null,"timezone":null,"parentField":null,"childField":null,"filterField":null,"filterFieldRange":5,"scope":-1,"enableDuplicateFiltering":false,"enableWildcards":false,"enableQuestionMark":false,"enableDidYouMean":false,"enableCollaborativeRanking":false,"enableRankingInformation":false,"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,"cq":null,"dq":null,"mq":null,"timezone":null,"parentField":null,"childField":null,"filterField":null,"filterFieldRange":5,"scope":-1,"enableDuplicateFiltering":false,"enableWildcards":false,"enableQuestionMark":false,"enableDidYouMean":false,"enableCollaborativeRanking":false,"enableRankingInformation":false,"retrieveFirstSentences":false,"firstResult":0,"numberOfResults":10,"excerptLength":200,"summaryLength":0,"includedFields":null,"excludedFields":null,"queryFunctions":[],"rankingFunctions":[],"sortCriteria":["relevancy"],"rankingExpressions":[],"rankingOverrides":[],"groupByRequests":[]}},"children":[{"description":"Apply \u0027ranking\u0027 rules","duration":0,"applied":[]},{"description":"Apply \u0027top\u0027 rules","duration":0,"applied":[]},{"description":"Apply \u0027rankingweight\u0027 rules","duration":0,"applied":[]}]},{"description":"Send query to index","error":"Server is unavailable: (not specified,null)"}]}],"results":[]}

And this is the log of Coveo Rest API which is generated if I'm going to : http://myInstance/coveo/rest

14:13:04.241 [qtp1157740463-86] DEBUG org.eclipse.jetty.server.Server - REQUEST on HttpChannelOverHttp@70446d17{r=1,c=false,a=DISPATCHED,uri=//localhost:9090/rest/search/?&organizationId=poctest} GET //localhost:9090/rest/search/?&organizationId=poctest Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,/;q=0.8 Accept-Encoding: gzip, deflate, sdch Accept-Language: en-US,en;q=0.8 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.84 Safari/537.36 Upgrade-Insecure-Requests: 1 Coveo-Search-Token: eyJhbGciOiJIUzI1NiJ9.eyJ2OCI6ZmFsc2UsImV4cCI6MTQ2NjI1MTY3OSwiaWF0IjoxNDY2MTY1Mjc5LCJvcmdhbml6YXRpb24iOiJsb2NhbCIsInVzZXJJZHMiOlt7InByb3ZpZGVyIjoiU2l0ZWNvcmUgU2VjdXJpdHkgUHJvdmlkZXIgZm9yIFc4LTAyMDAzMS1ET00iLCJuYW1lIjoic2l0ZWNvcmVcXGFkbWluIiwidHlwZSI6IlVzZXIifV0sInJvbGVzIjpbInF1ZXJ5RXhlY3V0b3IiXX0.Kzb3a2vFobNWelSWsLcksciNvBP9p4MZ13O6wfVt9c Host: localhost:9090 Cookie: UnicornLogVerbosity=Error; sitecorewebeditribbon=1; scContentEditorFoldersWidth=631; ASP.NETSessionId=k5ucmub50ahpvzyee1e1bx0u; shell#lang=en; _RequestVerificationToken=5xy9AUC1qBIWK0C3rgAaXoTr8p07iHk7VqdXjv5XV7UJHvUFThjYbV266ogpRkQ3CvYREVRpvxfy4ZM8PgpfoH1dv7zJ9vpLmpemWGVfgA1; sc_fv=21.0.0; _CSRFCOOKIE=73612cd8-ac60-4478-b4e9-fbc8450e3f53; coveowebsite#lang=en; .ASPXAUTH=4B2921BE0C895ED68C8CFA8317381CCC71A3ADC663C65EC808771A2F7421E9875B817B5EDF952F3072BDB4187EA6E623711C65FC5AF0AC1F23FA3BF823FE40CEFDB335E0162191BF3FAC7A8B6AF26FD83D7DBAAD4DB75A54BEF7286FE28B303F2FE4F977F79EA34A3F3D6F12E32E98DC72D5EA1F8BB39D9AACDC3AC519CA9015BB1FDB2FCF352D6D25DDB287E01FBD85; sitecore_userticket=87D23B7CE9D0459EA612C5D27A6C858B

14:13:04.245 [qtp1157740463-86] DEBUG c.c.s.api.rest.LocalSearchServlet - Authenticated Authentication(default,ArrayBuffer(UserId(sitecore\admin,Sitecore Security Provider for W8-020031-CLIENTPOC,User)),Some(QueryRestrictions(None,None,None)),false,None,Set(queryExecutor),Some(TokenParams(local,ArrayBuffer(UserId(sitecore\admin,Sitecore Security Provider for W8-020031-CLIENTPOC,User)),Some(Set(queryExecutor)),None,None,None,None,None,None,None,Some(1466251679000),false,None)),None) 14:13:04.249 [qtp1157740463-86] WARN c.c.s.api.rest.LocalSearchServlet - /rest/search/ triggered server unavailable exception: Server is unavailable: (not specified,null) com.coveo.search.api.endpoints.ServerUnavailableException: Server is unavailable: (not specified,null) at com.coveo.search.api.endpoints.soap.v7.SoapSearchEndpoint$.trapErrors(SoapSearchEndpoint.scala:191) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.endpoints.soap.v7.SoapSearchSession$$anonfun$executeQuery$1.apply(SoapSearchSession.scala:100) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.endpoints.soap.v7.SoapSearchSession$$anonfun$executeQuery$1.apply(SoapSearchSession.scala:97) ~[coveo-search-api-server.jar:na] at scala.util.DynamicVariable.withValue(DynamicVariable.scala:58) [coveo-search-api-server.jar:na] at com.coveo.search.api.EvaluationReport.execute(EvaluationReport.scala:35) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.endpoints.soap.v7.SoapSearchSession.executeQuery(SoapSearchSession.scala:97) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.RestSearchService$$anonfun$performQuery$1$$anonfun$apply$1$$anonfun$3$$anonfun$apply$4.apply(RestSearchService.scala:125) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.RestSearchService$$anonfun$performQuery$1$$anonfun$apply$1$$anonfun$3$$anonfun$apply$4.apply(RestSearchService.scala:125) ~[coveo-search-api-server.jar:na] at com.coveo.commons.scala.metrics.StatsDTimer.time(StatsDTimer.scala:13) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.RestSearchService$$anonfun$performQuery$1$$anonfun$apply$1$$anonfun$3.apply(RestSearchService.scala:124) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.RestSearchService$$anonfun$performQuery$1$$anonfun$apply$1$$anonfun$3.apply(RestSearchService.scala:124) ~[coveo-search-api-server.jar:na] at com.coveo.commons.scala.metrics.StatsDTimer.time(StatsDTimer.scala:13) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.RestSearchService$$anonfun$performQuery$1$$anonfun$apply$1.apply(RestSearchService.scala:123) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.RestSearchService$$anonfun$performQuery$1$$anonfun$apply$1.apply(RestSearchService.scala:110) ~[coveo-search-api-server.jar:na] at com.coveo.commons.scala.metrics.StatsDTimer.time(StatsDTimer.scala:13) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.RestSearchService$$anonfun$performQuery$1.apply(RestSearchService.scala:110) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.RestSearchService$$anonfun$performQuery$1.apply(RestSearchService.scala:110) ~[coveo-search-api-server.jar:na] at com.coveo.commons.scala.metrics.StatsDTimer.time(StatsDTimer.scala:13) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.RestSearchService.performQuery(RestSearchService.scala:109) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.RestSearchService.performQueryAndReturnJson(RestSearchService.scala:87) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.BaseSearchServlet$class.doExecuteQueryInJsonFormat(BaseSearchServlet.scala:116) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.BaseSearchServlet$class.com$coveo$search$api$rest$search$BaseSearchServlet$$doExecuteQuery(BaseSearchServlet.scala:97) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.BaseSearchServlet$$anonfun$5.apply(BaseSearchServlet.scala:84) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.BaseSearchServlet$$anonfun$5.apply(BaseSearchServlet.scala:84) ~[coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$class.org$scalatra$ScalatraBase$$liftAction(ScalatraBase.scala:285) [coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$$anonfun$invoke$1.apply(ScalatraBase.scala:279) ~[coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$$anonfun$invoke$1.apply(ScalatraBase.scala:279) ~[coveo-search-api-server.jar:na] at org.scalatra.ApiFormats$class.withRouteMultiParams(ApiFormats.scala:189) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.withRouteMultiParams(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$class.invoke(ScalatraBase.scala:278) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.org$scalatra$json$JsonSupport$$super$invoke(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.json.JsonSupport$$anonfun$invoke$1.apply(JsonSupport.scala:88) ~[coveo-search-api-server.jar:na] at org.scalatra.json.JsonSupport$$anonfun$invoke$1.apply(JsonSupport.scala:82) ~[coveo-search-api-server.jar:na] at org.scalatra.ApiFormats$class.withRouteMultiParams(ApiFormats.scala:189) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.withRouteMultiParams(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.json.JsonSupport$class.invoke(JsonSupport.scala:82) ~[coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.invoke(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$$anonfun$runRoutes$1$$anonfun$apply$8.apply(ScalatraBase.scala:253) ~[coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$$anonfun$runRoutes$1$$anonfun$apply$8.apply(ScalatraBase.scala:251) ~[coveo-search-api-server.jar:na] at scala.Option.flatMap(Option.scala:171) ~[coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$$anonfun$runRoutes$1.apply(ScalatraBase.scala:251) ~[coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$$anonfun$runRoutes$1.apply(ScalatraBase.scala:250) ~[coveo-search-api-server.jar:na] at scala.collection.immutable.Stream.flatMap(Stream.scala:493) ~[coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$class.runRoutes(ScalatraBase.scala:250) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.runRoutes(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$class.runActions$1(ScalatraBase.scala:175) [coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$$anonfun$executeRoutes$1.apply$mcV$sp(ScalatraBase.scala:187) ~[coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$$anonfun$executeRoutes$1.apply(ScalatraBase.scala:187) ~[coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$$anonfun$executeRoutes$1.apply(ScalatraBase.scala:187) ~[coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$class.org$scalatra$ScalatraBase$$cradleHalt(ScalatraBase.scala:205) [coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$class.executeRoutes(ScalatraBase.scala:187) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.executeRoutes(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$$anonfun$handle$1.apply$mcV$sp(ScalatraBase.scala:126) [coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$$anonfun$handle$1.apply(ScalatraBase.scala:126) [coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$$anonfun$handle$1.apply(ScalatraBase.scala:126) [coveo-search-api-server.jar:na] at scala.util.DynamicVariable.withValue(DynamicVariable.scala:58) [coveo-search-api-server.jar:na] at org.scalatra.DynamicScope$class.withResponse(DynamicScope.scala:78) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.withResponse(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.DynamicScope$$anonfun$withRequestResponse$1.apply(DynamicScope.scala:58) [coveo-search-api-server.jar:na] at scala.util.DynamicVariable.withValue(DynamicVariable.scala:58) [coveo-search-api-server.jar:na] at org.scalatra.DynamicScope$class.withRequest(DynamicScope.scala:69) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.withRequest(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.DynamicScope$class.withRequestResponse(DynamicScope.scala:57) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.withRequestResponse(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.ScalatraBase$class.handle(ScalatraBase.scala:125) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.org$scalatra$servlet$ServletBase$$super$handle(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.servlet.ServletBase$class.handle(ServletBase.scala:53) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.org$scalatra$CorsSupport$$super$handle(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.CorsSupport$$anonfun$handle$1.apply$mcV$sp(CORSSupport.scala:212) [coveo-search-api-server.jar:na] at org.scalatra.CorsSupport$$anonfun$handle$1.apply(CORSSupport.scala:200) [coveo-search-api-server.jar:na] at org.scalatra.CorsSupport$$anonfun$handle$1.apply(CORSSupport.scala:200) [coveo-search-api-server.jar:na] at scala.util.DynamicVariable.withValue(DynamicVariable.scala:58) [coveo-search-api-server.jar:na] at org.scalatra.DynamicScope$class.withResponse(DynamicScope.scala:78) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.withResponse(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.DynamicScope$$anonfun$withRequestResponse$1.apply(DynamicScope.scala:58) [coveo-search-api-server.jar:na] at scala.util.DynamicVariable.withValue(DynamicVariable.scala:58) [coveo-search-api-server.jar:na] at org.scalatra.DynamicScope$class.withRequest(DynamicScope.scala:69) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.withRequest(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.DynamicScope$class.withRequestResponse(DynamicScope.scala:57) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.withRequestResponse(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.CorsSupport$class.handle(CORSSupport.scala:199) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.handle(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.scalatra.ScalatraServlet$class.service(ScalatraServlet.scala:60) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.service(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at javax.servlet.http.HttpServlet.service(HttpServlet.java:790) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.com$coveo$search$api$rest$search$BaseSearchServlet$$super$service(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.BaseSearchServlet$$anonfun$service$1.apply$mcV$sp(BaseSearchServlet.scala:54) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.BaseSearchServlet$$anonfun$service$1.apply(BaseSearchServlet.scala:54) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.BaseSearchServlet$$anonfun$service$1.apply(BaseSearchServlet.scala:54) [coveo-search-api-server.jar:na] at scala.util.DynamicVariable.withValue(DynamicVariable.scala:58) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.search.BaseSearchServlet$class.service(BaseSearchServlet.scala:53) [coveo-search-api-server.jar:na] at com.coveo.search.api.rest.LocalSearchServlet.service(LocalSearchServlet.scala:12) [coveo-search-api-server.jar:na] at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:821) [coveo-search-api-server.jar:na] at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:583) [coveo-search-api-server.jar:na] at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:224) [coveo-search-api-server.jar:na] at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1158) [coveo-search-api-server.jar:na] at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:511) [coveo-search-api-server.jar:na] at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:185) [coveo-search-api-server.jar:na] at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1090) [coveo-search-api-server.jar:na] at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141) [coveo-search-api-server.jar:na] at org.eclipse.jetty.server.handler.gzip.GzipHandler.handle(GzipHandler.java:437) [coveo-search-api-server.jar:na] at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:119) [coveo-search-api-server.jar:na] at org.eclipse.jetty.server.Server.handle(Server.java:517) [coveo-search-api-server.jar:na] at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:308) [coveo-search-api-server.jar:na] at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:242) [coveo-search-api-server.jar:na] at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:261) [coveo-search-api-server.jar:na] at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:95) [coveo-search-api-server.jar:na] at org.eclipse.jetty.io.SelectChannelEndPoint$2.run(SelectChannelEndPoint.java:75) [coveo-search-api-server.jar:na] at org.eclipse.jetty.util.thread.strategy.ExecuteProduceConsume.produceAndRun(ExecuteProduceConsume.java:213) [coveo-search-api-server.jar:na] at org.eclipse.jetty.util.thread.strategy.ExecuteProduceConsume.run(ExecuteProduceConsume.java:147) [coveo-search-api-server.jar:na] at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:654) [coveo-search-api-server.jar:na] at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:572) [coveo-search-api-server.jar:na] at java.lang.Thread.run(Thread.java:745) [na:1.8.0_45] 14:13:04.258 [qtp1157740463-86] DEBUG org.eclipse.jetty.server.Server - RESPONSE for /rest/search/ h=true 408 null Date: Fri, 17 Jun 2016 12:13:04 GMT Cache-Control: no-cache, no-store, must-revalidate, private Content-Type: application/json; charset=utf-8

If you got any idea :<

Gravatar for jflheureux@coveo.com

Comment by Jean-François L'Heureux, Jun 17, 2016 8:35 AM

I see that you don't have any serverCertificatePath or clientCertificatePath in your config.yml. Those settings are mandatory.

serverCertificatePath should be the path to the CES7 index's cert-ca.pem certificate file.

clientCertificatePath should be the path to the CES7 index's cert-iis.p12 certificate file.

You can have a look here for an example configuration: https://developers.coveo.com/display/SitecoreV4/Understanding+the+Search+API's+configuration+file+(config.yml)+-+On-Premises

After modifying the config.yml, you need to restart the Coveo Search API service for the changes to be used.

Gravatar for johann@sidewalk.be

Comment by joba, Jun 17, 2016 10:55 AM

Owwww … What a stupid error :P didn't saw it …

Well thanks it works perfectly now ;)

Johann

Gravatar for jflheureux@coveo.com

Comment by Jean-François L'Heureux, Jun 17, 2016 11:06 AM

Normally, Coveo for Sitecore is supposed to configure those 2 paths automatically when it detects the Coveo Search API service isn't running. In your case, the service was probably running or wasn't installed yet when you installed the Coveo for Sitecore package.

I'm glad it is working.

Gravatar for ftremblay@coveo.com

Answer by François Tremblay, Apr 21, 2017 3:11 PM

The following topic has been created in our help to document the procedure to change the rest API port https://developers.coveo.com/x/fhkvAg

Ask a question