cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

ThingWorx Navigate is now Windchill Navigate Learn More

Translate the entire conversation x

Application Log Error "EntityNotFound" – Unable to Delete Thing

MM_9023322
15-Moonstone

Application Log Error "EntityNotFound" – Unable to Delete Thing

We are facing an issue in our ThingWorx environment with primary and secondary servers.

  • The application log is throwing EntityNotFound errors.

  • To resolve it temporarily, we added the missing Thing entity, which suppressed the error.

  • However, this is not a viable long-term solution as we intentionally deleted that entity and do not want it to exist.

Problem Details:

  • We are unable to delete the Thing again — neither via the Composer nor programmatically.

  • On attempting to delete, the application log shows an error: Unable to delete from DB.

  • It seems the Thing is still being pinged or referenced, but we are not able to trace from where this is happening.

  • We are unsure whether it’s an external system or internal service making calls to the deleted Thing.

    Is there a way to not to dig at the service/mashup/subscription level and still fix the application logging issue?

ACCEPTED SOLUTION

Accepted Solutions
GuillaumeL
14-Alexandrite
(To:MM_9023322)

Hi,

In fact the service is not even called. Per Design ThingWorx will raise an error if the Thing called (just after /Thing/) does not exist or user does not have permission to read it. I don't recommend to remove this specific error message from logs because in some cases it can be usefull for monitoring. However, here is some way to avoid this problem :

  • If your devices connects through an appkey, you can revoke this appkey. Error message won't appear anyomore in Application Logs but now in Security Logs.
  • otherwise you can try to block them through firewall or Tomcat black list
  • Instead of deleting things, you can desasctivate it, but you will still have a message like : Thing [MyThing] is not enabled
  • Or you can design your application not to delete thing, add some archived attribute and when the service on ThingWorx is called, check this attribute, if archived then log a custom message otherwise do the standard process

Best regards,

Guillaume

To try to delete again the thing, I would recomment to restart the server and then try again to delete them.

View solution in original post

3 REPLIES 3
GuillaumeL
14-Alexandrite
(To:MM_9023322)

Hi,

I guess that the best way to remove the application logs is to find who is calling this thing. As a security point of view, it could be a good option as well.

Did you try to check the 'access-log' file ? It can give the IP of the URL caller.

Best regards,

Guillaume

Hi @GuillaumeL ,

Thank you for the response. I was able to identify which devices are calling the Things. There are several devices making requests to the following endpoint:

Thingworx/Thing/DeviceID(Things)/Services/XYZ

I cannot modify the configuration on the device side, so these calls will continue. The devices first check for the DeviceId, and if it is not found, ThingWorx throws an "Entity Not Found" error.

Currently, there are 76 such Things. I do not want to add them back to ThingWorx. Instead, I would like to ignore these errors silently. 

Thank you

GuillaumeL
14-Alexandrite
(To:MM_9023322)

Hi,

In fact the service is not even called. Per Design ThingWorx will raise an error if the Thing called (just after /Thing/) does not exist or user does not have permission to read it. I don't recommend to remove this specific error message from logs because in some cases it can be usefull for monitoring. However, here is some way to avoid this problem :

  • If your devices connects through an appkey, you can revoke this appkey. Error message won't appear anyomore in Application Logs but now in Security Logs.
  • otherwise you can try to block them through firewall or Tomcat black list
  • Instead of deleting things, you can desasctivate it, but you will still have a message like : Thing [MyThing] is not enabled
  • Or you can design your application not to delete thing, add some archived attribute and when the service on ThingWorx is called, check this attribute, if archived then log a custom message otherwise do the standard process

Best regards,

Guillaume

To try to delete again the thing, I would recomment to restart the server and then try again to delete them.

Announcements


Top Tags