Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [alf-dev] Availability of POC infrastructure pieces?

Hi Bob,

Thanks for the tips.  I made some progress based on this:

1. Hand crafted a war directory in my Eclipse ALF project per your
suggestions below.  One small change that I made was to not create a jar
file for the EventManager bits, but placed them in a WEB-INF/classes
directory instead.  When I get around to creating a build.xml for an ant
build of the EM, I'll change this so that build & deploy target builds the
jar and builds/deploys the war.  I then manually copied the war directory to
the tomcat webapps dir.

2. Not sure what the proper contents of the alf_logging.properties file
should be, so I used boilerplate contents:

# Set root logger level to DEBUG and its only appender to A1.
log4j.rootLogger=DEBUG, A1

# A1 is set to be a ConsoleAppender.
log4j.appender.A1=org.apache.log4j.ConsoleAppender

# A1 uses PatternLayout.
log4j.appender.A1.layout=org.apache.log4j.PatternLayout
log4j.appender.A1.layout.ConversionPattern=%-4r [%t] %-5p %c %x - %m%n

This dumps to the Tomcat console window and does not create any
alf_event.log, nor does it dump anything into the tomcat temp dir...

3. Had to download and deploy the ActiveBPEL samples in order to obtain both
their soap_client and the AsynchEchoCallerService.  These can be found at:
http://www.active-endpoints.com/samples/samples-2/samples.php

The files are 'all.zip' or 'all.tar.gz' depending on your platform.

4. When I run the soap_client, I do get some activity on the Tomcat console
log, followed by an uncaught Java exception:

0    [http-8080-Processor24] INFO
org.eclipse.alf.eventManager.ALFHttpServlet
- <?xml version="1.0" encoding="UTF-8"?><soapenv:Envelope
xmlns:soapenv="http://
schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema";
 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";>
 <soapenv:Body>
  <ns1:asynctestRequest
xmlns:ns1="urn:active-endpoints.resources.wsdl.2005-10.a
sync_echo">
    <ns1:input>The string to echo.</ns1:input>

</ns1:asynctestRequest>
 </soapenv:Body>
</soapenv:Envelope>
0    [http-8080-Processor24] INFO
org.eclipse.alf.eventManager.ALFHttpServlet
- Processing Asnyc Echo Request...
(500)Internal Server Error
javax.xml.soap.SOAPException: (500)Internal Server Error
        at
org.apache.axis.soap.SOAPConnectionImpl.call(SOAPConnectionImpl.java:95)
        at
org.activebpel.samples.soap_client.SOAPClient.invoke(SOAPClient.java:75)
        at
org.activebpel.samples.soap_client.SOAPClient.invokeStat(SOAPClient.java:56)
        at
org.apache.jsp.index_jsp._jspService(org.apache.jsp.index_jsp:148)
        at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
        at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:3
32)
        at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:252)
        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:173)
        at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va:213)
        at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va:178)
        at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126
)
        at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105
)
        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.processC
onnection(Http11BaseProtocol.java:667)
        at
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.jav
a:527)
        at
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWo
rkerThread.java:80)
        at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav
a:684)
        at java.lang.Thread.run(Thread.java:595)
Caused by: (500)Internal Server Error
        at
org.apache.axis.transport.http.HTTPSender.readFromSocket(HTTPSender.java:744
)
        at
org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:144)

        at
org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:
32)
        at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
        at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
        at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)
        at org.apache.axis.client.Call.invokeEngine(Call.java:2765)
        at org.apache.axis.client.Call.invoke(Call.java:2748)
        at org.apache.axis.client.Call.invoke(Call.java:1862)
        at
org.apache.axis.soap.SOAPConnectionImpl.call(SOAPConnectionImpl.java:90)
        ... 23 more

So, some progress, but I need to figure out why invokeService is failing so
loudly...

Thanks,

- matt


 
> -----Original Message-----
> From: alf-dev-bounces@xxxxxxxxxxx 
> [mailto:alf-dev-bounces@xxxxxxxxxxx] On Behalf Of Robert Brady
> Sent: Wednesday, April 12, 2006 6:03 PM
> To: ALF Developer Mailing List
> Subject: RE: [alf-dev] Availability of POC infrastructure pieces?
> 
> Hi Matt,
> 
> I have downloaded the ALF Event Manager code from CVS, 
> integrated with the latest activeBPEL engine, and have got 
> the Event Manager to kick off activeBPEL's asyncEcho.  No, 
> it's not a full-blown ALF implementation, but it's a babystep 
> in the right direction and good to tinker with.
> 
> Here's a thumbnail How-to:
> 
> 1) In the Catalina home where you installed activeBPEL create 
> the dirs "alfeventmgr/WEB-INF" under webapps.
> 
> 2) Add a web.xml file to WEB-INF dir in 1) that defines the 
> event mgr servlets and a param value for property files.  
> Here's a snippet of what goes in there:
> 
> <web-app>
>  <context-param>
>    <param-name>alfPropertiesHome</param-name>
>    <param-value>/WEB-INF/</param-value>
>   </context-param>
> 
>   <display-name>ALF Event Notification</display-name>
>   <description>
>       ALF Event Notification Web Services.
>   </description>
> 
>     <!-- Define services that are included in the example application
> -->
>     <servlet>
> 	<servlet-name>ALFEventManager</servlet-name>
> 	
> <servlet-class>org.eclipse.alf.eventManager.ALFEventManager</s
> ervlet-cla
> ss>
>     </servlet>
> 		
>     <servlet-mapping>
> 	<servlet-name>ALFEventManager</servlet-name>
> 	<url-pattern>/services/ALFEventManager</url-pattern>
>     </servlet-mapping>
> </web-app>
> 
> 
> 3) Add three files to your WEB-INF dir:
> 	alf_logging.properties => log4j properties file
>       alf_messages.properties => not needed now, I just put 
> empty file here
> 	EventActionMap.xml => Not really needed for baby 
> prototype (see step 4), but I used dummy contents below:
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <ALFEventRule xmlns:p="http://www.eclipse.org/ALF/XMLSchema/EventRule";
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";>
>   <Conditions>
>     <EventType>Successful Completion</EventType>
>     <ObjectType>Test</ObjectType>
>     <Product>SilkCentral</Product>
>     <ProductVersion>8.1</ProductVersion>
>     <ProductInstance />
>     <Action>
>       <ServiceFlow>
>  
> <Endpoint>http://localhost:8080/active-bpel/services/AsyncEcho
> CallerServ
> ice</Endpoint>
>       </ServiceFlow>
>     </Action>
>   </Conditions>
> </ALFEventRule>        
> 
> 4) Change ALFEventManager.java for babystep:
> 
>    in processMessage(SOAPMessage soapMessage) I put this 
> after second line in method:
> 
> 		SOAPElement elementInput = (SOAPElement) 
> body.getElementsByTagName("input").item(0);
> 		if(elementInput.getValue() != null)
> 		{
> 			logEvent("Processing Asnyc Echo Request...");
> 			processHelloWorldEvent(soapEnvelope);
> 			return;
> 		}
> 
> And processHelloWorldEvent() looks like:
> 
> private void processHelloWorldEvent(SOAPEnvelope soapEnvelope) {
> 		EventAction eventAction = new EventAction();
> 	
> eventAction.addServiceFlow("http://localhost:8080/active-bpel/
> services/A
> syncEchoCallerService");
> 		invokeService(soapEnvelope, eventAction);
> 	}
> 
> The idea here is to capture message from activeBPEL soap 
> client and send out to activeBPEL engine, then look at logs 
> and congratulate ourselves (and Serena!)
> 
> 5) Clean ALF project, make jar file of all classes, place jar 
> lib dir under WEB-INF dir of 1)
> 
> 6) Add axis jars to a lib dir of 5)
> 
> 7) Start tomcat (and thus activeBPEL engine), go to activeBPEL soap
> client:
> http://localhost:8080/soap_client/index.jsp (assume port 8080)
> 
> enter service URL:
> http://localhost:8080/alfeventmgr/services/ALFEventManager
> 
> paste message content to alf event mgr into form:
> <ns1:asynctestRequest
>     
> xmlns:ns1="urn:active-endpoints.resources.wsdl.2005-10.async_echo">
>   <ns1:input>The string to echo.</ns1:input> </ns1:asynctestRequest>
> 
> click "invoke"
> 
> 8) Look at logs in catalina_home/temp to verify or 
> caltalina_home/bin/alf_event.log
> 
> 9) Enjoy babystep & tinker more!
> 
> 
> -Bob
> 
> 
> Bob Brady, Ph.D.
> Senior Software Engineer
> Segue Software
> 201 Spring Street
> Lexington, MA 02421
> t: 781-402-5975
> f: 781-402-1097
> e: rbrady@xxxxxxxxx
> w: www.segue.com
> 
> -----Original Message-----
> From: alf-dev-bounces@xxxxxxxxxxx [mailto:alf-dev-bounces@xxxxxxxxxxx]
> On Behalf Of Matthew Laudato
> Sent: Wednesday, April 12, 2006 5:09 PM
> To: 'ALF Developer Mailing List'
> Subject: RE: [alf-dev] Availability of POC infrastructure pieces?
> 
> > Mark Phippard wrote on 3/8/2006:
> > 
> > I think the main issue is that sometime in the not too 
> distant future, 
> > there needs to be a reasonable set of instructions for 
> setting up an 
> > ALF test environment.  This is especially true if you want 
> people from 
> > the open source community to be able to get involved.
> > 
> 
> Has there been any progess on this front?  I've built the 
> basic AccuRev web services interface, but there's no way 
> currently to test this with ALF.
> The
> environment I'm using is similar to the list posted on this thread
> earlier:
> 
> Present and used:
> Apache 2.0.55 (Windows)
> Tomcat 5.5
> Axis 1.3
> Eclipse 3.1.1 with WTP (but the WTP stuff wasn't very 
> helpful...I pretty much punted on these and used Axis)
> 
> The Tomcat common and shared libs together have everything 
> one needs to run Axis (especially activation.jar).
> 
> Present but currently unused:
> ActiveBPEL 1.2
> Oracle BPEL Designer Eclipse plugin
> 
> These are unused because I have no ALF war file to drop in 
> for testing purposes, so I haven't taken a look at them yet.
> 
> I took the approach of hand-coding WSDL and then using the 
> Axis WSDL2Java to generate stubs/skels, etc.  Writing the 
> implementation and client test code was straight-forward from 
> there.  I also hand-built the war directory inside of Eclipse 
> and pointed my default Tomcat context to this directory.
> Pretty
> easy to do once I was done mud wrestling with the tools.  
> Currently there are two supported methods:
> 
> AccuRevCommand_execute - this is a big bucket method along 
> the lines of what Steve Taylor did for Openmake.
> UpdateReferenceStream_execute - this updates a specified 
> AccuRev reference stream.  A ref stream is a read-only copy 
> of a stream (the AccuRev term for a collection of versioned 
> elements) that is often used by our customers (and by us, for 
> that matter) for nightly builds.
> 
> There is ongoing work by AccuRev to extend this set, along 
> the lines of whatever comes out of the ALF SCM Vocabulary 
> meetings that we are participating in.
> 
> As I have mentioned in earlier posts, I have built the Event 
> Manager, but without without the property files, the various 
> XML files, and really, the whole ALF war file (assuming such 
> a thing exists?), it is not much help (but it is a good read!)
> 
> Anxiously awaiting ALF at AccuRev!
> 
> Thanks,
>  - matt
> 
> 
> 
> _______________________________________________
> alf-dev mailing list
> alf-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/alf-dev
> _______________________________________________
> alf-dev mailing list
> alf-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/alf-dev
> 




Back to the top