Deploying play framework on weblogic - java

How can I deploy a play 2.1 web application to oracle weblogic 10.3?
Weblogic is running on windows server 2008 r2.
My application has web socket and I undersand that there are problems with them on deployment.
Edit:
I understand that servlet 3.0 does not support web sockets. If so, what does Play run on its own server?

Play isn't a Java EE framework. It doesn't use servlets and doesn't natively deploy to an application server. Instead, it brings its own full stack. You just run your application standalone, without any external application server. (It's quite common to put your Play application behind a load balancing webserver, but that's not the point right now.)
While there exists a plugin that lets you bundle up your Play application into a war, I'm not sure it'll do much good in your case. It's not tested on WebLogic. Also, and that's the more fundamental problem: if I'm not mistaken, WebLogic 10.3 only supports servlet specification 2.5, while Websockets are only available starting with servlet 3.1. So what you're planning won't work, regardless of Play.
Edit:
Regarding your edit: There still seems to be a misconception here. Play is not a Java EE framework. It does not use servlets. It does not package its application up as wars, and it does not need an application server for deployment. Play comes with its own webserver, which is based on Netty. This built-in webserver supports Websockets and all of Plays features.
And I checked the source of the play2-war-plugin, and it looks like Servlet 3.1 is not (yet) supported. Same goes for Websockets.
To summarize: No, at this moment, it is not possible to write a Play 2 application that uses Websockets and deploy it to a servlet 3.1 container.

In play1.x, we can package the project to a war, by using play warhowever Play 2.x doesn't allow that. You could use external plugins https://github.com/dlecan/play2-war-plugin to package your apps into standard WAR packages from Play framework 2.

Related

what is the role of apache server in java swing application (3 tier)?

I have made a Java Swing application, in the GUI the user can select the type of element and choose a date then the element's informations will be shown on a JTable.i used easyPHP to create the DB.
so what is the role of apache server in this case!
can i consider it like an application server ?
A Java swing application (AFAIK out of the box, for alternatives see below) is not available over HTTP/S (and is therefore not classified as a web application) and Apache is a web server (with features such as proxy, TLS terminator etc.). Therefore there would be no need for a web server such as Apache to front your Swing application.
Apache web server is not an application server for a Swing application per se. Although it can run applications in different programming languages such as php through loading of modules. It however does not run Java web applications.
An application server in a Java perspective would be Tomcat, Glassfish, JBoss, WebLogic etc. An application server hosts an application and could provide a set of services such as Naming, HTTP processing and so on.
Perhaps you are referring to Apache Tomcat instead of Apache Web Server. If so, you would be right on the mark as that is an application server for Java web applications.
If you would like to make your application available through HTTP and enjoy the myriad and expansive benefits of an application server, I would recommend you to rethink on using Swing and utilize a technology built over Java Servlets such as JSPs, Spring MVC and so on.
If you would still like to make the Swing application available through a web server (through HTTP/S) there are some solutions out there but I have not tried any of those. Please do a search on "Swing available on HTTP" in that case. I have also provided a link as well.
You can read up on Application Servers on this wiki link.
You can read up on an HTTP end point for a Swing application here.
This Apache is not used in your application. You installed easyPHP so Apache comes with that to provide PHP programming environment.
Moreover Apache is a web server. So any web based application can be deploy here. PHP is a web programming language sot it requires Apache or any other web server.
But your application is standalone developed with JAVA SWING. So you can stop Apache server and check everything is running fine or not.

Deploy Java restful web service to live server

I have just learned to create java rest API using jersey and Oracle database.
I'm developing in eclipse and using weblogic server to run and test web service on localhost.
My question is what are the options of live servers to deploy this service so that I can access this API in my android application or any web application???
You can do that. But you have to make sure that all the dependent jars are packaged with the your WAR project(eg; Oracle db related things).
Some blog entries which give you an idea about what are all these servers and which one to pick for open development and common standards - http://blogs.forrester.com/mike_gualtieri/11-07-15-stop_wasting_money_on_weblogic_websphere_and_jboss_application_servers,
and this one http://zeroturnaround.com/rebellabs/the-great-java-application-server-debate-with-tomcat-jboss-glassfish-jetty-and-liberty-profile/
This will give pretty good idea about what is all these servers :)

Moving Web Application To Web Hosting/Web Server

Let's imagine that I have finished web application made with JavaEE. This web application contains login system but in the end its very basic web application. I used GlassFish 3.1.2.2.
I would like to know that once finished web application I would like to move/deploy this web application to my web hosting/web server, let's say to Bluehost. What measures I need to make, how they are done and what requirements there are?
I have been searching around the internet but not found any single page that could answer to my question.
You will need to package as WAR file and deploy on the server.
The best and free to use is openshift. It comes with TOMCAT which you can use. Remember tomcat doesn't support EJBs.
You're in demand of a provider that supports Java Servlet and JavaServer Pages. Package your application as a war file and upload it to a tomcat instance, or any other servlet container.

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?

What tech needed to run JSP and Servlets?

If I want to build a site with PHP, all I have to do is install the PHP package and make sure mod_php is enabled in my apache web server. Voila! a PHP environment.
Now, if I want to build a site with equivalent Java tech, i.e. JSP and Servlets, What do I have to install?
You need a servlet container, such as Tomcat or Jetty. They are both easy to configure, and there are lots of tutorials available online.
You only have to install Java (usually already done) and a servlet container like Tomcat.
Netbeans locally includes all startconfig and sample projects needed and you can deploy to gae or eatj. It's complicated and worth the effort. You can go with gae or custom your own with jetty, tomcat, jboss, websphere or glassfish. 512 RAM was minimal after trying with 256 which permgened. You might try with 256. I recommend avoid EJB and custom tags and keep web archives instead of enterprise archives for small to medium projects.
You will need a Java Web Container (Tomcat is a good starting point) plus needing to tell your Apache frontend how to reach the web container from the outside.
Note, most modern Java Web Containers can perform well enough to not need a frontend Apache server.
You need to install the Java Environment, where a web server, The code which does the appropriate functions.
You will be using the jsp for the view part
Servlets for the Basic modal part, where you will write the business logic
and Web.xml, is the deployment descriptor where you will tell the server aabout the servlets and jsp and how the control of the flow will be defined

Categories

Resources