Article - CS239982

ThingWorx fails to persist updates and returns error "Error occurred while accessing the data provider"

Modified: 21-Jan-2025   


Applies To

  • ThingWorx Platform 7.0 to 9.7

Description

  • Error occurred while accessing the data provider error message returned in ThingworxStorage/logs/ApplicationLog.log when running a custom service in ThingWorx
  • Updates in ThingWorx are failing following migration/upgrade
  • Error when running DataTable service AddDataTableEntries in ThingworxStorage/logs/ApplicationLog.log:
Unable to Invoke Service AddDataTableEntries on <DataTableName>: com.tingworx.common.exceptions.DataAccessException:[1,018] Data store unknown error: [Error occurred while accessing the data provider.]
  • ThingWorx server was briefly inoperable due to error in ThingworxStorage/logs/ApplicationLog.log:
[message: [1,018] Data store unknown error: [Error occurred while accessing the model provider.]]
Transactions could not be committed.
  • ThingWorx is experiencing hundreds of database deadlocks per day
  • ThingworxStorage/logs/ErrorLog.log show that deadlocks are generated primarily on the model_index_pkey index:
com.microsoft.sqlserver.jdbc.SQLServerException: Transaction (Process ID 60) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction
  • Restarting Tomcat temporarily resolves the model provider issue
  • There were a lot of BatchUpdateException errors in application log:
[L: ERROR] [O: E.c.q.l.c.Logger] [I: ] [U: SuperUser] [S: ] [P: <HA_node_name>] [T: pool-31-thread-10] BatchUpdateException error occurred executing batch update of persistent properties 
[L: ERROR] [O: E.c.q.l.c.Logger] [I: ] [U: SuperUser] [S: ] [P: <HA_node_name>] [T: pool-31-thread-10] Could not commit the transaction. Rolling back... 
[L: ERROR] [O: E.c.q.l.c.Logger] [I: ] [U: SuperUser] [S: ] [P: <HA_node_name>] [T: pool-31-thread-10] Error occurred during commit for the ThingworxPersistenceProvider persistence provider. 
[L: ERROR] [O: E.c.t.p.p.PostgresModelExceptionTranslator] [I: ] [U: SuperUser] [S: ] [P: <HA_node_name>] [T: pool-19-thread-58] An I/O error occurred while sending to the backend. 
This is a printer-friendly version of Article 239982 and may be out of date. For the latest version click CS239982