K
Kira Yamato
Hello NG. I need an advice on what is the best way to do the following:
I have an UNIX-style binary program that communicates through stdin and
stdout. I like to expose its functionality to the web. Users will
work with this program interactively, so session states must be kept.
Here's an approach I came up with: I want to use java.io.Process to
invoke an instance of the external program. Then store this Process
object as a session object in the servlet.
I like to know what unforeseen issues may be associated with this
approach. For example,
1) Do I have any cleanup issues to worry about? Like orphan process
launched but never terminated even though the session expires.
2) Or any other issues that you can see?
Or perhaps there is another better way to go about this.
I am much appreciated for any insights. Thanks.
I have an UNIX-style binary program that communicates through stdin and
stdout. I like to expose its functionality to the web. Users will
work with this program interactively, so session states must be kept.
Here's an approach I came up with: I want to use java.io.Process to
invoke an instance of the external program. Then store this Process
object as a session object in the servlet.
I like to know what unforeseen issues may be associated with this
approach. For example,
1) Do I have any cleanup issues to worry about? Like orphan process
launched but never terminated even though the session expires.
2) Or any other issues that you can see?
Or perhaps there is another better way to go about this.
I am much appreciated for any insights. Thanks.