Why can batches not be loaded in Input Management?
When opening the Input Management Dashboard, an error message appears and the affected batches cannot be opened.
The cause is inconsistent content entries within the
database.
What causes the problem?
The problem is caused by a race condition during the creation of documents in the database.
As a result, multiple active content entries are created
for the same document_id.
The dashboard cannot correctly process these inconsistent data
entries.
What prerequisites are required for troubleshooting?
The following access rights and tools are required:
- Access to the
PROD-DEcluster - Permission for port forwarding
- Access to the
stp_imdatabase - An SQL client, e.g. pgAdmin 4
How is the connection to the database established?
To access the database, a port forwarding connection must first be established:
kubectl -n lexolution port-forward svc/portforward-aurora-shared 5432:5432This enables local access to the database.
##How can affected documents be identified?
Execute the following query on the stp_im database:
select document_id, count(*) as anz
from content
where deleted_at is null
and content_parent_id is null
group by document_id
order by anz desc
limit 10The top entry with the highest count (anz) usually identifies the affected document_id.
Note
In rare cases, multiple documents with anz > 1 may exist. The following steps must then be performed for each affected document.
How is the faulty content entry identified?
Insert the identified document_id into the following query:
select *
from content
where document_id = 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'
and deleted_at is null
and content_parent_id is null
order by created_at descTwo active entries should be returned.
For the cleanup, the id of one of the two entries is required. It does not matter which of the two entries is used.
How is the faulty entry cleaned up?
Execute the following query:
update content
set deleted_at = CURRENT_TIMESTAMP,
deleted_by = '11111111-1111-1111-1111-111111111111'
where id = 'yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy'Note
The WHERE clause must never be removed. Without this restriction, all content entries would be marked as deleted.
What happens after the issue has been resolved?
After the cleanup has been completed successfully, the Input Management Dashboard should open correctly again.
The affected batches can then be loaded again.
To export all documents from the Recycle Bin, the Input Management CLI has been extended with an administrative function.
What should be considered?
Note
The CLI is designed as
a development and administration tool and is not intended for delivery
to end customers. Use at your own risk.
How is the CLI prepared?
After downloading the CLI package, extract the ZIP archive.
The included appsettings.json file must then be modified
in a text editor to reference the correct tenant.
The hostname configured for both Authority and
ServiceUrl must be replaced with the customer-specific
tenant domain.
Note
Ensure that both
Authority and ServiceUrl point to the correct
tenant. If these settings are not configured correctly, authentication
and export operations will fail.
How do I authenticate?
Before exporting documents, the user must authenticate to obtain valid credentials.
STP.IM.Service.Cli.exe loginA help message will be displayed in the console.
Open the link contained in the message in a web browser. The login page will display the requested permissions. Complete the sign-in process to continue.
How can the Recycle Bin be exported?
After successful authentication, run the following command:
STP.IM.Service.Cli.exe export-recycle-binIt is possible to specify a target path for the backup as the only parameter of this command.
STP.IM.Service.Cli.exe export-recycle-bin D:\my\recycle\bin\backupWhere are the exported documents stored?
The target path is optional.
If no target path is specified, a subfolder named
recycleBinExport is created in the current working
directory.
Within this folder, a separate subfolder is created for each exported document.
Each document folder contains the original file using the name under which it was originally uploaded.
This article was automatically translated by AI and may contain errors.
Related to