1

I am setting up an DXA 1.7 POC to use Smart Target. I am using the DXA Module 1.7 Sdl.Web.Modules.SmartTarget

I am getting an error when the DXA Model builder is running.

Below is the stack trace I am getting.

It looks to be related to the GetTriggerTypes call to the Smart Target Query service.

Sdl.Web.Experience.Client.ExperienceOptimizationClient.GetTriggerTypes()

I am following the DXA Module installation guide and it doesn't have any steps to do with setting up Triggers.

Does anyone have any pointers to start this investigation? Are there any good blog posts going through the setup of the DXA Smart Target Module?

Microsoft.OData.Client.DataServiceQueryException: An error occurred while processing this request. ---> Microsoft.OData.Client.DataServiceClientException: {"error":{"code":"9000","message":"java.lang.NullPointerException: null"}}
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.DataServiceQuery`1.GetEnumerator()
at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
at Sdl.Web.Experience.Client.ExperienceOptimizationClient.GetTriggerTypes(Int32 timeout)
at Tridion.SmartTarget.Utils.AmbientDataHelper.FilterTriggers(ClaimStore claimStore)
at Tridion.SmartTarget.Utils.AmbientDataHelper.GetTriggers(ClaimStore claimStore)
at Sdl.Web.Modules.SmartTarget.Mapping.SmartTargetModelBuilder.ExecuteSmartTargetQuery(SmartTargetPageModel smartTargetPageModel, Localization localization) in C:\Code\DXA\dxa-modules\webapp-net\ExperienceOptimization\Mapping\SmartTargetModelBuilder.cs:line 211
at Sdl.Web.Modules.SmartTarget.Mapping.SmartTargetModelBuilder.BuildPageModel(PageModel& pageModel, IPage page, IEnumerable`1 includes, Localization localization) in C:\Code\DXA\dxa-modules\webapp-net\ExperienceOptimization\Mapping\SmartTargetModelBuilder.cs:line 92
at Sdl.Web.Tridion.Mapping.ModelBuilderPipeline.CreatePageModel(IPage page, IPage[] includes, Localization localization) in C:\Jenkins\workspace\DXA Dev CI Web App .NET\Sdl.Web.Tridion\Mapping\ModelBuilderPipeline.cs:line 78
at Sdl.Web.Tridion.Mapping.DefaultContentProvider.<>c__DisplayClass5_0.<GetPageModel>b__1() in C:\Jenkins\workspace\DXA Dev CI Web App .NET\Sdl.Web.Tridion\Mapping\DefaultContentProvider.cs:line 119
at Sdl.Web.Tridion.Caching.CacheProvider.GetOrAdd[T](String key, String region, Func`1 addFunction, IEnumerable`1 dependencies) in C:\Jenkins\workspace\DXA Dev CI Web App .NET\Sdl.Web.Tridion\Caching\CacheProvider.cs:line 65
at Sdl.Web.Tridion.Mapping.DefaultContentProvider.GetPageModel(String urlPath, Localization localization, Boolean addIncludes) in C:\Jenkins\workspace\DXA Dev CI Web App .NET\Sdl.Web.Tridion\Mapping\DefaultContentProvider.cs:line 131
at Sdl.Web.Mvc.Controllers.PageController.Page(String pageUrl) in C:\Jenkins\workspace\DXA Dev CI Web App .NET\Sdl.Web.Mvc\Controllers\PageController.cs:line 25

2 Answers 2

3

My guess is that you miss the SmartTarget ADF cartridge. The trigger types are stored as ADF claims. Check if that is setup correctly: https://docs.sdl.com/LiveContent/content/en-US/SDL%20Web-v5/GUID-59AC3854-A6E7-46F1-B34E-A56CDB6E4091

1
  • Hi Niclas, Thanks for the input I will run through the setup of the service again to check it is setup as it should. Commented Nov 14, 2017 at 11:23
3

There were two issues we have resolved to fix this specific issue. Thanks to Niclas pointing to the ADF claims.

The Query micro service was also throwing an error. There were some issues following the documentation:

https://docs.sdl.com/LiveContent/content/en-US/SDL%20Web%20Experience%20Optimization-v2/GUID-A6C8EBBA-EC6A-43FE-A7A0-142AC9DD3293

Location of the jars should be lib not services\experienceoptimization.

https://docs.sdl.com/LiveContent/content/en-US/SDL%20Web-v5/GUID-4B7742A5-F755-454F-A255-E5EAE7B1EC08

Port for the QueryServer should be 8180 not 9180. I think this is assuming you are doing a all in one box installation and not the default configuration for scaled out implementations.

2
  • If you find issues in the documenattion, please leave a comment there so they can be fixed. Commented Nov 14, 2017 at 16:07
  • You're wrong about the JAR files needing to be in 'lib'. They should be in their own folder, as documented. If you already had the service installed before adding XO, though, you will need to reinstall the service for it to pick up the new folder and add it to the class path. As for the ports being different, that is indeed a case of you using a different instance preset than what is covered in the described scenario. It's hard for the documentation to cover all possibilities while still being easy to follow. Commented Nov 28, 2017 at 12:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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