how to deploy jbpm5.2 on tomcat 7 using mysql database? - mysql

Can anybody please help me with a link or document to run jbpm-5.2 on tomcat 7 using mysql as database ? Does jbpm deployment to tomcat require some other tool or repository or something else ? I am a complete novice to jbpm... Please help me.
Thanks in advance...

I had same problem and have posted a solution here (there is an ANT script referenced which can be downloaded):
http://ironclaws.wordpress.com/2012/06/18/jbpm-5-2-tomcat-7-mysql-ant-script-18-2/
To summarize what is required in order to install jbpm 5.2 onto tomcat 7 using the final full distribution:
Bitronix Transaction Manager : The distribution does not attempt to deploy / configure this despite the requirement. The above Ant installer will install Bitronix at the Tomcat Server level – advantageous as at this point BTM may be integrated into other projects on the platform.
The jBPM distribution is designed for JBoss AS server and the console / console-server packages include EL (expression language) libraries. These will conflict with those which are installed with Tomcat – the Tomcat EL should be preserved.
There is some confusion with respect to javassist jar in the config / config-server distributions.
The included jars should be dropped – and included into both config / config-server javassist-3.4.GA
The reason for this dependency is that Hibernate 3.4 is deployed as persistence layer in this distribution.
There is a conflicting dom4j library – dom4j-1.6.jar deployed with the console / console-server packages. This should also be removed.
It is not mentioned clearly that the parameter:
-Dreporting.needcontext=true needs to be passed to the Tomcat JVM in order to allow the gtw-server to correctly instantiate the report module loader.
For the ‘Demo’ it is important to configure the human-server persistence correctly, and additionally address the includeantruntime issue during starting of this service.

Related

mySQL Data Provider .NET Core 2.0

Looking for help for some solutions on switching out the default data provider for the project from MS SQL to mySQL. Eventually with the intent of deploying the solution to Auruora on AWS.
After installing the nuget package I get something along the lines of :
System.TypeLoadException: Method 'Clone' in type 'MySql.Data.EntityFrameworkCore.Infraestructure.MySQLOptionsExtension' from assembly 'MySql.Data.EntityFrameworkCore, Version=6.10.5.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d' does not have an implementation.
This lead me to believe that there is no .NET 2.0 Entity Framework Core extention that runs for MySQL. Do I have to rollback to a different version?
For EntityFrameworkCore, it's suggested to use Pomelo.EntityFrameworkCore.MySql.
You may refer to their Getting Started documentation.
A fellow member of the community has kindly summarised the essential steps here:
Put Pomelo.EntityFrameworkCore.MySql into the xxx.EntityFrameworkCore project's .csproj file (see step 2 in the Pomelo getting started guide)
In your xxxDbContextConfigurer class put builder.UseMySql(...) rather than builder.UseSqlServer(...)
Change the connection string found in the appsettings.json file in the xxx.Web.Host project

Getting 'java.sql.SQLException: com.mysql.jdbc.Driver' with grails run-app (when BuildConfig.groovy doesn't need to be recompiled)

I've upgraded my grails application from 1.3.9 to 2.2.3 and then to 2.3.3. I read the release and upgrade notes for 1.3.9->2.2.3 and then from 2.2.3->2.3.3
I am using OpenJDK 6, Jetty 6 and the plugin jetty 1.1, MySQL 5.5 and I have the connector library under lib
Now my issue is if I run grails clean and then grails run-app the application runs without any problems but if I stop it and run grails run-app again I get a gigantic error (see here: http://pastebin.com/36MpXhir)
I also found that changing something like adding a space somewhere in BuildConfig.groovy (anything that makes it be recompiled) makes the application run normally.
Looking at the stacktrace the first thing that puzzles me is
[02.12.13 16:13:59.919] [main] pool.ConnectionPool Unable to create initial connections of pool.
java.sql.SQLException: com.mysql.jdbc.Driver
at org.apache.tomcat.jdbc.pool.PooledConnection.connectUsingDriver(PooledConnection.java:254)
at org.apache.tomcat.jdbc.pool.PooledConnection.connect(PooledConnection.java:182)
at org.apache.tomcat.jdbc.pool.ConnectionPool.createConnection(ConnectionPool.java:701)
at org.apache.tomcat.jdbc.pool.ConnectionPool.borrowConnection(ConnectionPool.java:635)
at org.apache.tomcat.jdbc.pool.ConnectionPool.init(ConnectionPool.java:486)
at org.apache.tomcat.jdbc.pool.ConnectionPool.<init>(ConnectionPool.java:144)
at org.apache.tomcat.jdbc.pool.DataSourceProxy.pCreatePool(DataSourceProxy.java:116)
at org.apache.tomcat.jdbc.pool.DataSourceProxy.createPool(DataSourceProxy.java:103)
at org.apache.tomcat.jdbc.pool.DataSourceProxy.getConnection(DataSourceProxy.java:127)
at org.springframework.jdbc.datasource.LazyConnectionDataSourceProxy.afterPropertiesSet(LazyConnectionDataSourceProxy.java:162)
There are references to org.apache.tomcat even though I'm using jetty (and removed tomcat from BuildConfig.groovy).
Did anyone else encounter such a problem?
Don't put jar files in the lib directory if they're available in a public Maven repo. It's far better to download jars once and keep them in a local cache, and reuse them as needed.
The MySQL driver is used as the commented-out example in the generated BuildConfig.groovy - just un-comment it :) You might want to bump up the version to the latest, e.g.
dependencies {
runtime 'mysql:mysql-connector-java:5.1.27'
}
This is a good site for finding Maven artifacts: http://mvnrepository.com/artifact/mysql/mysql-connector-java
If you do have a jar that's not in a Maven repo (e.g. one with shared code at your company) then you can put it in the lib directory, but it's not auto-discovered. Run grails compile --refresh-dependencies to get it added to the classpath.
For me same error has occurred while running the Grails Application.Then I debug and view the code history of my code which was committed recently.
From that I found the issue that was:
Inside the controller file I send the instance with-out properly
Eg:
**def list=[personInstance.]---> error occurred.**
**render list as JSON**
Then I correct my mistake-->clean the app --> run the app
Now its working fine.

How do I determine which assembly is missing in Mono 2.10.2?

I have a web server with MONO 2.10.2 (fast-cgi) on a CentOS 6 box. Running a plain-vanilla MVC 3 site works great. However, when I add MySql.Data, it gives me a not-so-helpful error:
System.IO.FileLoadException: The assembly name is invalid.
My DLLs are in the right place. They're referenced properly. Everything has been done correctly, but Mono still complains that it can't find an assembly without telling me which one. The problem occurs after simply adding a reference to MySql.Data and without changing any code. I've looked through the MySql.Data source solution and the references that it needs seem to exist on the web server.
I understand other people have the same problem. I am happy to debug it myself, but I'm new to Mono and I can't figure out how to get a more-detailed error messages. I've checked Mono's site for instructions to enable more detailed logging, but their docs assume a certain base knowledge about Mono that I do not have.
Is there a way to get more detailed information when Mono fails to load an assembly?
I'm not sure if these details matter, but just in case...
- Mono: 2.10.2 (served via fastcgi-mono-server4)
- MySql: Connector.Net 6.4.4.0 (from the v4 set in the .Net & Mono download)
- Webserver: NGINX 1.0.11
- OS: CentOS 6
If you can get a "test case" that compiles to an application, try:
MONO_LOG_LEVEL="debug" MONO_LOG_MASK="dll" mono my_app.exe
Or just temporarily edit your CGI script so that it sets those two variables. Check the logs - you should see what is not loaded propely.

Grails IncompatibleClassChangeError

I deploy a war made with "grails war" to a jetty server.
As far as I can determine, Grails builds with Sun JDK 1.6.0_17-b04 and jetty runs on Sun JDK 1.6.0.16 (both on linux).
2010-08-18 07:33:47.018:WARN::Nested in org.springframework.beans.factory.access.BootstrapException: Error executing bootstraps; nested exception is org.codehaus.groovy.runtime.InvokerInvocationException:
java.lang.IncompatibleClassChangeError: the number of constructors during runtime and compile time for java.lang.ClassLoader do not match. Expected 3 but got 2:
java.lang.IncompatibleClassChangeError: the number of constructors during runtime and compile time for java.lang.ClassLoader do not match. Expected 3 but got 2
at grails.plugin.scopedproxy.AlwaysReloadableSmartClassLoader.<init>(AlwaysReloadableSmartClassLoader.groovy:28)
at grails.plugin.scopedproxy.ScopedProxyUtils.wrapInSmartClassLoader(ScopedProxyUtils.groovy:154)
How can this problem be solved or debugged further?
Run grails clean before you run grails war.
According to another post, Groovy code that uses exceptions that was compiled with a version of Java prior to 7 is not compatible with Java 7.
More information can be found here.
You are probably running into a JAR conflict. Namely your build environment is using one jar, and runtime (Jetty) is using a conflicting jar. This used to often happen with various XML parsing stacks.
Try looking at the Jars used by jetty and compare them to the ones in your project.

Visual Studio 2005 application portability

I am creating an application (VS2005, C++ Forms application) that is supposed to work on many different machines that won't have any version of Visual Studio and I am wondering what I should worry about. I am using the Mysql connector, so apparently the machine running it will need to have some compatible version of MySQL, but appart from that, what else should I do to make it work? I'm sure that just giving out the .exe file in the project/release file won't suffice...
Edit: I tried running on a different machine (same .NET, same MySQL, even same Visual Studio), but if I try to run the.exe it gives me a error message saying: "This application has failed to start because the application configuration is incorect. Reinstalling the application may fix this problem". I also tried building on it (desperate thought, because it doesn't have the connector) and it gave me the following output:
1>------ Build started: Project: Carna2e, Configuration: Debug Win32 ------
1>Copying 'f:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.dll' to target directory...
1>Build log was saved at "file://f:\Documents and Settings\User\Desktop\Carna2e\Carna2e\Debug\BuildLog.htm"
1>Carna2e - 0 error(s), 0 warning(s)
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========
here is the build log, that is (like it should) the same with the output:
Build Log:
Build started: Project: Carna2e, Configuration: Debug|Win32
Command Lines Copying 'f:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.dll' to target directory...
Results Build log was saved at "file://f:\Documents and Settings\User\Desktop\Carna2e\Carna2e\Debug\BuildLog.htm"
Carna2e - 0 error(s), 0 warning(s)
Fixed: Apparently I also had to have the connector installed...
At a minimum, the version of the .Net Framework that you write your application for needs to be present on the target machines.
MySQL would have to be present and configured for your application, unless you intend to run MySQL on a database server.
Other than that, you would only have to install more things if you use non-.Net libraries.
only thing you must be sure so you exe work is tha versoun of the framework you need is installed if you project is created with VS 2008 you need .net framework 3.5
Best Regards,
Iordan