org.camunda.bpm.engine.impl.persistence.entity.HistoricVariableInstanceEntity.insertHistoricVariableInstance (batch index #1) failed

Hi,

I am getting org.camunda.bpm.engine.impl.persistence.entity.HistoricVariableInstanceEntity.insertHistoricVariableInstance (batch index #1) failed.Cause: java.sql.BatchUpdateException: String or binary data would be truncated.
java.sql.BatchUpdateException: String or binary data would be truncated.
But it is not giving for which entity it is failing or any information about which DB as there were multiple ACT_HI_ table.
Please provide some insight to it.

Hi @Shwetanana,

Welcome to the community!
Could you please provide more details so we can help you with that:

  • please share with us the Camunda version do you use
  • which server do you use and the version of it
  • what database do you use, the version might help as well
  • which are the steps to reproduce the issue and how often do you observe the problem?
  • it will help us if you share the complete stacktrace of the exception

Providing as many details as it’s possible will help to narrow down why the problem did occur.

Best regards,
Yana

Camunda Version: 7.11.0
For DB we are using Azure SQL
Whenever any task is completed then some time getting Entity processing failed, ENGINE-03083 Exception while executing Batch Database Operations with message ’

Error flushing statements. Cause: org.apache.ibatis.executor.BatchExecutorException: org.camunda.bpm.engine.impl.persistence.entity.HistoricVariableInstanceEntity.insertHistoricVariableInstance (batch index #1) failed. Cause: java.sql.BatchUpdateException: String or binary data would be truncated.

Cause: org.apache.ibatis.executor.BatchExecutorException: org.camunda.bpm.engine.impl.persistence.entity.HistoricVariableInstanceEntity.insertHistoricVariableInstance (batch index #1) failed. Cause: java.sql.BatchUpdateException: String or binary data would be truncated.

java.sql.BatchUpdateException: String or binary data would be truncated.
'. Flush summary:

Hi @Shwetanana,

Unfortunately, we do not support Azure SQL, please refer to the supported environments documentation:
https://docs.camunda.org/manual/7.12/introduction/supported-environments/#supported-database-products
That means that we cannot guarantee that the product will work as expected with that database, as well as what are the configuration that need to be perform for it.

You can consider switching to one of the supported database setup from the link above and we recommend you to do so.

*Side note: If you want to try out Azure even if it not supported -

  • the exception occurs when a historic variable instance is inserted to the ACT_HI_VARINS. Check if all of the values are the right size of their column. You can enable logging if you think that might help you. [1]
  • keep in mind that every database needs to have the correct isolation level configured [2]

1: https://docs.camunda.org/manual/7.12/user-guide/logging/#database-statements
2: https://docs.camunda.org/manual/7.12/user-guide/process-engine/database/#isolation-level-configuration

I hope that helps you.

Best regards,
Yana

What is the functionalities of ACT_HI_VARINS and what can be impact if task information is not inserting in this table.

This table stores the historic data for variables [1]
In general, the engine can function without the historic data but that the webapps (Cockpit) might be broken after that. My concern is that if the transaction doesn’t succeed due to such error, it will be rolled back. That means that some operation won’t be performed, for example, task complete and so on.

1): https://docs.camunda.org/manual/7.12/user-guide/process-engine/database/#history