How to share folder file in the system on JBOSS 7.1? - jboss

I have this issue, I want to share the contain of a certain folder in my filesytem on JBOSS is possible ?
Thank you

Related

Rename Wildlfy temporary content folder(s)

As mentioned in the title, is there a way to rename Wildfly tmp/vfs/temp/temp-xxxxxxxxxxxxxxx/content-yyyyyyyyyyyyyyy folder(s)?
What I would like to obtain is something like this:
tmp/vfs/temp/temp-xxxxxxxxxxxxxxx/WebApp.war, where WebApp.war is the name of a WAR package inside the deployment folder
OR
tmp/vfs/temp/temp-xxxxxxxxxxxxxxx/WebApp.war-yyyyyyyyyyyyyyy.
I tried looking in the Wildfly documentation, but I could not find anything useful.
I am pretty sure it is feasible and it should not be related to a configuration file inside the WAR package.
Currently I am using two versions of Wildfly (on different hosts): 8.1.0 and 10.0.0-Final.
Thanks in advance for your time.

how to download war files from wildfly 8

Wildfly 8:
Where are the deployed war files located on the server file system?
How do I download them? I tried using the JBoss CLI as well as the Web Interface.
Found the war files to be located here. In this directory I found several subdirectories. The war files were all named content and did not have an extension. I could figure out what they were based on file size and timestamp.
wildfly location\standalone\data\content
You want the files 'after' they have been deployed? This generally isn't a good idea as it isn't guaranteed to be exactly the same as the source archive.
The standard location for the deployment archives is ./standalone/deployments/ although this can be changed in the configuration.
After an archive is deployed you can see the exact location of there the deployed archive came from in the configuration, it will be written to the bottom of the xml file.
There is a download button to download the .war
in the management console localhost:9990
click the view button near your war
on top you will find a download icon
I found it in the %WILDFLY_HOME%\standalone\temp\ directory. If it is not present there then you can perform a search in all the subdirectories of the wildfly.

weblogic 12c not loading application properties file

We're moving from OC4J to WebLogic and have some properties files that reside outside of the EAR file. In OC4J we simply put them in the "applib" directory. Everything I've read so far about WebLogic says to put the file in the user_projects\domains\mydomain directory, but that's not working.
Is there another directory that I need to use or how do I force WebLogic to look in user_projects\domains\mydomain for the application properties files?
Maybe not the best solution, but at least a workaround. I edited wls12130\oracle_common\common\bin\commEnv.cmd and appended the domain home dir to this line:
set WEBLOGIC_CLASSPATH=%JAVA_HOME%\lib\tools.jar;%PROFILE_CLASSPATH%;%ANT_CONTRIB%\lib\ant-contrib.jar;%CAM_NODEMANAGER_JAR_PATH%;%DOMAIN_HOME%

Where could I find com.ibm.websphere.sca.ServiceManager and com.ibm.websphere.bo.BOFactory jar files?

I am working on RAD(WebSphere Portal Server 6.1v) and i am getting java build path error for ServiceManager and BOFactory jar files.
Kindly help.
I believe this is part of WebSphere Process Server. These jar files are located in the <INSTALL_ROOT>/plugins directory
BOFactory is located in com.ibm.soacore.runtime_6.1.0.jar
ServiceManager is located in com.ibm.soacore.sca_6.1.0.jar
You need to have the server or the client jars installed on the machine you are developing on.

Deploy war file with modifiable properties files

I am building a web service and am packaging it into a war file for deployment. Right now all of my config files (.properties and .xml) are being packaged into my .war file. This isn't going to work as some of these files will need to be modified for each individual installation. I know that some servlet containers will leave the .war files intact which would mean the config files would never be easily modified. My question is this: what is the best practice for deploying a .war file with these external config files? I'm thinking that the config files will need to be shipped separate from the .war file and placed into a directory that is in the classpath. Is there a default directory setup like this in Tomcat that these files can just be dropped into and my web service will be able to find without much trouble?
Maybe I shouldn't be using a war file for this setup? Maybe I should just be providing a zip file (with the same contents as the war file) and the deployment will simply be to extract the zip into the webapps directory?
I do not know any default directory in Tomcat to store configuration, my
attempts to solve the same issue have been :
1 - Move configuration to the DB and provide scripts or webpages to modify values.
2 - Have a script to deploy the war. The script would merge configuration from a user directory into web.xml or other deployed config files.
3 - Have webapps look first in a user directory for configuration and
if not found then look for configuration files deployed by the war.
Least favorite is 3 - it require all webapps to check two places for configuration and
you end up with two different xml files on the server with different values and it is not always clear which one is used.
Next favorite is 2 - the webapps can be written without knowledge of multiple config files, but you run into issue when someone does a deploy from Tomcat manager instead of using your script.
Favorite is 1. This just works in most cases. Problem is when you don't have a DB or
want to configure how you connect to the DB.
If having the file visible from all webapps is not an issue, you could put it $CATALINA_HOME/lib.
One solution is to modify property file after deployment of war file is to use ServletContext.getRealpath() method to get the real path means path of file in the server where it is deployed and then modify that file it will modify file in container only not the original file. So you need to backup it if it is important modification for you. So by this you do not need to redeploy war file as it is already modifying file from deployed container.
This solution can edit a file that is in webpages folder also from the java class.
If you want more description or how to do it then let me know i have did it.