I have a custom service written in .Net to fetch component data. This service uses SDL Web Delivery V 8.1.1 APIs and deployed on Delivery Server. I have separate servers for content and delivery.
In this service I fetch
GetComponentPresentationWithPriority method of
componentpresentation factory. I'm getting following error:
Invalid v4 service endpoint for content-service at Sdl.Web.Delivery.ContentService.AutoConfigure.get_ODataV4ServiceEndpoint() at Sdl.Web.Delivery.ContentService.ContentServiceProvider..ctor() at Sdl.Web.Delivery.ContentService.ContentServiceProvider.get_Instance() at Sdl.Web.Delivery.Dynamic.ComponentPresentationFactory.RetrieveComponentPresentation(Int32 paramPublicationId, String methodName, Object parameters) at Sdl.Web.Delivery.Dynamic.ComponentPresentationFactory.GetComponentPresentationWithPriority(Int32 componentId, Int32 priority) at Tridion.ContentDelivery.DynamicContent.ComponentPresentationFactory.GetComponentPresentationWithPriority(Int32 componentId, Int32 priority)
I have checked contentservice capability is set in discovery service and also re-run the utility to update capabilities. Tried using both http://localhost:8081//client/v4/content.svc and http://localhost:8081/content.svc endpoints for content service. Both give same error. The auth is also disabled for discovery and content service.
MORE INFO: When I try
ComponentPresentation cp1 = cpf.GetComponentPresentationWithHighestPriority(URI);
there is no error, but
null. I can see in broker DB content exists. And it happens for all components.
but at same time
ComponentPresentation cp = cpf.GetComponentPresentationWithPriority(componentId, priority);
throws above error.
I'm wondering how the API connects to content service and where it gets connection string from? I have tried modifying
Tridion_Home and adding
lib/config folder in bin folder of my custom service. But no success.