I am using the following code to generate and compile java program inside another java program:
import javax.tools.*;
JavaCompiler compiler = ToolProvider.getSystemJavaCompiler();
compiler.run(null, null, null, "-classpath", classpath, souce_files_directory+"WebManager.java");
Inside the WebManager.java file I use regular HttpSesion m...
I am trying to implement a generation of HttpSession key
I am generating a random number between 1,000,000 to 9,999,999 and send it as a cookie to the user.
Is it possible to make this process secure?
anyone can make a random number like that and try to access my server...maybe I need larger range?
another question is, how can I gener...
The object I'm saving to the session is LocalizationContext, which is not serializable, and my Tomcat is 5.5.28, while the qa server is Tomcat 5.5.30. This is from the Tomcat docs (http://tomcat.apache.org/tomcat-5.5-doc/config/manager.html):
Whenever Catalina is shut down
normally and restarted, or when an
application reload is ...
Hey guys,
I have a GWT application which I would like to run from within a Joomla layout. The concept seems to work fine and the application loads up correctly. Joomla uses an iFrame to achieve this and just sends off the url which will kick start the GWT application.
The issue I am having is that I require certain information from Joo...
I'm having a bit of trouble with Session timeouts in my Tomcat served web application. From reading over Tomcat's documentation, sessions expire after a time which can be configured in the web.xml file.
<session-config>
<session-timeout>30</session-timeout>
</session-config>
Quesion) Does this mean 30 minutes from when the...
In my grails application, I have implemented the interface HttpSessionListener to listen for session creation as given below:
class MyHttpSessionListener implements HttpSessionListener {
public void sessionCreated(HttpSessionEvent event) {
log.info "***************** Session created: id= ${event.getSession()?.id}"
}
}
...
I'd like to list all current sessions in an Admin Controller in grails. What's the easiest way to get a reference to e.g. a Collection of sessions from the controller?
...
I need to write a small Java class that will enable me to add to and read from the current user session.
Everything I see refers to Servlets but I'd ideally like to just use a plain old class.
Can anyone please help this Java Newbie?
Thanks
...
Hi Folk,
i'm trying to use session with metro webservice and tomcat but i have a strange issue, look at these line of code:
MessageContext mc = wsCtxt.getMessageContext();
HttpSession session = ((javax.servlet.http.HttpServletRequest) mc.get(MessageContext.SERVLET_REQUEST)).getSession();
At the first call a session is created, at the ...
I'm working on an application that uses .NET's StaticFileHandler to serve up dynamically generated content...
There is also another part of our application that uses the current HttpSession to store user-specific data.
Since the StaticFileHandler is designed to handle static files, it doesn't implement IRequiresSessionState, thus anythi...
Let's say I have a running Java-based web application with 0 or more valid HttpSession objects associated with it. I want a way to access the current list of valid HttpSession objects. I was thinking that I could implement an HttpSessionListener and use it to append to a list of session id values that are stored in an application-scoped ...
I'm not sure if what I'm doing is wrong, or if I just missed an annotation or configuration item somewhere. Here's the situation:
I have a JSF application with a session-scoped bean named SessionData. This bean has an application-scoped bean reference (of type ApplicationData) injected into it at creation time. This works ok when the...
Greetings, fellow StackOverFlow members. I have just begun to learn how to program web-enabled applications using technologies such as Java Enterprise Beans and Java Persistence API.
The official NetBeans website currently offers a bundle that (supposedly) allows me to develop said applications. A bundle that has an approximate size of ...
Ok, with all the answers to this question I'm still not able to handle my problem.
I have the following constellation:
In a JSF (1.1) webapp I have a request scoped bean beanof class Bean. When the user quickly clicks a commandButton multiple times to redirect him to the insult.xhtml page the doSomethingThatTakesALittleLongerAndShouldOn...
My android app sends data to a servlet every 10 seconds. the servlet receives the very first request and responds back. but the servlet doesn't receive the second set of data that the client sends after the next 10 seconds. could some one please tel me how do i go about doing this. is it something related to session?
...
Hi!
Very basic question.
I have a portal containing several servlets, one of which takes care of logging in (but only as an admin). How do I use HttpSessions between Servlets to know if the admin is signed in?
Thanks in advance!
...