As discussed, for trouble shooting, we wrote a simple vb program which call simple function of our COM. We executed that little program over 20 times a day and put it on the same problem server. After a couple week of testing, we have below findings
Findings
1) The problem can be found when it runs in background execution, no matter how we specify with credential with adminstrator user right or just left it as no credential. As said before, this problem come out quite irregularly but we can experience this problem only after around 35-60 executions if run it in background execution
2) When we looked at the testing code in detailed, the error is happened when it create a instance of our COM object and Exception is caught when run at below codes. Please also check the error message too.
Our Code which exception is occured :
"Set oMyVariableName = CreateObject("XXXNonTrade.NonTrade")"
Error Message from our exception handling logic in simple vb program :
"Automation error"
"The server process could not be started because the configured identity is incorrect. Check the username and password. "
3) Everytime when this problem come out, it can be fixed simply by rerun the job WITHOUT changing anything. i.e. It maybe not due to job/task configuration.
4) When we set it to run in Foreground mode, it seems no problem.
Thanks for your advice in advance