How to deploy the new application in open-liberty server - open-liberty

How to deploy the application manually:
How to deploy the application.ear manually in the open liberty. Followed the documentation and dropped inside the /liberty/wlp/usr/servers/defaultserver/dropins directory.
From the admin console, it shows two application one in running state and another stopped.
application1.war - Running state
application2.ear - Stopped state (manually dropped in dropins directory)
Note: When perform the start action from admin console on application2. It gives the error message that can't locate the application2.ear defined in server.xml.
Server.xml:
<webapplication location="dropin/application2.ear" contextRoot="/test">

There are a number of things in the question that point to errors.
An ear file is not a Web Application, so the use of the webApplication element with an ear file is likely in error. If you want to deploy an ear file in Liberty via server.xml config you would use enterpriseApplication.
There is a likely typo in the location field where you likely intended dropins rather than dropin which means the application binary wasn't found.
Liberty doesn't support applications configured in server.xml being placed in dropins, we see this as two applications with the same name and won't start the second one.
Any of these symptoms will display in admin center two applications with one being stopped. Simplest thing given your configuration would be to just delete the server.xml configuration.

Related

How to configure Tomcat 9 Spring REST app WAR on Jelastic?

I'm migrating a Spring REST app WAR, that's running fine on a cPanel Tomcat 9 installation, to a Jelastic Tomcat 9 environment. All my content is returning 404's.
My first question is, what to put into the Jelastic Context field, during deployment? I have tried two different names: (1) ROOT- (e.g. ROOT-067) that Jelastic provides, and (2) my preferred webapp name. Both yield same 404 errors. When I study the webapps Directories, in both cases my WAR is correctly unpacked.
My second question is, do I need to modify the Tomcat conf/server.xml or conf/web.xml, that Jelastic generates? I have tried leaving them as originally generated, and making similar changes that I made to both files in the cPanel deployment. With the changed files, the Jelastic deployment fails due to Timeout error after 15 minutes.
Thanks for any and all help!
Bob
Usually you don't have to do any changes in your server.xml / web.xml unless you need to have something very specific in it, did you try to set your context name just as ROOT (without index and a dash)? Could you please provide your environment name and a hosting service provider name? I will contact providers tech guys and we will investigate why that problem occurs. Will be glad to help.

Websphere application modify web.xml doesn't work

I have deployed applications in Websphere 8.5, and I want to modify web.xml, but it seems not working. What I am supposed to do?
While there are documented ways of updating enterprise application files, those were conceived for multi-server deployments and partly are legacy of the previous decade of monster application servers. They are inconvenient for making changes to local development server and it wastes a lot of time.
Upon application deployment, WAS creates (copies/updates) deployment descriptors in the config directory. Then web.xml is used from that location.
You are probably changing web.xml in the location where original application files are kept, thus no effect. You should change the one in config\cells\<cell_name>\applications\<ear_name>\deployments\<app_name>\<war_name>\WEB-INF.
WebSphere writes a second file named web_merged.xml. If you only update the web.xml and replace it you will not update the runtime file used by the container.
Best result I had was using the single file upload function provided within the Admin console or to use the wsadmin or jacl cmd.
The proper way is to update application via console/script.
But I'm assuming you are editing file directly (very hard to guess from your description, I've asked you to describe your procedure).
You need to restart the application to pick up changes in web.xml. See the Hot deploy in WAR files
Two ways:
Update web.xml with WebSphere Web Console
Update web_merged.xml at the same time, and also update the two files in config\cells\<cell_name>\applications\<ear_name>\deployments\<app_name>\<war_name>\WEB-INF

Add jars to Ibm Websphere Portal Server with out restarting the server

I have multiple applications that share common jars, so I decided to put them in the shared library and add a reference to all the applications.
Now the problem is that when I make a change in one of the jars and put them back I have to re start the server.
The weird thing is that I have to do that on my local system and not on the shared server, i was trying to find the setting that will allow me to upload the jar and see the effect with out restarting the server.
One of the blogs says it it not possible but on the shared server it happens so I am sure it is definitely possible.
Please advice what can be done here.
thanks
It sounds like you've configured the shared library to be a part of the server's classpath. Any JARs on the server classpath are only loaded once on server startup. Changes to these JARs require a full server restart.
Libraries that are added to the application's classpath can be reloaded dynamically. The application will still need to restart when the JAR gets changed but that's a much lighter operation and WAS will often automatically detect a file system change and restart the affected applications.
Check how you've configured your shared library to make sure it's being loaded on the application classpath.

How to deploy Camunda BPM to Tomcat in Jelastic

I would like to setup Camunda-BPM in a Tomcat 7 running on Jelastic. I followed the instructions.
The problem now is that Jelastic does not allow to add the file bpm-platform.xml into the catalina-home/conf directory. So when I start the tomcat I get
...
Caused by: org.camunda.bpm.engine.ProcessEngineException: /opt/tomcat/conf/bpm-platform.xml does not exist. This file is necessary for deploying the camunda BPM platform
Can someone please give me a hint where I can place bpm-platform.xml so that the BPM engine starts?
The directory you're looking for is labelled as 'server' in the Jelastic dashboard - but sadly you cannot upload new files to this directory via the dashboard (only edit the existing ones).
However, you can write to this directory via FTP (http://docs.jelastic.com/ftp-ftps-support), so you should be able to add the file that way.
If you are just using a trial account at the moment, you may need to seek assistance from your hosting provider to add the file there for you manually from their side (since trial accounts do not have public IP, so can't use FTP).

Auto-deploy/reload a jar in weblogic server

I am new to Oracle SOA Suite 11.1.1.4... Currently I am working on User defined XPath Functions. As part of this, I will prepare a jar file and need to deploy into weblogic server(10.3) domain lib folder(fusionmw\soasuite\11gR1\11.1.1\sp4\user_projects\domains\DOMAIN_NAME\lib). When ever this jar is altered, I need to replace this in server domain lib and restart the server to load the changes. But I feel this is not a good practice in production server to restart.
Is there a way to auto load updated jar into server's domain so the changes will reflect immediately instead of restarting the server.
Thanks in advance,
Swamy.
Auto-deployment is a method for quickly deploying an application to a stand-alone server (Administration Server) for evaluation or testing. It is recommended that this method be used only in a single-server development environment.
You can run a WebLogic Server domain in two different modes: development and production. Only development mode allows you use the auto-deployment feature
To auto-deploy an archived application, copy its archive file to the /autodeploy directory. WebLogic Server automatically sets the application’s deployment mode to stage mode.
Few words of caution when using autodeploy
Make sure that the server is running while you are adding/replacing/deleting a jar/war/ear in the autodeploy folder. Otherwise the server goes out of sync
Make sure the server is running in development mode otherwise the autodeploy folder changes are not seen by the server instance
In case you are packaging your jar/war/ear in a windows system then deploying it to a weblogic server running in a Unix environment, the weblogic instance will fail to unpack/autodeploy the file through the following exception
java.util.zip.ZipException: Error opening file - filename.war Message - error in opening zip file
java.io.IOException: error in opening zip file with ... Message - error in opening zip file ....
Read this link

Resources