문제

In Tomcat 6, RealmBase provided a "path" field. That apparently has been removed in Tomcat 7. I need to know how to determine the value of the context root inside my authenticate() method.

도움이 되었습니까?

해결책

I found a way to get this by looking at the 6.0 source code of RealmBase.

Fortunately the RealmBase-derived instance has a "context" property containing the context root path:

this.getObjectName().getKeyProperty("context");
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top