I am using Quartz Scheduler available in JBossAS-5.x. I want to change default configurations of Quartz. E.g. Threads and all stuffs. But I am unable to find the default configuration file in JBoss. Kindly suggest some pointers on the same.
You can find it in the quartz source code repository: http://svn.terracotta.org/svn/quartz/trunk/quartz-jboss/src/main/java/org/quartz/ee/jmx/jboss/doc-files/quartz-service.xml
HIH
Related
I am hoping you might be able to help me with an issue that I can not manage to find a solution for. I want to build an IntelliJ Plugin that is able to connect to a mysql database. However, adding the mysql connector jar as a library like you would for a simple project does not seem to work and I am out of ways to try it to work. Do you have any suggestions I might try? I thought about the plugin.xml dependencies but I can not seem to find a way to specify the dependency properly. Any hint would be much appreciated.
Here is what I have tried:
In a plugin project, I added the mysql connector as dependency:
dependency setup
I have a DB connection class:
connection class
And another class where I've added my main method and I want to execute an SQL query:
execution result
As seen, I am getting a ClassNotFound exception for the Driver.
If I do the exact same setup, but on a simple Java project, the connection runs with no issues. See below:
dependency setup
result
There is a warning about the deprecated explicit loading of the Diver but this is not the issue. Even iv I remove this, the plugin project still can not find the class.
Actually it seems like the recommended way of declaring dependencies for the Plugins is via Gradle dependencies.
Comment by Jakub here https://www.youtube.com/watch?v=-6D5-xEaYig&lc=UgzA2TPtX_1H2PaL7Q54AaABAg.9Mv96dstxEG9N20UT7YuRQ
I looked up how to declare mysql as gradle dependency and found this: https://www.reddit.com/r/gradle/comments/apme5g/how_to_add_mysqlconnector_to_gradle_build/
So I used
dependencies {
implementation ("mysql:mysql-connector-java:8.0.24")
}
in build.gradle and all works fine now :)
Hope this will help others as well.
I have two bundles, one is DB related and another one simple. DB bundle will export osgi service reference. Another one will get the service reference.
It is working fine when installing one by one. The service reference is null when starting the Jboss fuse karaf container.
Can i set bundle ordering ? or Can i set delay for completing DB bundle?
I need to install bundle after completing DB bundle.
Advance Thanks.
The actual code you have to write depends on how your bundles start. Do you use a Java class as BundleActivator? Spring? Blueprint?
Generally speaking, each bundle must specify its dependencies. There are 2 kinds of dependencies:
dependeny on some classes in packages exported by other bundles
dependency on a service provided by some other bundle
Your bundle should declare packages and services (Java interfaces) it needs. This way you "force" JBoss/Karaf to start bundles in the correct order and avoid null service references.
Have a look at this guide:
https://access.redhat.com/documentation/en-US/Red_Hat_JBoss_Fuse/6.0/html-single/Managing_OSGi_Dependencies/index.html
I would like to connect my web application (running on tomcat 7) to MySQL (v5.6.20). It is ok if I include the driver mysql-connector-java-5.1.31-bin.jar into my web application. But would like to have it for all my apps. On my local computer, I put the file in tomcat/lib and everything is fine.
How to do the same with openshift? Is it a bad idea to do so?
I am a total beginner. What I do to upload my application (war files) is
git add --all
git commit --m "text"
git push
Thanks a lot for your help!!
Here are two KB articles from the Help Center that I think will help you get going, the first shows how to use the pre-configured database connections that come with each of the Java containers on OpenShift (https://help.openshift.com/hc/en-us/articles/202399720-How-to-use-the-pre-configured-MySQLDS-and-PostgreSQLDS-data-sources-in-the-Java-cartridges), They are very easy to use.
The second shows you how to include external libraries (jar files) inside your application without using maven (https://help.openshift.com/hc/en-us/articles/202399730-How-to-include-libraries-jar-files-in-your-java-application-without-using-Maven).
A third option, if you are using a Maven based project (similar to the default applications that come with the Java cartridges), is to add the mysql driver as a dependency to your pom.xml file, and it will be loaded into the correct place in your application when you do a git push. If you want to go that route, I think that this article will help: http://www.java-tutorial.ch/core-java-tutorial/mysql-with-java-and-maven-tutorial
I'm completely new to OpenShift and so far ran in hundreds of bugs while trying to create my first application. Now I want to configure Maven to use my own goals. So far I tried:
adding a Jenkins and configuring the Maven Build - the Jenkins didn't take up the changes and finally stopped building altogether
adding a file .openshift/action_hook/pre_build with the content export MAVEN_ARGS="clean package -Popenshift" as explained here
adding a file .openshift/action_hook/build with the content mvn clean package -Popenshift as explained there
Evidently, the documentation is somewhat obsolete... so what is the correct way?
I finally managed to get the Jenkins to build with my goals. The misconception was that it would use the configured Maven goals INSTEAD of the default ones, when it would just use them additionally (he never had to, since the shell script failed). So deleting the script and adding a custom Maven build works.
I'd like to store the Felix configurations we've made in SVN and have them applied to CQ in the packages produced by an automated build. To do this I have been following the instructions found in this CQ5 OSGI Configuration Document to create sling:OsgiConfig configuration nodes that get checked into SVN.
How can I store environment-specific configurations? For example, I want a different logging configuration for the DEV environment than the PROD environment will use. I would like to store the config for both environments in SVN ideally and have the environment pick which config to use somehow based on the environment.
How can I do that--or is there a different approach that I should be using for environment-specific configurations?
To have environment-specific configurations, you should use Run Modes in CQ5 - there is plenty of information here on how to achieve this_page
Hope this helps.