How to run Grails app WAR file on Apache web server? - java

I want to know if it is possible to run a Grails app (basically a Java WAR file) on Apache web server. Currently I am using Tomcat but I need some Apache specific configurations.
Thanks in advance.

You can not run a Grails application (WAR) on an Apache HTTP webserver. A Java WAR requires a JEE application container such as Tomcat or Jetty to run.
Depending on your needs you could put an Apache HTTP webserver in front of a Tomcat server which runs your Grails application. This way you can use the features of the Apache HTTP webserver as well as what is offered by Tomcat. However, this is beyond the scope of the question you asked.

Related

Run polymer js application on localhost using any Java server (not python or any other related )

I have watched some videos regarding set up of polymer js application. In some, they say start SimpleHTTPServer and deploy your app, but this server is a module of python, I don't want to install it.
So I want to run this application using some Java related server.
I have used Apache Tomcat (although any Java web server would work). Create a simple static web application (Eclipse creates a template for a new web project) and add your polymer files to it. Deploy to Tomcat and point your browser to http://localhost:8080 (or whichever ip:port you have configured)
While in active development use Eclipse to deploy and sync web application to Tomcat. Refer to Eclipse documentation for that.
For production deployment, first use polymer-cli to create a bundled package and then deploy the contents of the bundled (or unbundled) package as a web application.

HTML5 and Java server application deployment on AWS

I have created a Java restful server application which can be compiled as a JAR/WAR file and I have another front-end application built using knockoutjs and HTML5 which talks to the Restful Server side application.
I am trying to deploy both on to Amazon Linux AMI EC2 Instance. I was successfully able to deploy the JAR after setting up a glassfish server on the server. The server side application is running completely fine.
I am having problems in understanding how the HTML5 application needs to be deployed on the AWS server. So that both can be accessible from the same server.
It would be great if some best practices are also suggested.Appreciate any help
Thanks
You probably want to put your GlassFish application server behind an HTTP server like Apache HTTPd or nginx, and either of those servers could then also serve your static content -- your HTML and JS. Check out http://www.codefactorycr.com/glassfish-behind-apache.html

Running portable web services application server

I need portable container for running web services as server. JSON as a response. The server application must be able to start up using .bat script under Windows. Machine running the server must have only Java Runtime Enviroment installed, no other stuff required.
Axis2 on top of Tomcat do not seem like simple portable web server. What are the other alternatives?
UPDATE:
How come no one offered?
com.sun.net.httpserver.HttpServer;
and
com.sun.jersey.api.container.httpserver.HttpServerFactory;
Jetty is a good option.
Another very lightweight option is fluent-http.
I'm not that familiar with Axis2, but as far as I know you can use embedded tomcat to achieve this with whichever frameworks you please.
Take a look at the tomcat maven plugin which I believe will even generate your application as a jar containing embedded tomcat in the latest version.

How can i change deployed application to webserver from application server?

I am having a web application which is deployed in oracle weblogic application server. After getting analysed, i found that there is no need for application server(atleast for this application), i am in need to deploy this application into the oracle weblogic web server.
can anyone help on this, how can i change deployed application to webserver from application server ?
Or in a different words, i can say how can i migrate my application deployment from oracle weblogic application server to oracle weblogic web server ?
I am using weblogic 10. and Maven to build the application
About the application, it is using Apache axis, webservices, jsf, and few java classes.
Thanks in advance!
I've recently migrated one application from WAS to tomcat
The approach i followd is.
Identify and remove all the WL specific dependencies / jars (that you may not need of)
Change the build script to generate .war instead of .ear
deploy the generated .war to any servlet container/ webserver
with your specs (axis,ws,jsf) you dont need a .ear but .war will do.
if you are using ant modify your build script, i'd suggest go for maven for better dependency management
building of top of the answer by #TechExchange
even for Jboss, you still need to analyze the application to remove all WL specifics.
Ex: Descriptors for EJB's MDB's and so on.
with JBOSS you can still use the ear format.
A quesiton, you had mentioned that because you found that the application doesn't need a app server you decided to migrate it to web server, now with JMS in the picture do you still need to move?

How to publish the web service which is created in Java using Eclipse?

I have created one web service in Java using Eclipse, now I need to publish that web service. How to achieve this?
you can deploy your ws that is developed in java on tomcat server and to do that you can follow instuctions on How to manually deploy a web service on Tomcat 6?
now TomCat7 is availabale and you must check this PDF which helps you to deploy Webservices on Tomcat from eclipse. It is self explained Pictorial representation and is exactly what you want.
Export the war and deploy it to an application server.

Categories

Resources