[JBoss jBPM] - Can't deploy my BPEL process to jBPM BPEL 1.1 Beta3
by rainstar79
Hi,
I've got a problem in deploying my first BPEL process. I know it's a long text to read, but if you help me with this problem you will save my life ;-)
I modeled my first BPEL process by using the Eclipse BPEL designer. Now I am at the point that I need to deploy this process. Therefore I took the examples folder of the jBPM BPEL 1.1 and replaced the files in the hello folder, by my new BPEL artifacts.
When I run the ant task pack-definition, a zip file is generated properly. But when I say deploy-definition, an exception is thrown:
| [deployprocess] target url: http://localhost:8080/jbpm-bpel/deploy?processfile=file%3A%2FC%3A%2FProgr...
| [deployprocess] got response code: 500
|
| BUILD FAILED
| C:\Programme\Java\jbpm-bpel-1.1.Beta3\examples\common\bpel-build.xml:60: deployment failed, see details in the server console
|
|
and
| 2007-04-12 12:10:29,096 INFO [org.jbpm.bpel.xml.BpelReader] read wsdl
| definitions: PlanetsService.wsdl
| 2007-04-12 12:10:29,112 INFO [org.jbpm.bpel.xml.BpelReader] read wsdl
| definitions: PlanetsServiceArtifacts.wsdl
| 2007-04-12 12:10:29,112 INFO [org.jbpm.bpel.xml.BpelReader] read wsdl
| definitions: PlanetsService.wsdl
| 2007-04-12 12:10:29,128 INFO [org.jbpm.bpel.xml.BpelReader] read wsdl
| definitions: droid.wsdl
| 2007-04-12 12:10:29,128 ERROR [org.jbpm.bpel.xml.ProblemHandler]
| PlanetsService.bpel could not read wsdl document
| java.io.FileNotFoundException: C:\Programme\Java\jboss-4.0.5.GA\bin
| (Access denied)
| at java.io.FileInputStream.open(Native Method)
| at java.io.FileInputStream.<init>(FileInputStream.java:106)
| at org.jboss.net.protocol.file.FileURLConnection.getInputStream(FileURLConnection.java:105)
|
| at org.apache.xerces.impl.XMLEntityManager.setupCurrentEntity(Unknown
| Source)
| at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
|
| at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
|
| at java.lang.Thread.run(Thread.java:595)
| 2007-04-12 12:10:29,128 ERROR [org.jbpm.bpel.xml.ProblemHandler]
| PlanetsService.bpel could not read wsdl document
| WSDLException: faultCode=PARSER_ERROR: Problem parsing ''.:
| C:\Programme\Java\jboss-4.0.5.GA\bin (Zugriff verweigert):
| java.io.FileNotFoundException: C:\Programme\Java\jboss-4.0.5.GA\bin (Zugriff verweigert)
|
| at java.io.FileInputStream.open(Native Method)
| at java.io.FileInputStream.<init>(FileInputStream.java:106)
| at org.jboss.net.protocol.file.FileURLConnection.getInputStream(FileURLConnection.java:105)
|
| at org.apache.xerces.impl.XMLEntityManager.setupCurrentEntity(Unknown
| Source)
|
|
|
|
|
| My BPEL process is defined in PlanetsService.bpel and is as follows:
|
| | <?xml version="1.0" encoding="UTF-8"?>
| | <bpws:process xmlns:bpws="http://schemas.xmlsoap.org/ws/2004/03/business-process/"
| | xmlns:ns="http://planets.euArtifacts"
| | xmlns:ns0="http://pluto.researchstudio.at/ibpm/DROIDService.jws"
| | xmlns:ns1="http://pluto.researchstudio.at/ibpm/MigrateService.jws"
| | xmlns:tns="http://planets.eu" exitOnStandardFault="yes"
| | name="PlanetsService" suppressJoinFailure="yes"
| | targetNamespace="http://planets.eu">
| |
| | <bpws:import importType="http://schemas.xmlsoap.org/wsdl/"
| | location="PlanetsService.wsdl" namespace="http://planets.eu"/>
| |
| | <bpws:import importType="http://schemas.xmlsoap.org/wsdl/"
| | location="droid.wsdl" namespace="http://pluto.researchstudio.at/ibpm/DROIDService.jws"/>
| | <bpws:import importType="http://schemas.xmlsoap.org/wsdl/"
| | namespace="http://planets.euArtifacts"/>
| | <bpws:import importType="http://schemas.xmlsoap.org/wsdl/"
| | location="PlanetsServiceArtifacts.wsdl" namespace="http://planets.euArtifacts"/>
| | <bpws:import importType="http://schemas.xmlsoap.org/wsdl/"
| | location="migration.wsdl" namespace="http://pluto.researchstudio.at/ibpm/MigrateService.jws"/>
| |
| | <bpws:partnerLinks>
| | <bpws:partnerLink myRole="PlanetsServiceProvider" name="client"
| | partnerLinkType="tns:PlanetsService" partnerRole="PlanetsServiceRequester"/>
| | <bpws:partnerLink name="DROID" partnerLinkType="ns:DROID-PLKT"
| | partnerRole="DROIDService"/>
| | <bpws:partnerLink name="Migration" partnerLinkType="ns:Migration-PLKT"
| | partnerRole="MigrationService"/>
| | </bpws:partnerLinks>
| | <bpws:variables>
| | <bpws:variable messageType="tns:PlanetsServiceRequestMessage" name="input"/>
| | <bpws:variable messageType="tns:PlanetsServiceResponseMessage" name="output"/>
| | <bpws:variable messageType="ns0:identifyFormatResponse" name="DROIDResponse"/>
| | <bpws:variable messageType="ns0:identifyFormatRequest" name="DROIDRequest"/>
| | <bpws:variable messageType="ns1:migrateFileResponse" name="MigrationResponse"/>
| | <bpws:variable messageType="ns1:migrateFileRequest" name="MigrationRequest"/>
| | </bpws:variables>
| | <bpws:sequence name="main">
| | <bpws:receive createInstance="yes" name="receiveInput"
| | operation="initiate" partnerLink="client" portType="tns:PlanetsService" variable="input"/>
| | <bpws:assign name="Assign" validate="no">
| | <bpws:copy>
| | <bpws:from part="payload" variable="input">
| | <bpws:query queryLanguage="http://www.w3.org/TR/1999/REC-xpath-19991116">
| | <![CDATA[/tns:input]]></bpws:query>
| | </bpws:from>
| | <bpws:to part="s" variable="DROIDRequest"/>
| | </bpws:copy>
| | </bpws:assign>
| | <bpws:invoke inputVariable="DROIDRequest" name="InvokeDROID"
| | operation="identifyFormat" outputVariable="DROIDResponse"
| | partnerLink="DROID" portType="ns0:DROIDService"/>
| |
| | <bpws:assign name="Assign1" validate="no">
| | <bpws:copy>
| | <bpws:from part="identifyFormatReturn" variable="DROIDResponse"/>
| | <bpws:to part="file" variable="MigrationRequest"/>
| | </bpws:copy>
| | </bpws:assign>
| | <bpws:invoke inputVariable="MigrationRequest" name="InvokeMigration"
| | operation="migrateFile" outputVariable="MigrationResponse"
| | partnerLink="Migration" portType="ns1:MigrateService"/>
| | <bpws:assign name="Assign2" validate="no">
| | <bpws:copy>
| | <bpws:from part="migrateFileReturn" variable="MigrationResponse"/>
| | <bpws:to part="payload" variable="output">
| | <bpws:query queryLanguage="http://www.w3.org/TR/1999/REC-xpath-19991116"><![CDATA[/tns:result]]></bpws:query>
| | </bpws:to>
| | </bpws:copy>
| | </bpws:assign>
| | <bpws:invoke inputVariable="output" name="callbackClient"
| | operation="onResult" partnerLink="client" portType="tns:PlanetsServiceCallback"/>
| | </bpws:sequence>
| | </bpws:process>
| |
| |
|
|
| My PlanetsService.wsdl is:
|
|
| | <?xml version="1.0"?>
| | <definitions name="PlanetsService"
| | targetNamespace="http://planets.eu"
| | xmlns:tns="http://planets.eu"
| | xmlns:plnk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/"
| | xmlns="http://schemas.xmlsoap.org/wsdl/"
| | >
| |
| | <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| | TYPE DEFINITION - List of services participating in this BPEL process
| | The default output of the BPEL designer uses strings as input and
| | output to the BPEL Process. But you can define or import any XML
| | Schema type and us them as part of the message types.
| | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
| | <types>
| | <schema attributeFormDefault="unqualified"
| | elementFormDefault="qualified"
| | targetNamespace="http://planets.eu"
| | xmlns="http://www.w3.org/2001/XMLSchema"
| | >
| |
| | <element name="PlanetsServiceRequest">
| | <complexType>
| | <sequence>
| | <element name="input" type="string" />
| | </sequence>
| | </complexType>
| | </element>
| |
| | <element name="PlanetsServiceResponse">
| | <complexType>
| | <sequence>
| | <element name="result" type="string"/>
| | </sequence>
| | </complexType>
| | </element>
| |
| | </schema>
| | </types>
| |
| | <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| | MESSAGE TYPE DEFINITION - Definition of the message types used as
| | part of the port type defintions
| | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
| | <message name="PlanetsServiceRequestMessage">
| | <part name="payload" element="tns:PlanetsServiceRequest"/>
| | </message>
| |
| | <message name="PlanetsServiceResponseMessage">
| | <part name="payload" element="tns:PlanetsServiceResponse"/>
| | </message>
| |
| |
| | <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| | PORT TYPE DEFINITION - A port type groups a set of operations into
| | a logical service unit.
| | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
| | <!-- portType implemented by the PlanetsService BPEL process -->
| | <portType name="PlanetsService">
| | <operation name="initiate">
| | <input message="tns:PlanetsServiceRequestMessage"/>
| | </operation>
| | </portType>
| |
| | <!-- portType implemented by the requester of PlanetsService BPEL process
| | for asynchronous callback purposes
| | -->
| | <portType name="PlanetsServiceCallback">
| | <operation name="onResult">
| | <input message="tns:PlanetsServiceResponseMessage"/>
| | </operation>
| | </portType>
| |
| |
| | <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| | PARTNER LINK TYPE DEFINITION
| | the PlanetsService partnerLinkType binds the provider and
| | requester portType into an asynchronous conversation.
| | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
| | <plnk:partnerLinkType name="PlanetsService">
| | <plnk:role name="PlanetsServiceProvider" portType="tns:PlanetsService"/>
| | <plnk:role name="PlanetsServiceRequester" portType="tns:PlanetsServiceCallback"/>
| | </plnk:partnerLinkType>
| | </definitions>
| |
|
| This is my bpel-definition in the Meta-Inf folder:
|
|
| | <?xml version="1.0" encoding="UTF-8"?>
| | <bpelDefinition location="PlanetsService.bpel" xmlns="http://jbpm.org/bpel"
| | xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
| | xsi:schemaLocation="http://jbpm.org/bpel
| | http://jbpm.org/bpel/bpel_definition_1_0.xsd">
| |
| | <!-- makes WSDL interface elements available to the process -->
| | <imports>
| | <wsdl location="PlanetsService.wsdl" />
| | <wsdl location="PlanetsServiceArtifacts.wsdl" />
| | </imports>
| |
| | </bpelDefinition>
| |
|
| and here is my PlanetsServiceArtifacts.wsdl:
|
|
| | <?xml version="1.0" encoding="UTF-8"?>
| | <bpelDefinition location="PlanetsService.bpel" xmlns="http://jbpm.org/bpel"
| | xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
| | xsi:schemaLocation="http://jbpm.org/bpel
| | http://jbpm.org/bpel/bpel_definition_1_0.xsd">
| |
| | <!-- makes WSDL interface elements available to the process -->
| | <imports>
| | <wsdl location="PlanetsService.wsdl" />
| | <wsdl location="PlanetsServiceArtifacts.wsdl" />
| | </imports>
| |
| | </bpelDefinition>
| |
|
|
| I invoke 2 external Services, which can be found here:
| http://pluto.researchstudio.at/ibpm/DROIDService.jws?wsdl
| http://pluto.researchstudio.at/ibpm/MigrateService.jws?wsdl
|
| Thanks for your HELP!!!!
| cheers Rainer
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4036666#4036666
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4036666
19 years
[JBoss Messaging] - Servlet as a topic listener
by rolmovel
Hi, I,m trying to subscribe a servlet to a topic for event notifying to clients (with lazy loading technology) but when i instance the servlet from the IExplorer i get next exception:
| 12:25:58,989 ERROR [STDERR] javax.jms.IllegalStateException: This method is not applicable inside the application server. See the J2EE spec, e.g. J2EE1.4 Section 6.6
| 12:25:58,989 ERROR [STDERR] at org.jboss.resource.adapter.jms.JmsSession.checkStrict(JmsSession.java:542)
| 12:25:58,989 ERROR [STDERR] at org.jboss.resource.adapter.jms.JmsMessageConsumer.setMessageListener(JmsMessageConsumer.java:136)
| 12:25:58,989 ERROR [STDERR] at elimina.ServletPrueba.service(ServletPrueba.java:79)
| 12:25:58,989 ERROR [STDERR] at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
| 12:25:58,989 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
| 12:25:58,989 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| 12:25:58,989 ERROR [STDERR] at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
| 12:25:58,989 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
| 12:25:58,989 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| 12:25:58,989 ERROR [STDERR] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
| 12:25:58,989 ERROR [STDERR] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
| 12:25:58,989 ERROR [STDERR] at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
| 12:25:58,989 ERROR [STDERR] at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
| 12:25:58,989 ERROR [STDERR] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
| 12:25:58,989 ERROR [STDERR] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
| 12:25:58,989 ERROR [STDERR] at org.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
| 12:25:58,989 ERROR [STDERR] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
| 12:25:58,989 ERROR [STDERR] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
| 12:25:58,989 ERROR [STDERR] at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
| 12:25:58,989 ERROR [STDERR] at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
| 12:25:58,989 ERROR [STDERR] at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
| 12:25:58,989 ERROR [STDERR] at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
| 12:25:58,989 ERROR [STDERR] at java.lang.Thread.run(Unknown Source)
| 12:25:59,005 INFO [CachedConnectionManager] Closing a connection for you. Please close them yourself: org.jboss.resource.adapter.jms.JmsSession@ed7f5c
| java.lang.Throwable: STACKTRACE
| at org.jboss.resource.connectionmanager.CachedConnectionManager.registerConnection(CachedConnectionManager.java:290)
| at org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:417)
| at org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectionManager2.java:842)
| at org.jboss.resource.adapter.jms.JmsSessionFactoryImpl.allocateConnection(JmsSessionFactoryImpl.java:389)
| at org.jboss.resource.adapter.jms.JmsSessionFactoryImpl.createTopicSession(JmsSessionFactoryImpl.java:166)
| at elimina.ServletPrueba.service(ServletPrueba.java:75)
| at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
| at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
| at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
| at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
| at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
| at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
| at org.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
| at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
| at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
| at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
| at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
| at java.lang.Thread.run(Unknown Source)
|
|
Here is the code ...
|
| package elimina;
|
| import javax.jms.Message;
| import javax.jms.Session;
| import javax.jms.TextMessage;
| import javax.jms.Topic;
| import javax.jms.TopicConnection;
| import javax.jms.TopicConnectionFactory;
| import javax.jms.TopicSession;
| import javax.jms.TopicSubscriber;
| import javax.management.ObjectName;
| import javax.naming.Context;
| import javax.naming.InitialContext;
| import javax.servlet.http.HttpServlet;
|
| import java.io.IOException;
| import java.util.Hashtable;
|
| import javax.servlet.ServletException;
| import javax.servlet.http.HttpServletRequest;
| import javax.servlet.http.HttpServletResponse;
|
| /**
| * Servlet Class
| *
| * @web.servlet name="ServletPrueba"
| * display-name="Name for ServletPrueba"
| * description="Description for ServletPrueba"
| * @web.servlet-mapping url-pattern="/ServletPrueba"
| * @web.servlet-init-param name="A parameter"
| * value="A value"
| */
| public class ServletPrueba extends HttpServlet implements javax.jms.MessageListener {
|
| public ServletPrueba() {
| // TODO Auto-generated constructor stub
| }
|
| public void onMessage (Message message) {
| try {
| TextMessage textMessage = (TextMessage) message;
| System.out.println("Mensaje recibido");
| } catch (Exception e) {
| // Ver excepciones y tratamiento
| System.out.println(e);
| }
| }
|
| protected void service(HttpServletRequest req, HttpServletResponse resp)
| throws ServletException,
| IOException {
| // TODO Auto-generated method stub
| Topic topic = null;
| TopicConnectionFactory topicConnectionFactory = null;
| TopicConnection topicConnection = null;
|
| super.service(req, resp);
| try {
| Hashtable props = new Hashtable();
| props.put(
| Context.INITIAL_CONTEXT_FACTORY,
| "org.jnp.interfaces.NamingContextFactory");
| props.put(
| Context.URL_PKG_PREFIXES,
| "org.jboss.naming:org.jnp.interfaces");
| props.put(Context.PROVIDER_URL, "jnp://localhost:1099");
| Context ctx = new InitialContext(props);
|
| topicConnectionFactory = (TopicConnectionFactory)ctx.lookup("TopicConnectionFactory");
| topic = (Topic)ctx.lookup("topic/testTopic");
| ctx.close();
|
| // conectamos
| topicConnection = topicConnectionFactory.createTopicConnection();
| TopicSession topicSession = topicConnection.createTopicSession(false, Session.AUTO_ACKNOWLEDGE);
|
|
| TopicSubscriber topicSubscriber = topicSession.createSubscriber(topic);
| topicSubscriber.setMessageListener(this);
|
| topicConnection.start();
| for (;;) {
| java.io.OutputStream out = resp.getOutputStream();
| out.write("1".getBytes());
| out.write(new byte[450]);
| out.flush();
| Thread.sleep(100);
| }
|
| } catch (Exception e) {
| // Ver que excepciones lanza y el trataimento
| e.printStackTrace();
| }
|
|
| }
|
| }
Thanks in advanced
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4036664#4036664
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4036664
19 years