tuscany-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Poonam Mane <poonam.m...@opennotus.com>
Subject Re: Apache Tuscany SCA : Error - cannot be resolved to a type
Date Thu, 28 Jul 2011 14:36:24 GMT
Thanks Ramond for your reply.

Yes, the EventsStastics is in the class path (it runs from Test.java). I can
show you the part of .rf file where this component (EventsStastics) is
called. Please find attached the .rf file daigram.
Below is the part of the code from .rf that calls EventsStastics

SCADomain scaDomain = (SCADomain) kcontext.getVariable("scaContext");

EventsStatistics eventsStastics =
scaDomain.getService(EventsStatistics.class,"EventsStatisticsComponent");

eventsStastics.createEvent("Kimstaff","HealthNet","CARRIERFILE", "HealthNet
Validation", discrepancyURL, "KimstaffEvents", "Discrepancies found!.",
"Serious",  (String) kcontext.getVariable("ofbizCustomerId"), (String)
kcontext.getVariable("ofbizPartnerId"));

CarrierStatsDTO carrierStats = (CarrierStatsDTO)
kcontext.getVariable("carrierStats");

eventsStastics.updateCarrierStat("Kimstaff","HealthNet",(String)
kcontext.getVariable("ofbizCustomerId"), (String)
kcontext.getVariable("ofbizPartnerId"), carrierStats.getSubscribers(),
carrierStats.getDependents(), carrierStats.getSuccesses(),
carrierStats.getFailures(), "Discrepancies found",
discrepancyURL,"verification", "", "WARN");


On Wed, Jul 27, 2011 at 4:09 PM, Raymond Feng <enjoyjava@gmail.com> wrote:

> Hi,
>
> It seems that you try to call Tuscany from the Drools flow. Can you show us
> the .rf file? Do you have EventsStatistics on the class path? You can also
> check if the kimstaff/ruleflow/Process_kimstaff_ruleflow_0.java has the
> fully-qualified class name of EventsStatistics?
>
> Thanks,
> Raymond
> ________________________________________________________________
> Raymond Feng
> rfeng@apache.org
> Apache Tuscany PMC member and committer: tuscany.apache.org
> Co-author of Tuscany SCA In Action book: www.tuscanyinaction.com
> Personal Web Site: www.enjoyjava.com
> ________________________________________________________________
>
> On Jul 27, 2011, at 2:54 PM, Poonam Mane wrote:
>
> > Hi,
> >
> > I am a newbie in Apche Tuscany SCA. I am getting any error while running
> the some components I have written in Apache Tuscany SCA. I will appreciate
> any help on this error. Please let me know if you need more information.
> >
> > Scenario 1: Success
> > If the Events Stasticts is directly called from a test.java, the code run
> successfully.
> > Test.java
> > EventsStatistics eventsStastics =
> scaDomain.getService(EventsStatistics.class,"EventsStatisticsComponent");
> >
> > Scenario 2: Failure
> > I call the same file via .rf file (drool file) it throws me error:
> > Process Compilation error : org.drools.lang.descr.ProcessDescr@3f3fbd
> >       kimstaff/ruleflow/Process_kimstaff_ruleflow_0.java (259:10381) :
> EventsStatistics cannot be resolved to a type
> >
> > <1.PNG>
> >
> > composite file
> > <sca:component name="EventsStatisticsComponent">
> >     <sca:implementation.java
> class="opennotus.ba.impl.EventsStatisticsImpl"/>
> >     <sca:service name="EventsStatistics">
> >       <sca:interface.java interface="opennotus.ba.EventsStatistics"/>
> >     </sca:service>
> >     <sca:reference name="existConnection"
> target="ExistAppConfigComponent"/>
> >   </sca:component>
> >
> >   <sca:component name="ExistAppConfigComponent">
> >       <sca:service name="ExistAppConfig">
> >       <sca:interface.java interface="opennotus.ba.ExistAppConfig"/>
> >     </sca:service>
> >     <sca:implementation.java
> class="opennotus.ba.impl.ExistAppConfigImpl"/>
> >     <sca:property name="existConfigFile"> </sca:property>
> >       <sca:property name="hostName"> </sca:property>
> >       <sca:property name="hostPort"></sca:property>
> >       <sca:property name="connectionProtocol"> </sca:property>
> >       <sca:property name="existBaseURI"> </sca:property>
> >       <sca:property name="existUserId"> </sca:property>
> >       <sca:property name="existPasswd"></sca:property>
> >   </sca:component>
> >
> > Thanks,
> > Poonam
>
>

Mime
View raw message