|
From: Leif M. <le...@ta...> - 2004-02-14 18:59:07
|
Mark,
Reed, Mark (MREED) wrote:
>Someone recently posted a question to this list regarding the wrapper
>hanging and not shutting down the wrapped application.
>The response was to read integration documentation more closely and to offer
>suggestions as to how the docs could be enhanced to help the user solve his
>problem. . I have spent a good deal of time reading the docs while
>implementing a project using the wrapper.
>The wrapper is great stuff, but I have a jew unanswered question that I have
>been trying to solve on my own without posting questions that are obviously
>answered in the docs.
>
>I have one suggestion or request regarding how the docs could be improved to
>help new users or users in general. The integration Method 3 states "The
>third and final method, while providing the most flexibility and access to
>all of the Wrapper's features"
>It would help if a clear distinction of what features are covered by each
>method and finally a clear list of the features that one gets by using each
>method that you dont get from the others. Specifically what is the list of
>features you get using Method 3 that you dont get with Method 1 or Method 2.
>Otherwise you study all three, study the example source provided and it a
>bit difficult to distinguish what you get from 3 that you dont get from 1 or
>2.
>I am trying to decide which method is best for my solution which is a fairly
>complex server application with lots of redundancy and availability
>requirements, remote support requirements via a Web based administration
>interface etc......
>I have used Methods 1 and Method 3 in some proof of concept code and was not
>quite successful with Method 3 due to my lack of understanding I'm sure. A
>better understanding of what you get from 3 as oppossed to 1 and 2 would
>help hence my intro paragraph.
>
>
Thanks for the feedback. I will go back and try improve the docs in the
areas you
mentioned.
>Question 1:
>When using Method 1 and providing my own shut down hook, should I expect to
>be able to instantiate an instance of the WrapperActionServer and have it
>control my app for example sending an R to restart seems to have no effect
>so perhaps this is only usable with Method 3.
>
>
The WrapperActionServer is designed so that it can be used with any of the 3
integration methods. For security reasons none of the functions are
enabled by
default. You will need to enable the restart feature manually as follows:
int port = 9999;
WrapperActionServer server = new WrapperActionServer( port );
server.enableRestartAction( true );
server.start();
Let me know if that is not the problem.
>Question 2:
>When using Method 1 should I expect to be able to configure
>wrapper.filter.trigger.1=(some fully qualified exception name)
>wrapper.filter.action.1=RESTART
>throw this exception from some point in the application, no handle and
>therefore cause the Wrapper (using METHOD 1) to restart the service?
>
>
The Wrapper is capable of triggering a restart or shutown when it
detects a string from
the stdout or stderr of the JVM. This works for any of the 3
integration methods. In
order for it to detect an exception, a message has to be send to stdout
or stderr
however. I am not clear. Is this working for you?
>Question 3:
>What ways can i trigger this mechanism or the wrapper to see my string
>filter it and react. For example could I just perform a
>System.out("MYCOMMAND") and assuming i had
>wrapper.filter.trigger.1=MYCOMMAND
>wrapper.filter.action.1=RESTART
>configured this would activate restart?
>
>
Yes, that should work for you.
I modified the filter docs a little to make this a clearer.
Cheers,
Leif
|