Is there any equivalent of ProxyPassReverse/ProxyPass for Jboss - java

Is there any equivalent of Apache ProxyPassReverse/ProxyPass for Jboss AS?

I'm not sure if JBoss supports anything like this, but it doesn't seem that it should be the role of an application server to also handle all of the numerous and complex features of a dedicated HTTP server like Apache HTTP Server.
Just like it is very common to front something like Apache Tomcat with Apache HTTP Server, couldn't you do the same with JBoss? If not, please further detail your need so that we can provide a better answer.

Related

Connecting external Java program with Apache via module

Last time I think how can I connect my Java external program to Apache webserver.
I wanna send HTTP requests to process and then send output back as HTML file.
I thought about JNI but with multi-thread structure, it doesn't look good for me.
I think with help of Sockets it could be nice but I want to hear Your ideas.
Last but very important: should I use "normal" Apache or Tomcat for that?
For the level of integration you are looking for, JNI is way too low-level and involved.
Instead, take a look at:
FastCGI: on the Apache side use mod_fastcgi and jfastCGI on the Java side.
small HTTP servers: mod_proxy on the Apache side, which reverse proxies to a small HTTP server on the Java side such as Netty or Undertow.

How to tell Tomcat which connector to use for websocket (JSR356)

I am using Tomcat 7.0.59 and currently testing websocket on it. It works fine by itself, but in my production environment, i need to take into account the fact there is an Apache server as the front end, and Tomcat is serving as the application server through the mod_jk connector.
Since it seems websocket does NOT work with mod_jk, and i can not change any part on the Apache side, the only solution left for me is to use a different port (or connector).
First solution: Add Tyrus server standalone jars in Tomcat (ugly for me -- not tested, should work, although i am wondering about potential conflict with Tomcat).
Second solution: Tell Tomcat websocket to 'bind' on another port (connector).
How can i setup the second solution?
Which paramaters can be passed to Tomcat's websocket by web.ml or server.xml ?
I have been searching the web and Tomcat doc for this subsject, but haven't found topics around these questions.

integrated windows authentication equivalent for java and linux

For windows there is integrated windows authentication.
We can configure active directory and join the cleint to the domain.
Then all the services on the client that communicates with the iis on the server can use the integrated authentication transparently.
Is there something similar for java, linux and some application server ?
Regards
I recommend you to use LDAP and PAM.
There is a similar question, where you can find info.
Hope that helps,
You may want to look at the steps for Moodle, to get NTLM working in Apache, on Linux, as that may be what you are looking for, since you already have active directory.
http://docs.moodle.org/en/NTLM_authentication#APACHE_Configuration
This will be between apache and the browser, so, if you want it to work with Tomcat, then you may need to have to use JK (http://tomcat.apache.org/connectors-doc/) to have connections come in to apache then be forwarded to tomcat, after authentication takes place.

java: basic web service interface without a web server

how hard is adding a basic web services interface to an existing java server application without having to turn it into a .war, or embedding a small web server like jetty?
say, xml-rpc instead of more modern approaches, if it helps.
if not too hard, can you suggest a starting point?
thank you in advance :)
It sounds like you're asking for the impossible: expose an HTTP service without plugging into or embedding an HTTP server!
Unless you want to reimplement what Jetty already does, I'd reccommend using Jetty as a library. That way you don't need to conform to the more awkward aspects of the Servlet spec. E.g. your servlets can have real constructors with parameters.
There is also a simple HTTP server implementation in JDK 6, but it's in the com.sun namespace so I'd avoid it for production code.
Check out the Restlet API which provides a painless way to implement RESTful web services that can run inside a web container or standalone.
I don't know what you are doing, but what about rmi?
RMI # stackoverflow
Spring-WS has the facility for using JRE 1.6's embedded web server, if that's an option for you. Spring-WS gives you a very nice SOAP server layer, if that's what you're after.
If not, then an embedded Jetty instance is probably the best idea.

YAWS fronting Tomcat

Is there currently any easy way to set up a YAWS web server in front of Apache Tomcat Servlet container, similar to popular Apache httpd + Tomcat set up?
I do not believe there is an AJP connector for YAWS, but you should be able to front Tomcat with YAWS via HTTP. YAWS is relatively easy to setup as a reverse proxy. See the man page here for details (see revproxy):
http://yaws.hyber.org/yman.yaws?page=yaws.conf
Note: This is not yet considered production quality so you will want to do plenty of testing to ensure this satisfies your production requirements.
I do not know what your use case is, but you may find Nginx is a worthwhile alternative to Apache as a load-balanced, HTTP reverse proxy in front of Tomcat. There are a number of good tutorials for this on the web, or checkout the recent Linux Journal article (requires a subscription):
http://www.linuxjournal.com/article/10108

Categories

Resources