My requirements are as follows:
- Once the application starts the PostgreSQL service will be started by the application
- Once the application closes the PostgreSQL service will be closed by the application
- ... so i will be taking care of the PostgreSQL setup and running the scripts and starting the service etc
How i am doing this at present is:
- when i start PostgreSQL in a new process i am redirecting the
RedirectStandardError
andRedirectStandardOutput
, it is a silent start, user cannot see the command window etc
The problem is,
- When I coded this I looked for message strings and only supported English. In other words, I used to look for the string
success
inRedirectStandardOutput
but now we are supporting multiple languages so the comparison fails.
Is there any way i can find out whether PostgreSQL set up was successfully started and PostgreSQL service is running or not?
I am starting PostgreSQL by calling pg_ctl.exe in separate process.