Solved

Indicium http 500 when trying to reach application

  • 15 November 2021
  • 4 replies
  • 111 views

Good morning, 

I currently have an application I would like to connect to from outside of the Thinkwise ecosystem.

I have tried browsing to this application using both the id and the alias, to no avail.

All of the required software has been installed. To make sure I also used the following thread: 

I also found this thread: 

This helped me to confirm that the application I am trying to reach is actually found. 

Below also a snippet of the error message that is being logged when trying to interact with the application:

2021-11-15T09:20:15.6792726+01:00 8000002d-000c-fd00-b63f-84710c7967bb [ERR] TSFMessagesMiddleware: An unhandled exception occurred while processing the request. (fffadd8a)
System.ArgumentException: An item with the same key has already been added. Key: empty_master_import
   at System.Collections.Generic.Dictionary`2.TryInsert(TKey key, TValue value, InsertionBehavior behavior)
   at Indicium.OData.ObjectModelConverter.convertTasksToODataModel(EdmModel edmModel, ApiObjectModel objectmodel, TSFEntityContainer container, IDttpCreator dttpCreator, EdmTypeReference complexReturnType) in C:\azp\agent\_work\1\s\src\Indicium\OData\ObjectModelConverter.cs:line 192
   at Indicium.OData.ObjectModelConverter.ConvertTSFObjectModelToODataModel(ApiObjectModel objectModel, IDttpCreator dttpCreator, List`1& modelValidationMessages) in C:\azp\agent\_work\1\s\src\Indicium\OData\ObjectModelConverter.cs:line 167
   at Indicium.OData.ApiModelCache.loadApiModel(String apiModelSignature, RoleSetInfo roleSetInfo, FullObjectModel fullModel, TSFRequestContext requestContext) in C:\azp\agent\_work\1\s\src\Indicium\OData\ApiModelCache.cs:line 163
   at Indicium.OData.ApiModelCache.<>c__DisplayClass10_0.<<GetModel>b__3>d.MoveNext() in C:\azp\agent\_work\1\s\src\Indicium\OData\ApiModelCache.cs:line 130
--- End of stack trace from previous location ---
   at Indicium.OData.ApiModelCache.<>c__DisplayClass10_0.<<GetModel>b__3>d.MoveNext() in C:\azp\agent\_work\1\s\src\Indicium\OData\ApiModelCache.cs:line 139
--- End of stack trace from previous location ---
   at Indicium.Shared.TSF.TSFMemoryCache`2.GetAddOrUpdate(TKey key, TimeSpan maximumAge, Func`2 add, Func`3 update) in C:\azp\agent\_work\1\s\src\Indicium.Shared\TSF\TSFMemoryCache.cs:line 105
   at Indicium.OData.ApiModelCache.GetModel(String guiApplAliasOrID, TSFRequestContext requestContext, ISession userSession) in C:\azp\agent\_work\1\s\src\Indicium\OData\ApiModelCache.cs:line 92
   at Indicium.OData.MetaSourceApiModelCache.GetApiModel(String metaSourceAliasOrID, String guiApplAliasOrID, TSFRequestContext requestContext, ISession userSession) in C:\azp\agent\_work\1\s\src\Indicium\OData\MetaSourceApiModelCache.cs:line 67
   at Indicium.OData.ODataRouteValueTransformer.TransformAsync(HttpContext httpContext, RouteValueDictionary values) in C:\azp\agent\_work\1\s\src\Indicium\OData\ODataRouteValueTransformer.cs:line 102
   at Microsoft.AspNetCore.Mvc.Routing.DynamicControllerEndpointMatcherPolicy.ApplyAsync(HttpContext httpContext, CandidateSet candidates)
   at Microsoft.AspNetCore.Routing.Matching.DfaMatcher.SelectEndpointWithPoliciesAsync(HttpContext httpContext, IEndpointSelectorPolicy[] policies, CandidateSet candidateSet)
   at Microsoft.AspNetCore.Routing.EndpointRoutingMiddleware.<Invoke>g__AwaitMatch|8_1(EndpointRoutingMiddleware middleware, HttpContext httpContext, Task matchTask)
   at Microsoft.AspNetCore.Session.SessionMiddleware.Invoke(HttpContext context)
   at Microsoft.AspNetCore.Session.SessionMiddleware.Invoke(HttpContext context)
   at Microsoft.AspNetCore.ResponseCompression.ResponseCompressionMiddleware.Invoke(HttpContext context)
   at Indicium.Middleware.Security.AuthenticationHeadersMiddleware.InvokeAsync(HttpContext context) in C:\azp\agent\_work\1\s\src\Indicium\Middleware\Authentication\AuthenticationHeadersMiddleware.cs:line 45
   at Indicium.Middleware.Security.SecurityHeadersMiddleware.InvokeAsync(HttpContext context, ContentSecurityPolicyBuilder cspBuilder) in C:\azp\agent\_work\1\s\src\Indicium\Middleware\Security\SecurityHeadersMiddleware.cs:line 48
   at Indicium.Middleware.Messages.TSFMessagesMiddleware.Invoke(HttpContext context, TSFRequestContext requestContext) in C:\azp\agent\_work\1\s\src\Indicium\Middleware\Messages\TSFMessageMiddleware.cs:line 42

 

Does anyone have a clue as to what could be my problem here?

Thanks in advance,

Peter Hiemstra

icon

Best answer by Mark Jongeling 15 November 2021, 10:42

View original

4 replies

Userlevel 7
Badge +23

Hi,

It could be that the object 'empty_master_import’ exists twice. That could happen if you have a table, task and/or report with the same name as another table, task and/or report. Can you check if that is the case? Be sure to also run all Validations for your project to find any additional errors.

Hope this helps!

@Mark Jongeling Thank you for the reply.

Unfortunately it seems that there is only one ‘empty_master_import’ object. I have also run all validations, and there are no errors which would indicate where my problem is coming from.

Userlevel 7
Badge +23

I've contacted the Indicium team and they confirm it should have something to do with object names being double; specifically a Task and a Report. Could you check again if that could be the case? It could even be a generated object.

Have you (re)synced the application model to IAM to ensure the application model in SF is the same as in IAM?

It could also be that some SQL-typed Control procedure code adds prefixes to objects and causing this problem although being unlikely :sweat_smile: .

@Mark Jongeling Finally got it working!

Since we couldn't identify the root cause of the problem, we decided to rename the task ‘empty_master_import’. Afterwards, we did a sync to the IAM and the application worked instantly. 

Many thanks for the help!

Reply