There is also https://tomcat.apache.org/tomcat-9.0-doc/config/listeners.html#Context_Naming_Info_Listener_-_org.apache.catalina.core.ContextNamingInfoListener which I have added years ago. Works perfeclty from servlets, Logback and Spring.
On 2025/03/17 12:53:22 Усманов Азат Анварович wrote: > Hi everyone! is it possible to display current version number in a jsp page > or servlet when using parallel deployment . using some property. > Currently when building an app war we use git to calculate last revision > number, store it in a file, use it to name a war accordingly.ex > Education##15229, Education##15230 etc. > I know tomcat already using something to show version because when checking > catalina.out for errors it already shows something like > 17-Mar-2025 11:15:49.732 SEVERE [https-openssl-apr-8443-exec-73] > org.apache.catalina.core.StandardWrapperValve.invoke Servlet.service() for > servlet [IndexServlet] with context path [/Education##23459] threw exception > [org.opensaml.common.SAMLException: Assertion is not conformed with > notOnOrAfter condition] with root cause > > I know if such property exists its probably a tomcat one, not java, since > parallel deployment is not a java but a tomcat feature > and request. getContextPath() shows only the main part (before ##) - > /Education > Ability to display such information in a webpage, would help greatly in > troubleshooting various app users requests when dealing with multiple version > s > Any help is appreciated! > Tomcat version 9.0.64 > OS RHEL Linux 6.5 > Java version 1.8.202 > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org