[Design of JBoss ESB] - Re: Problem in XML to CSV transformation
by ravikiran_tv
I tried using Neha's code for smooks-config.xml and XSLT file.
I used smooks filters to execute the transformation.
Smooks smooks = new Smooks("pdm_transformXML2CSV.xml");
| try {
| // Create an exec context - no profiles....
| ExecutionContext executionContext = smooks.createExecutionContext();
| // The result of this transform is a set of CharArray...
| CharArrayWriter outputWriter = new CharArrayWriter();
| // Configure the execution context to generate a report...
| executionContext.setEventListener(new HtmlReportGenerator("report.html"));
|
| // Filter the input message to extract, using the execution context...
| smooks.filter(new StreamSource(new ByteArrayInputStream(messageIn)), new StreamResult(outputWriter), executionContext);
|
|
| System.out.println("***************************");
| //System.out.println("Message Status " + pdm.getMsgHeader().getMessageStatus());
| System.out.println("Message Header is " + outputWriter.toString());
| System.out.println("***************************");
| } finally {
| smooks.close();
| }
|
|
Everything is working fine and I'm able to get exact CSV being transformed from XML template. Thanks Neha for your code - helped me.
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4241970#4241970
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4241970
16 years, 9 months
[Design the new POJO MicroContainer] - Re: ClassPool for JBoss Reflection
by alesj
"flavia.rainone(a)jboss.com" wrote : Ales, the main question here is where do these class pools belong to.
| "kabir.khan(a)jboss.com" wrote :
| | So just as the introspection implementation of JBoss Reflect is independent of the jboss-cl implementations (it just uses the right classloader in the environment it is running in) in a similar way the javassist implementation of JBoss Reflect should be independent of the actual classloader implementation.
| |
| | I think it makes sense to move the classpool stuff out to a separate project which can be consumed by other projects.
|
Yes, I agree with Kabir.
The Reflect should be CL impl agnostic.
You can simply create new CLPool project in jbossas/projects.
Which should also be properly structured - base spi, jboss-cl impl, ...
Where Reflect should then just consume minimal spi, everything else is impl detail depending on the env we're running in.
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4241956#4241956
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4241956
16 years, 9 months
[Design of Messaging on JBoss (Messaging/JBoss)] - Re: DuplicateDetectionTest::testNoPersistXA1 fails if libaio
by jmesnil
same behavior on BasicXARecoveryTest::testNonPersistent & testNonPersistentMultipleIDs
The XAException is caused by the same NPE.
All the tests in XALargeMessageMultiThreadFailoverTest fails too when libaio is not installed:
| java.lang.Exception: Exception on thread Thread[Thread-5,5,]
| at org.jboss.messaging.tests.integration.cluster.failover.MultiThreadFailoverSupport.runMultipleThreadsFailoverTest(MultiThreadFailoverSupport.java:169)
| at org.jboss.messaging.tests.integration.cluster.failover.XAMultiThreadRandomFailoverTest.runTestMultipleThreads(XAMultiThreadRandomFailoverTest.java:670)
| at org.jboss.messaging.tests.integration.cluster.failover.XAMultiThreadRandomFailoverTest.testC(XAMultiThreadRandomFailoverTest.java:107)
| Caused by: javax.transaction.xa.XAException
| at org.jboss.messaging.core.client.impl.ClientSessionImpl.commit(ClientSessionImpl.java:820)
| at org.jboss.messaging.tests.integration.cluster.failover.XAMultiThreadRandomFailoverTest.transactionallySendMessages(XAMultiThreadRandomFailoverTest.java:544)
| at org.jboss.messaging.tests.integration.cluster.failover.XAMultiThreadRandomFailoverTest.doTestC(XAMultiThreadRandomFailoverTest.java:186)
| at org.jboss.messaging.tests.integration.cluster.failover.XAMultiThreadRandomFailoverTest$1.run(XAMultiThreadRandomFailoverTest.java:112)
| at org.jboss.messaging.tests.integration.cluster.failover.MultiThreadFailoverSupport$1Runner.run(MultiThreadFailoverSupport.java:135)
|
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4241927#4241927
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4241927
16 years, 9 months
[Design of JBoss jBPM] - Deleting Process Throws Exception
by dhanushgopinath
Hi,
I am using jBPM 3.2 with jbpm bpel 1.1.1.GA.
I am trying to delete a bpel process definition using the deleteProcessDefinition API on Grpah Session Object . This is my code for the delete
|
| graphSession = jbpmContext.getGraphSession();
| graphSession .deleteProcessDefinition(Long.parseLong(processDefId));
But I am getting this exception while executing that API
| 14:40:34,147 WARN [JDBCExceptionReporter] SQL Error: 0, SQLState: 23503
| 14:40:34,147 ERROR [JDBCExceptionReporter] ERROR: update or delete on table "jbpm_token" violates foreign key constraint "fk_scopeinst_token" on table "bpel_scopeinstance"
| Detail: Key (id_)=(246) is still referenced from table "bpel_scopeinstance".
| 14:40:34,147 ERROR [AbstractFlushingEventListener] Could not synchronize database state with session
| org.hibernate.exception.ConstraintViolationException: could not delete: [org.jbpm.graph.exe.Token#246]
| at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:71)
| at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
| at org.hibernate.persister.entity.AbstractEntityPersister.delete(AbstractEntityPersister.java:2541)
| at org.hibernate.persister.entity.AbstractEntityPersister.delete(AbstractEntityPersister.java:2697)
| at org.hibernate.action.EntityDeleteAction.execute(EntityDeleteAction.java:74)
| at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:250)
All the process instances are ended, in fact I only have one process instance and that is ended. Any Idea why this is happening. Do I need to do anything before calling the delete API?
Thanks in Advance
Regards
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4241922#4241922
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4241922
16 years, 9 months