2

enter code hereWe are configuring DXA 2.0 CTP .Net website on windows server 2008 R2 .All microservice are configured on same server.While accessing the website getting below error in site.log file

ERROR - Failed to execute query
Sdl.Web.Delivery.Service.ServiceQueryException: Failed to execute query ---> Microsoft.OData.Client.DataServiceQueryException: An error occurred while processing this request. ---> Microsoft.OData.Client.DataServiceClientException: {"timestamp":"2017-12-06T14:36:19.241+0000","status":500,"error":"Internal Server Error","exception":"com.sdl.odata.client.api.exception.ODataClientHttpError","message":"Unable to get response from OData service: No Response.","path":"/ModelService/GetPublicationMappingsFunctionImport(Url='http://gbk-staging.khayal.net/')"}
   at Microsoft.OData.Client.QueryResult.ExecuteQuery()
   at Microsoft.OData.Client.DataServiceRequest.Execute[TElement](DataServiceContext context, QueryComponents queryComponents)
   --- End of inner exception stack trace ---
   at Microsoft.OData.Client.DataServiceRequest.Execute[TElement](DataServiceContext context, QueryComponents queryComponents)
   at Microsoft.OData.Client.DataServiceContext.InnerSynchExecute[TElement](Uri requestUri, String httpMethod, Nullable`1 singleResult, OperationParameter[] operationParameters)
   at Microsoft.OData.Client.DataServiceContext.Execute[TElement](Uri requestUri)
   at Sdl.Web.Delivery.Service.ODataV4Service.<>c__DisplayClass19_1`1.<Execute>b__1()
   at Sdl.Web.Delivery.Caching.CacheHandlers.DefaultMemCache.DefaultMemCacheHandler`1.SetOrGetExisting(String key, String region, Func`1 valueFactory, CacheItemPolicy cacheItemPolicy)
   at Sdl.Web.Delivery.Service.ODataV4Service.<>c__DisplayClass19_0`1.<Execute>b__0()
   --- End of inner exception stack trace ---
   at Sdl.Web.Delivery.Service.AbstractODataService.HandleHttpResponseCode(Exception e, Int32 statusCode)
   at Sdl.Web.Delivery.Service.ODataV4Service.<>c__DisplayClass19_0`1.<Execute>b__0()
   at Sdl.Web.Delivery.Service.Utils.PerformRetry[T](Func`1 block, Int32 retryCount)
   at Sdl.Web.Delivery.Service.Utils.Retry[T](Func`1 block, Int32 retryCount, Boolean locking)
   at Sdl.Web.Delivery.Dynamic.DynamicMappingsRetrieverImpl.GetPublicationMapping(String url)
   at Tridion.ContentDelivery.DynamicContent.DynamicMappingsRetriever.GetPublicationMapping(String url)
   at Sdl.Web.Tridion.CdApiLocalizationResolver.ResolveLocalization(Uri url) in C:\Jenkins\workspace\DXAuto\stash\develop\net\build_webapp\Sdl.Web.Tridion\CdApiLocalizationResolver.cs:line 66
   at Sdl.Web.Mvc.Configuration.WebRequestContext.get_Localization() in C:\Jenkins\workspace\DXAuto\stash\develop\net\build_webapp\Sdl.Web.Mvc\Configuration\WebRequestContext.cs:line 25
   at Sdl.Web.Mvc.Statics.StaticContentModule.BeginRequest(Object sender, EventArgs e) in C:\Jenkins\workspace\DXAuto\stash\develop\net\build_webapp\Sdl.Web.Mvc\Statics\StaticContentModule.cs:line 54

Below error in cd_client.log file

    ERROR [Sdl.Web.Delivery.ContentService.ContentServiceProvider..ctor]
            The service endpoint 'http://10.0.0.47:8085/ModelService/$metadata' was not reachable so version information is no longer available.

Error in dxa file for model-service is

 Error handling return value [type=org.springframework.http.ResponseEntity] [value=<500 Internal Server Error,{timestamp=Thu Dec 07 12:54:41 AST 2017, status=500, error=Internal Server Error, exception=com.sdl.odata.client.api.exception.ODataClientRuntimeException, message=Unable to perform action, path=/ModelService/RequestStartActionImport},{}>]
    HandlerMethod details: 
    Controller [org.springframework.boot.autoconfigure.web.BasicErrorController]
    Method [public org.springframework.http.ResponseEntity<java.util.Map<java.lang.String, java.lang.Object>> org.springframework.boot.autoconfigure.web.BasicErrorController.error(javax.servlet.http.HttpServletRequest)]

    org.springframework.web.HttpMediaTypeNotAcceptableException: Could not find acceptable representation
        at org.springframework.web.servlet.mvc.method.annotation.AbstractMessageConverterMethodProcessor.writeWithMessageConverters(AbstractMessageConverterMethodProcessor.java:201)
        at org.springframework.web.servlet.mvc.method.annotation.HttpEntityMethodProcessor.handleReturnValue(HttpEntityMethodProcessor.java:197)
        at org.springframework.web.method.support.HandlerMethodReturnValueHandlerComposite.handleReturnValue(HandlerMethodReturnValueHandlerComposite.java:81)
        at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:130)
        at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:827)
        at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:738)
        at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:85)
        at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:963)
        at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:897)
        at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:970)
        at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:872)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:648)
        at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:846)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:230)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
        at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:726)
        at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:471)
        at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:394)
        at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:311)
        at org.apache.catalina.core.StandardHostValve.custom(StandardHostValve.java:395)
        at org.apache.catalina.core.StandardHostValve.status(StandardHostValve.java:254)
        at org.apache.catalina.core.StandardHostValve.throwable(StandardHostValve.java:349)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:175)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:349)
        at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:784)
        at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
        at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:802)
        at org.apache.tomcat.util.net.Nio2Endpoint$SocketProcessor.doRun(Nio2Endpoint.java:1609)
        at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
        at org.apache.tomcat.util.net.AbstractEndpoint.processSocket(AbstractEndpoint.java:830)
        at org.apache.tomcat.util.net.Nio2Endpoint$Nio2SocketWrapper$4.completed(Nio2Endpoint.java:639)
        at org.apache.tomcat.util.net.Nio2Endpoint$Nio2SocketWrapper$4.completed(Nio2Endpoint.java:617)
        at sun.nio.ch.Invoker.invokeUnchecked(Unknown Source)
        at sun.nio.ch.Invoker$2.run(Unknown Source)
        at sun.nio.ch.AsynchronousChannelGroupImpl$1.run(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
        at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.lang.Thread.run(Unknown Source)
  • And if you try opening that url in a browser? Do you get any response? – Nuno Linhares Dec 6 '17 at 19:09
  • @NunoLinhares when i try to access '10.0.0.47:8085/ModelService/$metadata' i m getting this error "There was an unexpected error (type=Internal Server Error, status=500). Unable to get response from OData service: No Response." – Abdul Qadir Dec 7 '17 at 6:55
  • @NunoLinhares please see the edit i have added error logged in dxa file for model-service – Abdul Qadir Dec 7 '17 at 10:37
  • Looks like you content service is not responding, or throwing an error. Can you try connecting to it via a browser too? – Nuno Linhares Dec 7 '17 at 13:22
  • yes i tried and it is throwing same error which i updated in my question – Abdul Qadir Dec 7 '17 at 13:45
1

There was typo for ContentServiceCapability url inside discovery service config file after fixing the url and registering again using "java -jar discovery-registration.jar update" command fix this problem

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.