Windows jobs are ending not okay. The Messages window and activation report shows:
U00029006 File '1452688' cannot be deleted, error code '32', error description: '32 - The process cannot access the file because it is being used by another process. >libcpprnt/src/Path.cpp#sys::Path::remove:449<'.
The windows agent log shows something like:
20230817/170735.217 - U02000009 Job 'JOB_NAME' with RunID '1433034' ended with return code '1'.
20230817/170735.217 - U00063046 Thread '6052' ended with return code '1'.
20230817/170735.279 - U02001026 Job 'JOB_NAME' with RunID '1433034' has been removed from the job table.
20230817/170735.279 - U00029000 Report '1432013' for file 'C:\Automicv21\Agents\windows\temp\OAADDNWS.TXT' has been started.
20230817/170735.279 - Could not remove file 'C:\Automicv21\Agents\windows\temp\OAADDNWS.TXT', reason '32 - The process cannot access the file because it is being used by another process. >libcpprnt/src/Path.cpp#sys::Path::remove:449<'.
20230817/170735.279 - U00029006 File '1432013' cannot be deleted, error code '32', error description: '32 - The process cannot access the file because it is being used by another process. >libcpprnt/src/Path.cpp#sys::Path::remove:449<'.
Release : 12.3, 21.0
Take note of which jobs run into this error. Use the Windows OS Job Object on those jobs:
More information on this setting can be found in the following documentation page under point 5: https://docs.automic.com/documentation/webhelp/english/ALL/components/DOCU/21.0.7/Automic%20Automation%20Guides/Content/AWA/Objects/obj_jobs_WIN.htm?cshid=pa_view_JOBS_WINDOWS
The thought here and the reason this could be happening is that the process is not fully finished writing to the report file when the agent gets the message that the job is finished. By using the Windows OS Job Object set to Yes, the agent will wait until all sub-processes for the job are fully finished.
Setting "Use Windows OS Job Object" to "Yes" should resolve this issue.