Re: Send a command to postgres and close the program - Mailing list pgsql-jdbc

From Thiago Godoi
Subject Re: Send a command to postgres and close the program
Date
Msg-id AANLkTi=F1mBiWRyrSy9GLTKEwNpCD0UaXMbhaydSgaCm@mail.gmail.com
Whole thread Raw
In response to Send a command to postgres and close the program  (Thiago Godoi <thiagogodoi10@gmail.com>)
Responses Re: Send a command to postgres and close the program  (Craig Ringer <craig@postnewspapers.com.au>)
List pgsql-jdbc
The long-running work will be a command without data transfer to the server , that needs to continue processing the command after the client close the conection/program .

This function of send a command to the server is for apply correction patchs in the database.

Thanks again,

Thiago



2010/9/8 Craig Ringer <craig@postnewspapers.com.au>
On 8/09/2010 8:01 PM, Thiago Godoi wrote:
Hello guys,

I'm doing a program that will send a command to the database but the
execution of this command spends a lot of time and client probably will
close the java program .

The problem is that I need the command continue running after the client
close the program.

If they close the program, presumably they might also do things like reboot their machine, so you can't rely on the client at all.

I'd want something running server-side to handle this. LISTEN / NOTIFY can be a good way of waking the server-side helper and telling it that it has work to do.

It might help if you explained in more detail what this long-running work is. Is it critical to data integrity or security? Does it produce a lot of data that must be sent to the server, or is it processing that's done on existing data the server already has? etc.


--
Craig Ringer

Tech-related writing at http://soapyfrogs.blogspot.com/



--
Thiago Godoi
Ec07

pgsql-jdbc by date:

Previous
From: Maciek Sakrejda
Date:
Subject: Re: Eager fetch of Array in one tcp connection
Next
From: Petr Prikryl
Date:
Subject: Re: Eager fetch of Array in one tcp connection