Avatar of vetrixicode
vetrixicode
 asked on

Identifying Application Instances

Hello experts.

I have an application the performs a routine with some Data. Theres a lot of data to process, so I have that same application running several times, on the same computer ( 2 quadcore processors) , and in other computers as well, all accessing the same database.

All application instances write a log to a log table in the database, and I need to tell witch application instance wrote each log record.

So in general, the question is:

How do I assign an unique ID to an application instance when it starts? Right now, I have 21 instances running on 6 different computers.
And even better, how do I control these applications in a centralized way? Like, how to know how many are running (sometimes they hang) , what computer they are running from, and how to send commands to them (like stop, start, etc).

Any ideas will be greatly appreciated

Thank  you
DelphiSystem UtilitiesNetworking

Avatar of undefined
Last Comment
Geert G

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
reynaldio

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
SOLUTION
TheRealLoki

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
Geert G

what type of database is it ?
add 2 fields to the log table (username can be null and computername can be null)
write a insert trigger on the log table
in the trigger you can then alter the username and computername before inserting the record
implementation depends on database type like oracle or mssql
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck