Jakarta custom JWT Filter on top of spring boot camunda engine

Hi,
We have spring boot camunda engine with version 7.20.
We have requirement to secure the engine-rest call with JWT token validation.
latest 7 version is making use of jakarta filter where we are facing casting exception on line
String authorizationHeader = ((HttpServletRequest)request).getHeader(“Authorization”);

as
java.lang.ClassCastException
: class org.apache.catalina.connector.RequestFacade cannot be cast to class javax.servlet.http.HttpServletRequest (org.apache.catalina.connector.RequestFacade and javax.servlet.http.HttpServletRequest are in unnamed module of loader ‘app’)

If we proceed with jakarta servletrequest type …,there is no method to get the header data in which bearer token,we will be passing.

Please advise it.