On 14/4/20 8:05 pm, Brian Burch wrote:
On 14/4/20 6:53 pm, logo wrote:
Brian,
see down below....
Am 2020-04-14 08:34, schrieb Brian Burch:
</snip>
My initial code inspection makes me strongly suspect tomcat does not
initialise JNDIRealm and a nested CredentialHandler properly during
startup. However, I am not smart enough to attach my debugger to the
tomcat jvm until it is too late.
</snip>>>
set in bin/setenv.sh
export JPDA_SUSPEND=y
this will stop tomcat startup until debugger is attached.
Wow! That is a neat trick. I will try it tomorrow and see what I can
intercept.
Thanks very much for the tip,
Brian
Thanks again. I tried your setenv.sh export, but my systemd start of the
tomcat service failed without a meaningful error message.
My installation is a hybrid. I use the standard ubuntu systemd setup of
tomcat and then subsequently move the content from my source build over
the top of it.
The ubuntu setup installs /etc/default/tomcat8. This file includes a
line to export the JAVA_OPTS environment variable if you wish the server
to run under the jvm debugger.
The default definition includes the parameter:-
-Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n
... so I changed the suspend option to "y" and everything worked well.
Tomcat startup waited until I attached a remote debugger session, then
it started and hit my first breakpoint.
Now I need to find out what happens to the JNDIRealm and nested
CredentialHandler initialisation process.
Regards,
Brian
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org