Giter Site home page Giter Site logo

Comments (3)

nbogojevic avatar nbogojevic commented on July 17, 2024 3

Haven't tested it with glassfish/payera. Two approaches you could try
Adding agent you can try to add agent to command line/jvm options: it would be something like adding -javagent:$SESSION_PATH/session-agent.jar where $SESSION_PATH is path to where you've downloaded agent jar.
Another options is to add a SessionFilter as first filter in chain - this needs to be done in web.xml of your web app.

from httpsessionreplacer.

abucreative99 avatar abucreative99 commented on July 17, 2024

Thank you for your expert feedback.
Below is what i did:
I have added the agent in the jvmoptions of my container(payara).

-javaagent:/home/session-agent-0.4.9.jar

Then I added the libraries to my project: the session-agent and the session-replacement library.
Also, I have added the SessionFilter as the first filter in my web.xml as shown below:

<filter>
<filter-name>SessionFilter</filter-name>
<filter-class>com.amadeus.session.servlet.SessionFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>SessionFilter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>

I am not sure how to test if it works or how to access the sessionId saved.

Your quick help is greatly appreciated.

from httpsessionreplacer.

RafaelAlthaus avatar RafaelAlthaus commented on July 17, 2024

I did the same thing described by abucreative99, but I'm getting the following error when I open my login page. Any idea why?

arning: StandardWrapperValve[Faces Servlet]: Servlet.service() for servlet Faces Servlet threw exception java.lang.NullPointerException at org.jboss.weld.context.beanstore.http.AbstractSessionBeanStore.getLockStore(AbstractSessionBeanStore.java:116) at org.jboss.weld.context.beanstore.AttributeBeanStore.lock(AttributeBeanStore.java:251) at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:90) at org.jboss.weld.context.PassivatingContextWrapper$AbstractPassivatingContextWrapper.get(PassivatingContextWrapper.java:76) at org.jboss.weld.bean.ContextualInstanceStrategy$DefaultContextualInstanceStrategy.get(ContextualInstanceStrategy.java:100) at org.jboss.weld.bean.ContextualInstanceStrategy$CachingContextualInstanceStrategy.get(ContextualInstanceStrategy.java:177) at org.jboss.weld.bean.ContextualInstance.get(ContextualInstance.java:50)

from httpsessionreplacer.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.