(.) You do call the method fireAllRules() on the engine?<br>(.) To see what you actually have in WM, add a rule<br>rule "any"<br>when<br> $obj : Object()<br>then<br> System.out.println( "obj: " + $obj.getClass() );<br>
end<br><br>-W<br><br><div class="gmail_quote">On Tue, Apr 20, 2010 at 1:14 AM, mikexr <span dir="ltr"><<a href="mailto:mike@bigfatnuthin.com">mike@bigfatnuthin.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
I have been working on a test to try and get up to speed on DROOLS. And I am<br>
having some challenges.'<br>
<br>
I have this rule.<br>
<br>
#created on: Apr 1, 2010<br>
package com.regence.edi.rules;<br>
<br>
#list any import classes here.<br>
import com.regence.edi.enrollment.Person;<br>
import com.regence.edi.enrollment.GroupIdentifier;<br>
import com.regence.edi.enrollment.Enrollments;<br>
<br>
<br>
<br>
#declare any global variables here<br>
<br>
rule "New Enrollment Rule"<br>
no-loop<br>
dialect "mvel"<br>
ruleflow-group "834RuleflowGroup"<br>
when<br>
#conditions<br>
Enrollments( enrollmentType == "NewEnrollment")<br>
then<br>
#actions<br>
System.out.println("Found Subscriber<br>
"+Enrollments.EnrollmentPolicy.Enrollment.Person.getName())<br>
System.out.println("for GroupID " +<br>
Enrollments.GroupIdentifier.getGroupId())<br>
System.out.println("Setting Source Name to Mike")<br>
Enrollments.setSourceName("Mike")<br>
<br>
end<br>
<br>
<br>
It compiles and runs but nothing happens<br>
<br>
I debugged the code and the data is being passed to the rules engine. but<br>
it doesn seem like the rule is executing.<br>
<br>
<?xml version="1.0" encoding="UTF-8" standalone="yes"?><br>
<EnrollmentRequest><br>
<Enrollments><br>
<EnrollmentType>NewEnrollment</EnrollmentType><br>
<SourceName>USRINPUT</SourceName><br>
<GroupIdentifier><br>
<GroupId>60004854</GroupId><br>
<SubGroupID>1</SubGroupID><br>
</GroupIdentifier><br>
<EnrollmentPolicy><br>
<HoursPerWeekWorked>40</HoursPerWeekWorked><br>
<Enrollment><br>
<Event><br>
<EventType>NEW</EventType><br>
<EventDate>05/15/2009</EventDate><br>
<EventEffectiveDate>06/10/2009</EventEffectiveDate><br>
<EventTerminationDate/><br>
<BreakInCoverage/><br>
<QualifyingEvent/><br>
<Description/><br>
<Reason/><br>
</Event><br>
<Cobra><br>
<CobraType/><br>
<QualifyingEvent/><br>
<CobraEffectiveDate/><br>
<CertificateLength/><br>
<CobraTerminationDate/><br>
</Cobra><br>
<Person><br>
<Name><br>
<FirstName>TEST</FirstName><br>
<LastName>ENROLLMENT</LastName><br>
<MiddleName/><br>
<NameSuffix/><br>
</Name><br>
<DateOfBirth>05/05/1976</DateOfBirth><br>
<Gender>Male</Gender><br>
<MaritalStatus>Single</MaritalStatus><br>
<Language>ENGL</Language><br>
<PersonIdentifier><br>
<PersonId>555555555</PersonId><br>
<br>
<PersonIdentifierType>SocialSecurityNumber</PersonIdentifierType><br>
</PersonIdentifier><br>
<PersonIdentifier><br>
<PersonId>55555567345</PersonId><br>
<br>
<PersonIdentifierType>MedicareId</PersonIdentifierType><br>
</PersonIdentifier><br>
<PriorCoverage><br>
<CarrierName>Kaiser</CarrierName><br>
<PolicyHolderID>345545</PolicyHolderID><br>
<EffectiveDate>01/01/2009</EffectiveDate><br>
<TerminationDate>01/31/2009</TerminationDate><br>
<PolicyHolderName>Medical</PolicyHolderName><br>
</PriorCoverage><br>
<PriorCoverage><br>
<CarrierName>Providence</CarrierName><br>
<PolicyHolderID>23474</PolicyHolderID><br>
<EffectiveDate>02/01/2009</EffectiveDate><br>
<TerminationDate>03/31/2009</TerminationDate><br>
<PolicyHolderName>Medical</PolicyHolderName><br>
</PriorCoverage><br>
<ContactInformation><br>
<AddressDetails><br>
<ContactType>Home</ContactType><br>
<Address><br>
<AliasName>ADDR1</AliasName><br>
<AddressLine1>56 Test Street</AddressLine1><br>
<AddressLine2/><br>
<City>Portland</City><br>
<County>Multnomah</County><br>
<State>OR</State><br>
<ZipCode>97203</ZipCode><br>
<Country>US</Country><br>
</Address><br>
</AddressDetails><br>
<AddressDetails><br>
<ContactType>Mailing</ContactType><br>
<Address><br>
<AliasName>ADDR1</AliasName><br>
<AddressLine1>89 Mailing Street</AddressLine1><br>
<AddressLine2/><br>
<City>Portland</City><br>
<County>Multnomah</County><br>
<State>OR</State><br>
<ZipCode>97203</ZipCode><br>
<Country>US</Country><br>
</Address><br>
</AddressDetails><br>
<PhoneNumber><br>
<ContactType>Home</ContactType><br>
<PhoneNumber>665-567-8888</PhoneNumber><br>
</PhoneNumber><br>
<EMailAddress><br>
<EmailAddress><a href="mailto:user@home.com">user@home.com</a></EmailAddress><br>
</EMailAddress><br>
</ContactInformation><br>
<Membership><br>
<MembershipIdentifier><br>
<MemberID/><br>
<br>
<MemberIdentifierType>CPSS_SBSB_ID</MemberIdentifierType><br>
</MembershipIdentifier><br>
<br>
<RelationshipToSubscriber>Subscriber</RelationshipToSubscriber><br>
<MemberIndex>0</MemberIndex><br>
<InsuranceIDCard><br>
<IDLevel>FAMILY</IDLevel><br>
<IDBackground>100</IDBackground><br>
</InsuranceIDCard><br>
<Eligibility><br>
<Coverage><br>
<ClassId>1</ClassId><br>
<Product><br>
<ProductId>MINN1001</ProductId><br>
<BusinessCategory>M</BusinessCategory><br>
</Product><br>
<Product><br>
<ProductId>RX000001</ProductId><br>
<BusinessCategory>R</BusinessCategory><br>
</Product><br>
</Coverage><br>
</Eligibility><br>
<Preference><br>
<PreferenceType>EEOB</PreferenceType><br>
<Detail><br>
<DetailType>EMAIL</DetailType><br>
<DetailValue><a href="mailto:user@home2.com">user@home2.com</a></DetailValue><br>
</Detail><br>
</Preference><br>
</Membership><br>
<Medicare><br>
<Entitlement>Blah</Entitlement><br>
<br>
<EntitlementStartDate>01/01/2008</EntitlementStartDate><br>
<EntitlementEndDate/><br>
<MedicareProgram><br>
<MedicareProgramType>TypeA</MedicareProgramType><br>
<EffectiveDate>01/01/2008</EffectiveDate><br>
<TerminationDate></TerminationDate><br>
</MedicareProgram><br>
<MedicareProgram><br>
<MedicareProgramType>TypeB</MedicareProgramType><br>
<EffectiveDate>01/01/2008</EffectiveDate><br>
<TerminationDate></TerminationDate><br>
</MedicareProgram><br>
</Medicare><br>
<Disability><br>
<IsDisabled>false</IsDisabled><br>
<DisabledDate/><br>
<Description/><br>
<VerifiedBy/><br>
<VerifiedDate/><br>
<VerificationMethod>EMAIL</VerificationMethod><br>
</Disability><br>
</Person><br>
</Enrollment><br>
</EnrollmentPolicy><br>
</Enrollments><br>
</EnrollmentRequest><br>
<br>
<br>
I am looking for some assistance<br>
<br>
Thanks<br>
<br>
Mike<br>
<font color="#888888"><br>
--<br>
View this message in context: <a href="http://n3.nabble.com/Rules-Not-executing-tp731013p731013.html" target="_blank">http://n3.nabble.com/Rules-Not-executing-tp731013p731013.html</a><br>
Sent from the Drools - User mailing list archive at Nabble.com.<br>
_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
</font></blockquote></div><br>