This was a question I got tonight. It was a little more complicated prior to Servlet 3.0, but now it is very easy. In fact I almost thought it was not worth writing a post about it. Then I asked a friend in IM if he knew how to do it. It was so much more complicated, I decided to capitulate and post my response.
So how do I navigate to another web application on the server from my current application context?
Simple...
Thursday, November 01, 2012
Servlet 3.0 Tip: How Do I Get to Another Servlet Context?
Labels:
development
,
example
,
glassfish
,
Java
,
JavaEE
,
JEE6
,
Netbeans
,
Programming
,
tutorial
Subscribe to:
Post Comments
(
Atom
)
Popular Posts
-
Introduction This article is not another diatribe to tell you the importance of unit testing. I think we can all agree that it is important...
-
A friend of mine asked me if there was a list of reserved words in EL and JSF. He had previously looked for it, and after some Google search...
-
I saw a question posed on stackoverflow called Trouble with Primefaces 3.0.M2 SelectOneMenu Ajax behavior and I had just done an example a...
-
I was working on a couple of SSL based issues when I made a couple of observations. The default self-signed key generation in Java does not ...
-
This is an example on how to make a system call to the local operating system to execute external programs. This example was written to work...
-
We have been doing a lot of work lately with PrimeFaces. A common set of questions comes up about displaying <p:dialog/> boxes on a pa...
-
I was asked earlier today how to reset fields in a JSF application, if the validation fails. In his case, he had a Richfaces table which had...
-
Image by quasarkitten via Flickr The basics for creating a Maven archetype can be found in the Maven - Guide to Creating Archetypes . The ...
-
Previously, I posted an example of how to use JSF 1.2 with form based authentication (j_security_check). In this example, I use JSF 2.x to...
-
Abstract A common use case is to iterate over a collection of elements, and display them on a page. In the world of JSP, we would use a Ja...
3 comments :
What are the security implications of doing this?
How can an app avoid 3rd-app access?
What about security issues?
How to prevent access?
As I noted on twitter, the question was how to do it. When the question was posed to me, I knew how to do it so I made a quick post on how.
The security aspect had not entered my mind when I was asked how to do it. I would need to take some time to enable security on both applications to see if I can actually do it with security turned on.
In any case, in the absence of checking the security aspects, I can see that it is potentially very scary. Using this technique, and the article http://javaevangelist.blogspot.com/2012/11/dynamic-servlet-registration-example.html You could dynamically inject arbitrary servlets into another context.
Post a Comment