Apache Memory leakage while using camel-server - rest

I am using camel to configure rest end points in my application.
While adding all the files does not give any problem to the project which is working fine till the point I edit camel-server.xml ,please note that I am updating knowledge-service.xml as this is where the rest point uri should hit. The moment I update camel-server.xml , deployment of WAR files in tomcat starts throwing following error :
SEVERE: The web application [/app] created a ThreadLocal with key of type [org.drools.core.common.UpgradableReentrantReadWriteLock$1] (value [org.drools.core.common.UpgradableReentrantReadWriteLock$1#3968e529]) and a value of type [int[]] (value [[I#159d0431]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak.

Related

IBM Integration Bus: The PIF data could not be found for the specified application

I'm using IBM Integration Bus v10 (previously called IBM Message Broker) to expose COBOL routines as SOAP Web Services.
COBOL routines are integrated into IIB through MQ queues.
We have imported some COBOL copybooks as DFDL schemas in IIB, and the mapping between SOAP messages and DFDL messages is working fine.
However, when the message reaches a node where a serialization of the message tree has to take place (for example, a FileOutput or a MQ request), it fails with the following error:
"The PIF data could not be found for the specified application"
This is the last part of the stack trace of the exception:
RecoverableException
File:CHARACTER:F:\build\slot1\S000_P\src\DataFlowEngine\TemplateNodes\ImbOutputTemplateNode.cpp
Line:INTEGER:303
Function:CHARACTER:ImbOutputTemplateNode::processMessageAssemblyToFailure
Type:CHARACTER:ComIbmFileOutputNode
Name:CHARACTER:MyCustomFlow#FCMComposite_1_5
Label:CHARACTER:MyCustomFlow.File Output
Catalog:CHARACTER:BIPmsgs
Severity:INTEGER:3
Number:INTEGER:2230
Text:CHARACTER:Caught exception and rethrowing
Insert
Type:INTEGER:14
Text:CHARACTER:Kcilmw20Flow.File Output
ParserException
File:CHARACTER:F:\build\slot1\S000_P\src\MTI\MTIforBroker\DfdlParser\ImbDFDLWriter.cpp
Line:INTEGER:315
Function:CHARACTER:ImbDFDLWriter::getDFDLSerializer
Type:CHARACTER:ComIbmSOAPInputNode
Name:CHARACTER:MyCustomFlow#FCMComposite_1_7
Label:CHARACTER:MyCustomFlow.SOAP Input
Catalog:CHARACTER:BIPmsgs
Severity:INTEGER:3
Number:INTEGER:5828
Text:CHARACTER:The PIF data could not be found for the specified application
Insert
Type:INTEGER:5
Text:CHARACTER:MyCustomProject
It seems like something is missing in my deployable BAR file. It's important to say that my application has the message flow and it depends on a shared library that has all the .xsd files (DFDLs).
I suppose that the schemas are OK, as I've generated them using the Toolkit wizard, and the message parsing works well. The problem is only with serialization.
Does anybody know what may be missing here?
OutputRoot.Properties.MessageType must contain the name of the message in the DFDL schema. Additionally when the DFDL schema is in a shared library, OutputRoot.Properties.MessageSet must contain the name of the library.
Sounds as if OutputRoot.Properties is not pointing at the shared library. I cannot remember which subfield does that job - it is either OutputRoot.Properties.MessageType or OutputRoot.Properties.MessageSet.
You can easily check - just check the contents of InputRoot.Properties after an input node that has used the same shared libary.
Faced a similar problem. In my case, a message flow with an HttpRequest node using a DFDL domain parser / format to parse an HTTP response from the remote system threw this error (PIF data could not be found for the specified application). "Re-selecting" the same parser domain & message type on the node followed by build / redeploy solved the problem. Seemed to be a project reference related issue within the IIB toolkit.
you need to create static libraries and refer to application.
in compute node ur coding is based on dfdl body

MQJCA4004: Message delivery to an MDB 'null' failed with exception: 'deactivate of endpoint is in progress.'

I have an EAR deployed on WAS 7.0.0.3 server and the web service also deployed.
MQ listener is up and running in my WAS server and corresponding MQ host, channel name and MQ queue name are configured correctly. It is the response queue.
Whenever I'm getting data from MQ, I'm getting the below error in SystemOut.log
error
"MQJCA4004: Message delivery to an MDB 'null' failed with exception:
'deactivate of endpoint is in progress.' "
Please help me on this.
I've managed to further analyze similar MQJCA4004 error using this, kinda hackish, technique.
You need a Java decompiler that preserves line numbers.
JadClipse plugin for Eclipse can do that. Just make sure you have enabled:
Debug Settings
[x] Align code for debugging
in Window > Preferences > Java > Decompiler.
The standard Intellij Idea Community decompiler has that feature already enabled.
The IBM class responsible for producing the MQJCA4004 error is
com.ibm.mq.connector.inbound.AbstractWorkImpl
When you open it (with decompilation enabled) you'll be able to find the string MQJCA4004. Place a breakpoint there and start remote debugging your application server. When you hit that breakpoint, you'll gain access to all the context information including the exception (with call stack) that's causing this error.

Load balancing MySQL ndbcluster

I have successfully setup ndbcluster version 7.1.26.
This contains 2 data nodes[NDBD], 2 mysql [MYSQLD] nodes and one management [MGMD] node.
Replication works successfully.
My Web application is deployed in JBoss-5.0.1 and using JNDI for connection resources which are specified in application specific ds.xml file in load balanced url forms e.g. jbdc:mysql:loadbalance:host1:port1,host2:port2/databaseName.
host1 : refers to first mysqld node and port1 refers the port it is running on.
host2 : refers to second mysqld node and port2 refers the port it is running on.
When both of the [MySQLD] nodes are up and running everything works fine and cluster responds well, replicates data, and data retrieval operations also work properly.
But issues are raised when any of the [MySQLD] nodes goes down. Data gets inserted/updated/replicated but the application is unable to retrieve data from cluster and web page remains busy working which means busy retrieving data. As soon as the node which was down goes up it responds properly and application goes forward and shows up data retrieved from cluster.
At JBoss 5.0.1 startup it showed up a NullPointerException in class LoadBalancingConnectionProxy.invoke(LoadBalancingConnectionProxy.java:439). Tell me if the above Exception plays any role in the above explained issues.
If anyone had faced issues like above and if has any solution regarding the issues please let me know.
Thanks and regards.
I have resolved the issue as it was a bug in the connectorJ's version.
As The project I am working on was already using both the buggy jar mysql-connector-java-5.0.8.jar and the jar version in which the issue is already resolved i.e. mysql-connector-java-5.1.13-bin.jar.
After all the search when I removed the jar mysql-connector-java-5.0.8.jar my issues got resolved.
All that was problematic was that the ConnectorJ/Driver was getting referred from the buggy jar.
The bug id and url which refers to this issue is:
http://bugs.mysql.com/bug.php?id=31053
.
Thanks for considerations.
Are you using different userids and passwords for each of the hosts(host1, host2) specified in the tag ? (Either directly or using tag) ?

Deploying Playframework 2 to AppFog - Memory problems

I am trying to deploy simple Playframework Scala app to AppFog. I've created new Scala application and added a JAR from AppFog documentation. Then I've followed the steps from deploying to AppFog guide.
The problem is that the application won't start when less than 900MB of memory is reserved. The error is :
Error: Application [pralab-test] failed to start, logs information below.
====> /logs/stdout.log <====
No database found in Play configuration. Skipping auto-reconfiguration.
Play server process ID is 13276
[‹[33mwarn‹[0m] play - Plugin [org.cloudfoundry.reconfiguration.play.JPAPlugin]
is disabled
[‹[37minfo‹[0m] play - Application started (Prod)
#
# There is insufficient memory for the Java Runtime Environment to continue.
# pthread_getattr_np
# An error report file with more information is saved as:
# /mnt/var/vcap.local/dea/apps/pralab-test-0-d6bc1b644e85148149d759499e02b409/ap
p/hs_err_pid13276.log
When started with more memory application starts and uses only about 140MB of declared 900MB. Is it a startup memory peak of Play or there is a bug in AppFog?
Do you have any successful deployments of Play applications on AppFog?
EDIT
This runs OK on cloudfoundry.com with 256M of memory.
I was having this same problem and couldn't get around it. I just had to do what you did and allocate 1G to my app when it was only using around 250m. I opened customer support ticket and got no response.
I believe you are having this same problem that they claim to have fixed for "JAVA" but must not be rolled out to play autodetected apps: https://groups.google.com/forum/#!topic/appfog-users/hxBxUe3c4QI
Current options are just live with more memory allocated.

Binding a queue to an EJB 3.0 MDB in WebSphere 7

I'm writing, or trying to write, Baby's First MDB on WebSphere 7. I have nearly no hair left, having pulled it all out trying to get the thing to work. It appears that I've got everything set up right, but I get no response when I put a message to the associated queue.
Here's the EAR file setup:
simplemdb.ear
META-INF
Manifest.mf
application.xml
simplemdb.jar
META-INF
Manifest.mf
ejb-jar.xml
com
[ classes go here ]
I can't find any syntax for defining the queue's JNDI name in ejb-jar.xml, so instead I:
Define a WebSphere activation spec. Name SimpleMDBActivationSpec, JNDI name jms/SimpleActivationSpec, Destination jms/SimpleMDBQueue.
Define a WebSphere queue. Name SimpleMDBQueue, JNDI name jms/SimpleMDBQueue, Queue name SIMPLE.MDB.QUEUE.
Define an MQ queue, name SIMPLE.MDB.QUEUE.
Deploy the EAR file. During the deployment, I'm asked to enter binding information. I select Activation Specification, then point the Target Resource JNDI Name and Destination JNDI name at the activation spec and queue, respectively.
(The MDB code has no annotations.) At this point, the app points to the spec and queue, and the spec points to the queue - belt and suspenders. Naturally, I imagine that the app therefore knows about the queue. Full of hope, I put a message on the queue, and ... nothing. The onMessage event is supposed to use System.out to log a message. I see no message.
Clear documentation on this is conspicuous by its absence. Google gives LOTS of results, but none of them details how the configuration all fits together. There's lots of hand-waving about ibm-ejb-jar-bnd.xmi, but examples of the file are arcane, full of opaque numbers with no explanation about how they were generated, or how they relate to other parts of the configuration.
For goodness' sake. All I want to do is deploy an MDB, and have it write "Hello, world" when I put a message to a queue. I'm using vi and ant as my development and build tools. Can anybody out there give me an idea about what I'm missing?
Edit: "zos" tag added.
I found the problem. It's specific to WebSphere running on z/OS. For an activation spec to be fully available in that environment, the Control Region Adjunct (CRA) process must be started. I told WAS to start it up, recycled the app server, and lo! My MDB started responding.
To make the CRA start via the WebSphere Admin Console, go to ...
Application servers > [server name] > Communications > Messaging > WebSphere MQ CRA Settings
... and check the box that says "Start CRA". Hit OK, save it to the master configuration, and to make the CRA actually start, bring the app server down and back up. (This is for WAS 7.0.)
Thanks to everyone for their time and thoughtspace.
have a quick look at this and see if there is anything here that helps you.
http://publib.boulder.ibm.com/infocenter/ieduasst/v1r1m0/topic/com.ibm.iea.wasfpejb/wasfpejb/6.1/DevelopmentTools/WASv61_EJB3FP_MDBLab.pdf
I haven't played with this for the last one year so i am not able to comment straight away but i thought the PDF might be of some assistance to you.
HTH
Manglu