You can subscribe to this list here.
| 2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(233) |
Sep
(199) |
Oct
(206) |
Nov
(185) |
Dec
(270) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2006 |
Jan
(232) |
Feb
(426) |
Mar
(623) |
Apr
(592) |
May
(506) |
Jun
(389) |
Jul
(160) |
Aug
(3) |
Sep
(1) |
Oct
(1) |
Nov
(2) |
Dec
(5) |
| 2007 |
Jan
(1) |
Feb
(1) |
Mar
(2) |
Apr
(2) |
May
(4) |
Jun
(2) |
Jul
|
Aug
(3) |
Sep
(5) |
Oct
(9) |
Nov
(6) |
Dec
(6) |
| 2008 |
Jan
(3) |
Feb
|
Mar
(1) |
Apr
(3) |
May
(3) |
Jun
(5) |
Jul
(10) |
Aug
(2) |
Sep
(12) |
Oct
(10) |
Nov
(54) |
Dec
(49) |
| 2009 |
Jan
(19) |
Feb
(13) |
Mar
(20) |
Apr
(24) |
May
(44) |
Jun
(29) |
Jul
(32) |
Aug
(10) |
Sep
(7) |
Oct
(10) |
Nov
(4) |
Dec
(17) |
| 2010 |
Jan
(14) |
Feb
(5) |
Mar
(23) |
Apr
(50) |
May
(31) |
Jun
(9) |
Jul
(5) |
Aug
(4) |
Sep
(7) |
Oct
(5) |
Nov
(2) |
Dec
(3) |
| 2011 |
Jan
(12) |
Feb
(5) |
Mar
(5) |
Apr
(3) |
May
(4) |
Jun
(3) |
Jul
(2) |
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
| 2012 |
Jan
(1) |
Feb
(2) |
Mar
|
Apr
(1) |
May
(1) |
Jun
(2) |
Jul
(4) |
Aug
(1) |
Sep
|
Oct
(1) |
Nov
|
Dec
|
| 2013 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(2) |
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
| 2014 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(3) |
Sep
|
Oct
|
Nov
|
Dec
(1) |
| 2015 |
Jan
|
Feb
|
Mar
(2) |
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2016 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: <jbo...@li...> - 2006-06-06 12:35:28
|
Author: mic...@jb... Date: 2006-06-06 08:34:37 -0400 (Tue, 06 Jun 2006) New Revision: 4646 Modified: labs/jbossrules/updates/drools-ide-update/plugins/org.drools.ide_3.0.1.jar Log: patched for serialization Modified: labs/jbossrules/updates/drools-ide-update/plugins/org.drools.ide_3.0.1.jar =================================================================== (Binary files differ) |
|
From: <jbo...@li...> - 2006-06-06 12:14:53
|
Author: mar...@jb... Date: 2006-06-06 08:14:47 -0400 (Tue, 06 Jun 2006) New Revision: 4645 Added: labs/jbossrules/tags/3.0-GA/ Log: -moved 3.0-GA Copied: labs/jbossrules/tags/3.0-GA (from rev 4643, labs/jbossrules/3.0-GA) |
|
From: <jbo...@li...> - 2006-06-06 12:14:03
|
Author: mar...@jb... Date: 2006-06-06 08:13:57 -0400 (Tue, 06 Jun 2006) New Revision: 4644 Removed: labs/jbossrules/3.0-GA/ Log: -moved 3.0-GA |
|
From: <jbo...@li...> - 2006-06-06 12:03:07
|
Author: mar...@jb... Date: 2006-06-06 08:03:02 -0400 (Tue, 06 Jun 2006) New Revision: 4643 Added: labs/jbossrules/tags/3.0.1-GA/ Log: made a copy Copied: labs/jbossrules/tags/3.0.1-GA (from rev 4642, labs/jbossrules/trunk) |
|
From: <jbo...@li...> - 2006-06-06 12:02:06
|
Author: mar...@jb... Date: 2006-06-06 08:02:02 -0400 (Tue, 06 Jun 2006) New Revision: 4642 Removed: labs/jbossrules/tags/3.0.1-GA/ Log: -deleted old 3.0.1 |
|
From: <jbo...@li...> - 2006-06-06 11:52:32
|
Author: mar...@jb... Date: 2006-06-06 07:52:27 -0400 (Tue, 06 Jun 2006) New Revision: 4641 Modified: labs/jbossesb/trunk/xml/common/contract.xsd Log: updated contract definition. Modified: labs/jbossesb/trunk/xml/common/contract.xsd =================================================================== --- labs/jbossesb/trunk/xml/common/contract.xsd 2006-06-06 10:59:26 UTC (rev 4640) +++ labs/jbossesb/trunk/xml/common/contract.xsd 2006-06-06 11:52:27 UTC (rev 4641) @@ -1,8 +1,24 @@ <?xml version="1.0" encoding="UTF-8"?> - -<!-- -<contracts> - <wsdl-location></wsdl-location> -</contracts> ---> - \ No newline at end of file +<schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.example.org/esb/contract" xmlns:tns="http://www.example.org/esb/contract" xmlns:wsa="http://www.w3.org/2005/08/addressing"> + <xs:import namespace="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"/> + <xs:complexType name="ContractDefinition"> + <xs:sequence> + <xs:any maxOccurs="unbounded" minOccurs="0" namespace="##other" processContents="lax"/> + <xs:element name="serviceType" type="xs:anyURI"/> + <xs:element minOccurs="0" name="serviceSubType" type="xs:anyURI"/> + <xs:element minOccurs="0" name="version" type="xs:anyURI"/> + <xs:element minOccurs="0" name="protocols" type="ProtocolData"/> + <!-- + <xs:element minOccurs="0" name="policies" type="wsp:Policy"/> + --> + </xs:sequence> + <xs:attribute ref="wsu:Id" use="optional"/> + </xs:complexType> + + <xs:complexType name="ProtocolData"> + <xs:sequence> + <xs:element name="epr" type="wsa:EndpointReferenceType"/> + <xs:any maxOccurs="unbounded" minOccurs="0" namespace="##other" processContents="lax"/> + </xs:sequence> + </xs:complexType> +</schema> \ No newline at end of file |
|
From: <jbo...@li...> - 2006-06-06 10:59:29
|
Author: mar...@jb...
Date: 2006-06-06 06:59:26 -0400 (Tue, 06 Jun 2006)
New Revision: 4640
Modified:
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/CompositeConflictResolver.java
Log:
JBRULES-285 WorkingMemory is not serializable
-Fixed bad copy paste in leaps
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/CompositeConflictResolver.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/CompositeConflictResolver.java 2006-06-06 10:46:47 UTC (rev 4639)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/CompositeConflictResolver.java 2006-06-06 10:59:26 UTC (rev 4640)
@@ -73,13 +73,13 @@
final Object o2) {
int ret = 0;
if ( o1 != o2 ) {
- for ( int i = 0, length = CompositeConflictResolver.this.factResolvers.length; ret == 0 && i < length; ++i ) {
- ret = CompositeConflictResolver.this.factResolvers[i].compare( o1,
+ for ( int i = 0, length = CompositeConflictResolver.this.ruleResolvers.length; ret == 0 && i < length; ++i ) {
+ ret = CompositeConflictResolver.this.ruleResolvers[i].compare( o1,
o2 );
}
}
return ret;
- }
+ }
}
}
\ No newline at end of file
|
|
From: <jbo...@li...> - 2006-06-06 10:47:04
|
Author: mar...@jb...
Date: 2006-06-06 06:46:47 -0400 (Tue, 06 Jun 2006)
New Revision: 4639
Modified:
labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/IntegrationCases.java
labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/LeapsTest.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/ColumnConstraints.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/ConflictResolver.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/LeapsRule.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/LeapsWorkingMemory.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/CompositeConflictResolver.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/LoadOrderConflictResolver.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/RuleComplexityConflictResolver.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/RuleSalienceConflictResolver.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/util/TokenStack.java
Log:
JBRULES-285 WorkingMemory is not serializable
-Updated leaps to be serializable
Modified: labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/IntegrationCases.java
===================================================================
--- labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/IntegrationCases.java 2006-06-06 09:59:25 UTC (rev 4638)
+++ labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/IntegrationCases.java 2006-06-06 10:46:47 UTC (rev 4639)
@@ -1688,13 +1688,8 @@
}
- public void testSerializable() throws Exception {
-// PrimitiveLongMap longMap = new PrimitiveLongMap(8, 32);
-//
-// final byte[] map = serializeOut( longMap );
-// longMap = (PrimitiveLongMap) serializeIn( map );
+ public void testSerializable() throws Exception {
-
final Reader reader = new InputStreamReader( getClass().getResourceAsStream( "test_Serializable.drl" ) );
final PackageBuilder builder = new PackageBuilder();
@@ -1727,7 +1722,7 @@
workingMemory.setGlobal( "list", new ArrayList() );
- workingMemory.assertObject( new Integer(5) );
+ workingMemory.assertObject( new Integer(5) );
final byte[] wm = serializeOut( workingMemory );
@@ -1747,8 +1742,7 @@
assertEquals( 2, workingMemory.getObjects().size() );
assertEquals( new Integer( 5 ) , workingMemory.getObjects().get(0) );
- assertEquals( "help" , workingMemory.getObjects().get(1) );
-
+ assertEquals( "help" , workingMemory.getObjects().get(1) );
}
public void testLogicalAssertions() throws Exception {
@@ -2270,7 +2264,7 @@
assertTrue( list.contains( "fired3" ) );
}
- private Object serializeIn(final byte[] bytes) throws IOException,
+ protected Object serializeIn(final byte[] bytes) throws IOException,
ClassNotFoundException {
final ObjectInput in = new ObjectInputStream( new ByteArrayInputStream( bytes ) );
final Object obj = in.readObject();
@@ -2278,7 +2272,7 @@
return obj;
}
- private byte[] serializeOut(final Object obj) throws IOException {
+ protected byte[] serializeOut(final Object obj) throws IOException {
// Serialize to a byte array
final ByteArrayOutputStream bos = new ByteArrayOutputStream();
final ObjectOutput out = new ObjectOutputStream( bos );
Modified: labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/LeapsTest.java
===================================================================
--- labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/LeapsTest.java 2006-06-06 09:59:25 UTC (rev 4638)
+++ labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/LeapsTest.java 2006-06-06 10:46:47 UTC (rev 4639)
@@ -16,7 +16,9 @@
* limitations under the License.
*/
+import java.io.ByteArrayInputStream;
import java.io.InputStreamReader;
+import java.io.Reader;
import java.util.ArrayList;
import java.util.List;
@@ -28,6 +30,7 @@
import org.drools.WorkingMemory;
import org.drools.compiler.PackageBuilder;
import org.drools.rule.Package;
+import org.drools.rule.Rule;
/**
* This runs the integration test cases with the leaps implementation.
@@ -229,6 +232,61 @@
leapsRuleBase.removePackage( "org.drools.test" );
assertEquals( 0, workingMemory.getAgenda( ).getActivations( ).length );
+ }
+
+ public void testSerializable() throws Exception {
+
+ final Reader reader = new InputStreamReader( getClass().getResourceAsStream( "test_Serializable.drl" ) );
+ final PackageBuilder builder = new PackageBuilder();
+ builder.addPackageFromDrl( reader );
+ final Package pkg = builder.getPackage();
+
+ assertEquals( 0,
+ builder.getErrors().length );
+
+ RuleBase ruleBase = getRuleBase();//RuleBaseFactory.newRuleBase();
+
+ ruleBase.addPackage( pkg );
+
+ final byte[] ast = serializeOut( ruleBase );
+ ruleBase = (RuleBase) serializeIn( ast );
+ final Rule[] rules = ruleBase.getPackages()[0].getRules();
+ assertEquals( 4,
+ rules.length );
+
+ assertEquals( "match Person 1",
+ rules[0].getName() );
+ assertEquals( "match Person 2",
+ rules[1].getName() );
+ assertEquals( "match Person 3",
+ rules[2].getName() );
+ assertEquals( "match Integer",
+ rules[3].getName() );
+
+ WorkingMemory workingMemory = ruleBase.newWorkingMemory();
+
+ workingMemory.setGlobal( "list", new ArrayList() );
+
+ workingMemory.assertObject( new Integer(5) );
+
+ final byte[] wm = serializeOut( workingMemory );
+
+ workingMemory = ruleBase.newWorkingMemory( new ByteArrayInputStream( wm ) );
+
+ assertEquals( 1, workingMemory.getObjects().size() );
+ assertEquals( new Integer( 5 ) , workingMemory.getObjects().get(0) );
+
+ workingMemory.fireAllRules();
+
+ List list = ( List ) workingMemory.getGlobal( "list" );
+
+ assertEquals( 1, list.size() );
+ assertEquals( new Integer( 4 ), list.get( 0 ) );
+
+ assertEquals( 2, workingMemory.getObjects().size() );
+ assertEquals( new Integer( 5 ) , workingMemory.getObjects().get(0) );
+ assertEquals( "help" , workingMemory.getObjects().get(1) );
}
+
}
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/ColumnConstraints.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/ColumnConstraints.java 2006-06-06 09:59:25 UTC (rev 4638)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/ColumnConstraints.java 2006-06-06 10:46:47 UTC (rev 4639)
@@ -16,6 +16,7 @@
* limitations under the License.
*/
+import java.io.Serializable;
import java.util.List;
import org.drools.WorkingMemory;
@@ -32,7 +33,7 @@
* @author Alexander Bagerman
*
*/
-public class ColumnConstraints {
+public class ColumnConstraints implements Serializable {
private Class classType;
private final FieldConstraint[] alphaConstraints;
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/ConflictResolver.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/ConflictResolver.java 2006-06-06 09:59:25 UTC (rev 4638)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/ConflictResolver.java 2006-06-06 10:46:47 UTC (rev 4639)
@@ -16,6 +16,7 @@
* limitations under the License.
*/
+import java.io.Serializable;
import java.util.Comparator;
/**
@@ -25,7 +26,7 @@
* @author Alexander Bagerman
*
*/
-public interface ConflictResolver {
+public interface ConflictResolver extends Serializable {
public Comparator getFactConflictResolver();
public Comparator getRuleConflictResolver();
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/LeapsRule.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/LeapsRule.java 2006-06-06 09:59:25 UTC (rev 4638)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/LeapsRule.java 2006-06-06 10:46:47 UTC (rev 4639)
@@ -16,6 +16,7 @@
* limitations under the License.
*/
+import java.io.Serializable;
import java.util.ArrayList;
import org.drools.common.AgendaGroupImpl;
@@ -29,7 +30,7 @@
* @author Alexander Bagerman
*
*/
-class LeapsRule {
+class LeapsRule implements Serializable {
Rule rule;
final ColumnConstraints[] columnConstraints;
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/LeapsWorkingMemory.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/LeapsWorkingMemory.java 2006-06-06 09:59:25 UTC (rev 4638)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/LeapsWorkingMemory.java 2006-06-06 10:46:47 UTC (rev 4639)
@@ -17,6 +17,7 @@
*/
import java.beans.PropertyChangeListener;
+import java.io.Serializable;
import java.util.ArrayList;
import java.util.Collection;
import java.util.HashMap;
@@ -808,65 +809,66 @@
/**
* to store facts to cursor over it
*/
- private final Map factTables = new Map( ) {
- private LinkedList tables = new LinkedList( );
+ private final Map factTables = new FactTables();
+
+ class FactTables implements Map, Serializable {
+ private LinkedList tables = new LinkedList( );
- private HashMap map = new HashMap( );
+ private HashMap map = new HashMap( );
- public int size() {
- return this.tables.size( );
- }
+ public int size() {
+ return this.tables.size( );
+ }
- public void clear() {
- this.tables.clear( );
- this.map.clear( );
- }
+ public void clear() {
+ this.tables.clear( );
+ this.map.clear( );
+ }
- public boolean isEmpty() {
- return this.tables.isEmpty( );
- }
+ public boolean isEmpty() {
+ return this.tables.isEmpty( );
+ }
- public boolean containsKey( Object key ) {
- return this.map.containsKey( key );
- }
+ public boolean containsKey( Object key ) {
+ return this.map.containsKey( key );
+ }
- public boolean containsValue( Object value ) {
- return this.map.containsValue( value );
- }
+ public boolean containsValue( Object value ) {
+ return this.map.containsValue( value );
+ }
- public Collection values() {
- return this.tables;
- }
+ public Collection values() {
+ return this.tables;
+ }
- public void putAll( Map t ) {
- this.tables.addAll( t.values( ) );
- this.map.putAll( t );
- }
+ public void putAll( Map t ) {
+ this.tables.addAll( t.values( ) );
+ this.map.putAll( t );
+ }
- public Set entrySet() {
- return this.map.entrySet( );
- }
+ public Set entrySet() {
+ return this.map.entrySet( );
+ }
- public Set keySet() {
- return this.map.keySet( );
- }
+ public Set keySet() {
+ return this.map.keySet( );
+ }
- public Object get( Object key ) {
- return this.map.get( key );
+ public Object get( Object key ) {
+ return this.map.get( key );
- }
+ }
- public Object remove( Object key ) {
- Object ret = this.map.remove( key );
- this.tables.remove( ret );
- return ret;
- }
+ public Object remove( Object key ) {
+ Object ret = this.map.remove( key );
+ this.tables.remove( ret );
+ return ret;
+ }
- public Object put( Object key, Object value ) {
- this.tables.add( value );
- this.map.put( key, value );
- return value;
- }
- };
-
+ public Object put( Object key, Object value ) {
+ this.tables.add( value );
+ this.map.put( key, value );
+ return value;
+ }
+ }
}
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/CompositeConflictResolver.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/CompositeConflictResolver.java 2006-06-06 09:59:25 UTC (rev 4638)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/CompositeConflictResolver.java 2006-06-06 10:46:47 UTC (rev 4639)
@@ -16,6 +16,7 @@
* limitations under the License.
*/
+import java.io.Serializable;
import java.util.Comparator;
/**
@@ -46,34 +47,39 @@
}
public final Comparator getFactConflictResolver() {
- return new Comparator() {
- public int compare(final Object o1,
- final Object o2) {
- int ret = 0;
- if ( o1 != o2 ) {
- for ( int i = 0, length = CompositeConflictResolver.this.factResolvers.length; ret == 0 && i < length; ++i ) {
- ret = CompositeConflictResolver.this.factResolvers[i].compare( o1,
- o2 );
- }
+ return new FactConflictResolver();
+ }
+
+ class FactConflictResolver implements Comparator, Serializable {
+ public int compare(final Object o1,
+ final Object o2) {
+ int ret = 0;
+ if ( o1 != o2 ) {
+ for ( int i = 0, length = CompositeConflictResolver.this.factResolvers.length; ret == 0 && i < length; ++i ) {
+ ret = CompositeConflictResolver.this.factResolvers[i].compare( o1,
+ o2 );
}
- return ret;
}
- };
+ return ret;
+ }
}
public final Comparator getRuleConflictResolver() {
- return new Comparator() {
- public int compare(final Object o1,
- final Object o2) {
- int ret = 0;
- if ( o1 != o2 ) {
- for ( int i = 0, length = CompositeConflictResolver.this.ruleResolvers.length; ret == 0 && i < length; ++i ) {
- ret = CompositeConflictResolver.this.ruleResolvers[i].compare( o1,
- o2 );
- }
+ return new RuleConflictResolver();
+ }
+
+ class RuleConflictResolver implements Comparator, Serializable {
+ public int compare(final Object o1,
+ final Object o2) {
+ int ret = 0;
+ if ( o1 != o2 ) {
+ for ( int i = 0, length = CompositeConflictResolver.this.factResolvers.length; ret == 0 && i < length; ++i ) {
+ ret = CompositeConflictResolver.this.factResolvers[i].compare( o1,
+ o2 );
}
- return ret;
}
- };
+ return ret;
+ }
}
+
}
\ No newline at end of file
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/LoadOrderConflictResolver.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/LoadOrderConflictResolver.java 2006-06-06 09:59:25 UTC (rev 4638)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/LoadOrderConflictResolver.java 2006-06-06 10:46:47 UTC (rev 4639)
@@ -16,6 +16,7 @@
* limitations under the License.
*/
+import java.io.Serializable;
import java.util.Comparator;
import org.drools.common.DefaultFactHandle;
@@ -32,7 +33,8 @@
*/
public class LoadOrderConflictResolver
implements
- Comparator {
+ Comparator,
+ Serializable {
/** Singleton instance. */
private static final LoadOrderConflictResolver INSTANCE = new LoadOrderConflictResolver();
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/RuleComplexityConflictResolver.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/RuleComplexityConflictResolver.java 2006-06-06 09:59:25 UTC (rev 4638)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/RuleComplexityConflictResolver.java 2006-06-06 10:46:47 UTC (rev 4639)
@@ -16,6 +16,7 @@
* limitations under the License.
*/
+import java.io.Serializable;
import java.util.Comparator;
import org.drools.leaps.LeapsRuleHandle;
@@ -31,7 +32,8 @@
*/
class RuleComplexityConflictResolver
implements
- Comparator {
+ Comparator,
+ Serializable {
/** Singleton instance. */
private static final RuleComplexityConflictResolver INSTANCE = new RuleComplexityConflictResolver();
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/RuleSalienceConflictResolver.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/RuleSalienceConflictResolver.java 2006-06-06 09:59:25 UTC (rev 4638)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/conflict/RuleSalienceConflictResolver.java 2006-06-06 10:46:47 UTC (rev 4639)
@@ -16,6 +16,7 @@
* limitations under the License.
*/
+import java.io.Serializable;
import java.util.Comparator;
import org.drools.leaps.LeapsRuleHandle;
@@ -32,7 +33,8 @@
*/
class RuleSalienceConflictResolver
implements
- Comparator {
+ Comparator,
+ Serializable {
/** Singleton instance. */
private static final RuleSalienceConflictResolver INSTANCE = new RuleSalienceConflictResolver();
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/util/TokenStack.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/util/TokenStack.java 2006-06-06 09:59:25 UTC (rev 4638)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/leaps/util/TokenStack.java 2006-06-06 10:46:47 UTC (rev 4639)
@@ -16,6 +16,7 @@
* limitations under the License.
*/
+import java.io.Serializable;
import java.util.EmptyStackException;
import java.util.Iterator;
@@ -30,7 +31,7 @@
*
*/
-public class TokenStack {
+public class TokenStack implements Serializable {
protected TableRecord tailRecord = null;
|
Author: mar...@jb...
Date: 2006-06-06 05:59:25 -0400 (Tue, 06 Jun 2006)
New Revision: 4638
Modified:
labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/IntegrationCases.java
labs/jbossrules/trunk/drools-compiler/src/test/resources/org/drools/integrationtests/test_Serializable.drl
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/RuleBase.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/WorkingMemory.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/AbstractRuleBase.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/AbstractWorkingMemory.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/ReteooRuleBase.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/TerminalNode.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/beta/BetaLeftMemory.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/beta/BetaRightMemory.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/LinkedList.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/LinkedListNode.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/PrimitiveLongMap.java
Log:
JBRULES-285 WorkingMemory is not seriaziable
Modified: labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/IntegrationCases.java
===================================================================
--- labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/IntegrationCases.java 2006-06-06 09:06:17 UTC (rev 4637)
+++ labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/IntegrationCases.java 2006-06-06 09:59:25 UTC (rev 4638)
@@ -45,6 +45,7 @@
import org.drools.State;
import org.drools.TestParam;
import org.drools.WorkingMemory;
+import org.drools.common.ObjectInputStreamWithLoader;
import org.drools.compiler.DrlParser;
import org.drools.compiler.DroolsError;
import org.drools.compiler.DroolsParserException;
@@ -63,6 +64,7 @@
import org.drools.rule.Rule;
import org.drools.spi.ActivationGroup;
import org.drools.spi.AgendaGroup;
+import org.drools.util.PrimitiveLongMap;
/**
* This contains the test cases for each engines implementation to execute.
@@ -1687,6 +1689,12 @@
}
public void testSerializable() throws Exception {
+// PrimitiveLongMap longMap = new PrimitiveLongMap(8, 32);
+//
+// final byte[] map = serializeOut( longMap );
+// longMap = (PrimitiveLongMap) serializeIn( map );
+
+
final Reader reader = new InputStreamReader( getClass().getResourceAsStream( "test_Serializable.drl" ) );
final PackageBuilder builder = new PackageBuilder();
@@ -1703,7 +1711,7 @@
final byte[] ast = serializeOut( ruleBase );
ruleBase = (RuleBase) serializeIn( ast );
final Rule[] rules = ruleBase.getPackages()[0].getRules();
- assertEquals( 3,
+ assertEquals( 4,
rules.length );
assertEquals( "match Person 1",
@@ -1712,6 +1720,35 @@
rules[1].getName() );
assertEquals( "match Person 3",
rules[2].getName() );
+ assertEquals( "match Integer",
+ rules[3].getName() );
+
+ WorkingMemory workingMemory = ruleBase.newWorkingMemory();
+
+ workingMemory.setGlobal( "list", new ArrayList() );
+
+ workingMemory.assertObject( new Integer(5) );
+
+ final byte[] wm = serializeOut( workingMemory );
+
+ workingMemory = ruleBase.newWorkingMemory( new ByteArrayInputStream( wm ) );
+
+ assertEquals( 1, workingMemory.getObjects().size() );
+ assertEquals( new Integer( 5 ) , workingMemory.getObjects().get(0) );
+
+ assertEquals( 1, workingMemory.getAgenda().agendaSize() );
+
+ workingMemory.fireAllRules();
+
+ List list = ( List ) workingMemory.getGlobal( "list" );
+
+ assertEquals( 1, list.size() );
+ assertEquals( new Integer( 4 ), list.get( 0 ) );
+
+ assertEquals( 2, workingMemory.getObjects().size() );
+ assertEquals( new Integer( 5 ) , workingMemory.getObjects().get(0) );
+ assertEquals( "help" , workingMemory.getObjects().get(1) );
+
}
public void testLogicalAssertions() throws Exception {
Modified: labs/jbossrules/trunk/drools-compiler/src/test/resources/org/drools/integrationtests/test_Serializable.drl
===================================================================
--- labs/jbossrules/trunk/drools-compiler/src/test/resources/org/drools/integrationtests/test_Serializable.drl 2006-06-06 09:06:17 UTC (rev 4637)
+++ labs/jbossrules/trunk/drools-compiler/src/test/resources/org/drools/integrationtests/test_Serializable.drl 2006-06-06 09:59:25 UTC (rev 4638)
@@ -35,3 +35,14 @@
exists Person( name == "mark" )
then
end
+
+
+rule "match Integer"
+ agenda-group "yyy"
+ auto-focus true
+ when
+ Integer()
+ then
+ assertLogical ( new String( "help" ) );
+ list.add( new Integer( 4 ) );
+end
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/RuleBase.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/RuleBase.java 2006-06-06 09:06:17 UTC (rev 4637)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/RuleBase.java 2006-06-06 09:59:25 UTC (rev 4638)
@@ -16,6 +16,8 @@
* limitations under the License.
*/
+import java.io.IOException;
+import java.io.InputStream;
import java.io.Serializable;
import java.util.Set;
@@ -46,7 +48,8 @@
/**
* Create a new <code>WorkingMemory</code> session for this
- * <code>RuleBase</code>.
+ * <code>RuleBase</code>. By default the RuleBase retains a
+ * weak reference to returned WorkingMemory.
*
* <p>
* The created <code>WorkingMemory</code> uses the default conflict
@@ -60,8 +63,60 @@
*/
WorkingMemory newWorkingMemory();
+ /**
+ * Create a new <code>WorkingMemory</code> session for this
+ * <code>RuleBase</code>. Optionally the RuleBase retains a
+ * weak reference to returned WorkingMemory.
+ *
+ * <p>
+ * The created <code>WorkingMemory</code> uses the default conflict
+ * resolution strategy.
+ * </p>
+ *
+ * @see WorkingMemory
+ * @see org.drools.conflict.DefaultConflictResolver
+ *
+ * @return A newly initialized <code>WorkingMemory</code>.
+ */
WorkingMemory newWorkingMemory(boolean keepReference);
+ /**
+ * RuleBases handle the returning of a Serialized WorkingMemory
+ * pass as an InputStream. If the reference is a byte[] then
+ * wrap with new ByteArrayInputStream. By default the RuleBase retains a
+ * weak reference to returned WorkingMemory.
+ *
+ * <p>
+ * The created <code>WorkingMemory</code> uses the default conflict
+ * resolution strategy.
+ * </p>
+ *
+ * @see WorkingMemory
+ * @see org.drools.conflict.DefaultConflictResolver
+ *
+ * @return A serialised initialized <code>WorkingMemory</code>.
+ */
+ WorkingMemory newWorkingMemory(InputStream stream) throws IOException, ClassNotFoundException;
+
+ /**
+ * RuleBases handle the returning of a Serialized WorkingMemory
+ * pass as an InputStream. If the reference is a byte[] then
+ * wrap with new ByteArrayInputStream. Optionally the RuleBase retains a
+ * weak reference to returned WorkingMemory.
+ *
+ * <p>
+ * The created <code>WorkingMemory</code> uses the default conflict
+ * resolution strategy.
+ * </p>
+ *
+ * @see WorkingMemory
+ * @see org.drools.conflict.DefaultConflictResolver
+ *
+ * @return A serialised initialized <code>WorkingMemory</code>.
+ */
+ WorkingMemory newWorkingMemory(InputStream stream, boolean keepReference ) throws IOException, ClassNotFoundException;
+
+
Package[] getPackages();
void addPackage(Package pkg) throws Exception;
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/WorkingMemory.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/WorkingMemory.java 2006-06-06 09:06:17 UTC (rev 4637)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/WorkingMemory.java 2006-06-06 09:59:25 UTC (rev 4638)
@@ -29,6 +29,10 @@
/**
* A knowledge session for a <code>RuleBase</code>.
*
+ * While this object can be serialised out, it cannot be serialised in. This is because
+ * the RuleBase reference is transient. Please see the RuleBase interface for serializing
+ * in WorkingMemories from an InputStream.
+ *
* @author <a href="mailto:bo...@en...">bob mcwhirter </a>
*/
public interface WorkingMemory
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/AbstractRuleBase.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/AbstractRuleBase.java 2006-06-06 09:06:17 UTC (rev 4637)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/AbstractRuleBase.java 2006-06-06 09:59:25 UTC (rev 4638)
@@ -20,6 +20,7 @@
import java.io.ByteArrayOutputStream;
import java.io.Externalizable;
import java.io.IOException;
+import java.io.InputStream;
import java.io.ObjectInput;
import java.io.ObjectOutput;
import java.io.ObjectOutputStream;
@@ -386,4 +387,21 @@
public RuleBaseConfiguration getConfiguration() {
return this.config;
}
+
+ public WorkingMemory newWorkingMemory(InputStream stream) throws IOException, ClassNotFoundException {
+ return newWorkingMemory( stream,
+ true );
+ }
+ public WorkingMemory newWorkingMemory(InputStream stream,
+ boolean keepReference ) throws IOException, ClassNotFoundException {
+
+ final ObjectInputStreamWithLoader streamWithLoader = new ObjectInputStreamWithLoader( stream,
+ this.packageClassLoader );
+
+ AbstractWorkingMemory workingMemory = ( AbstractWorkingMemory ) streamWithLoader.readObject();
+ workingMemory.setRuleBase( this );
+
+ return workingMemory;
+
+ }
}
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/AbstractWorkingMemory.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/AbstractWorkingMemory.java 2006-06-06 09:06:17 UTC (rev 4637)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/AbstractWorkingMemory.java 2006-06-06 09:59:25 UTC (rev 4638)
@@ -81,6 +81,7 @@
/** The actual memory for the <code>JoinNode</code>s. */
protected final PrimitiveLongMap nodeMemories = new PrimitiveLongMap( 32,
8 );
+
/** Global values which are associated with this memory. */
protected final Map globals = new HashMap();
@@ -91,17 +92,18 @@
/** The eventSupport */
protected final WorkingMemoryEventSupport workingMemoryEventSupport = new WorkingMemoryEventSupport( this );
+
protected final AgendaEventSupport agendaEventSupport = new AgendaEventSupport( this );
/** The <code>RuleBase</code> with which this memory is associated. */
- protected final InternalRuleBase ruleBase;
+ protected transient InternalRuleBase ruleBase;
protected final FactHandleFactory handleFactory;
protected final TruthMaintenanceSystem tms;
/** Rule-firing agenda. */
- protected DefaultAgenda agenda;
+ protected DefaultAgenda agenda;
protected final List factQueue = new ArrayList();
@@ -150,6 +152,10 @@
// Instance methods
// ------------------------------------------------------------
+ void setRuleBase(InternalRuleBase ruleBase) {
+ this.ruleBase = ruleBase;
+ }
+
public void addEventListener(final WorkingMemoryEventListener listener) {
this.workingMemoryEventSupport.addEventListener( listener );
}
@@ -190,7 +196,7 @@
*/
public void setGlobal(final String name,
final Object value) {
- // Make sure the global has been declared in the RuleBase
+ // Make sure the global has been declared in the RuleBase
final Map globalDefintions = this.ruleBase.getGlobals();
final Class type = (Class) globalDefintions.get( name );
if ( (type == null) ) {
@@ -282,12 +288,12 @@
*
*/
public Object getObject(final FactHandle handle) {
- // you must always take the value from the assertMap, incase the handle
- // is not from this WorkingMemory
+ // you must always take the value from the assertMap, incase the handle
+ // is not from this WorkingMemory
InternalFactHandle factHandle = (InternalFactHandle) this.assertMap.get( handle );
if ( factHandle != null ) {
return factHandle.getObject();
- }
+ }
return null;
@@ -307,9 +313,9 @@
}
/**
- * A helper method used to avoid lookups when iterating over facthandles and
- * objects at once.
- * DO NOT MAKE THIS METHOD PUBLIC UNLESS YOU KNOW WHAT YOU ARE DOING
+ * A helper method used to avoid lookups when iterating over facthandles and
+ * objects at once. DO NOT MAKE THIS METHOD PUBLIC UNLESS YOU KNOW WHAT YOU
+ * ARE DOING
*
* @return
*/
@@ -407,7 +413,7 @@
final Rule rule,
final Activation activation) throws FactException {
if ( object == null ) {
- // you cannot assert a null object
+ // you cannot assert a null object
return null;
}
InternalFactHandle handle = null;
@@ -422,20 +428,23 @@
// lets see if the object is already logical asserted
key = this.tms.get( object );
} else {
- // Object is already asserted, so check and possibly correct its status and then return the handle
+ // Object is already asserted, so check and possibly correct its
+ // status and then return the handle
key = handle.getEqualityKey();
if ( key.getStatus() == EqualityKey.STATED ) {
- // return null as you cannot justify a stated object.
+ // return null as you cannot justify a stated object.
return handle;
}
if ( !logical ) {
- // this object was previously justified, so we have to override it to stated
+ // this object was previously justified, so we have to
+ // override it to stated
key.setStatus( EqualityKey.STATED );
this.tms.removeLogicalDependencies( handle );
} else {
- // this was object is already justified, so just add new logical dependency
+ // this was object is already justified, so just add new
+ // logical dependency
this.tms.addLogicalDependency( handle,
activation,
activation.getPropagationContext(),
@@ -447,7 +456,8 @@
// At this point we know the handle is null
if ( key == null ) {
- // key is also null, so treat as a totally new stated/logical assert
+ // key is also null, so treat as a totally new stated/logical
+ // assert
handle = this.handleFactory.newFactHandle( object );
this.assertMap.put( handle,
handle );
@@ -465,12 +475,14 @@
}
} else if ( !logical ) {
if ( key.getStatus() == EqualityKey.JUSTIFIED ) {
- // Its previous justified, so switch to stated and remove logical dependencies
+ // Its previous justified, so switch to stated and remove
+ // logical dependencies
final InternalFactHandle justifiedHandle = key.getFactHandle();
this.tms.removeLogicalDependencies( justifiedHandle );
if ( this.discardOnLogicalOverride ) {
- // override, setting to new instance, and return existing handle
+ // override, setting to new instance, and return
+ // existing handle
key.setStatus( EqualityKey.STATED );
handle = key.getFactHandle();
handle.setObject( object );
@@ -495,14 +507,16 @@
} else {
if ( key.getStatus() == EqualityKey.JUSTIFIED ) {
- // only add as logical dependency if this wasn't previously stated
+ // only add as logical dependency if this wasn't previously
+ // stated
this.tms.addLogicalDependency( key.getFactHandle(),
activation,
activation.getPropagationContext(),
rule );
return key.getFactHandle();
} else {
- // You cannot justify a previously stated equality equal object, so return null
+ // You cannot justify a previously stated equality equal
+ // object, so return null
return null;
}
}
@@ -516,10 +530,10 @@
rule,
activation );
- // this.ruleBase.assertObject( handle,
- // object,
- // propagationContext,
- // this );
+ // this.ruleBase.assertObject( handle,
+ // object,
+ // propagationContext,
+ // this );
doAssertObject( handle,
object,
@@ -594,29 +608,29 @@
}
}
- // /**
- // * Associate an object with its handle.
- // *
- // * @param handle
- // * The handle.
- // * @param object
- // * The object.
- // */
- // public void putObject(InternalFactHandle handle,
- // Object object) {
- // this.assertMap.put( object,
- // handle );
+ // /**
+ // * Associate an object with its handle.
+ // *
+ // * @param handle
+ // * The handle.
+ // * @param object
+ // * The object.
+ // */
+ // public void putObject(InternalFactHandle handle,
+ // Object object) {
+ // this.assertMap.put( object,
+ // handle );
//
- // handle.setObject( object );
- // }
+ // handle.setObject( object );
+ // }
//
- // public Object removeObject(InternalFactHandle handle) {
- // Object object = handle.getObject();
+ // public Object removeObject(InternalFactHandle handle) {
+ // Object object = handle.getObject();
//
- // this.assertMap.remove( object );
+ // this.assertMap.remove( object );
//
- // return object;
- // }
+ // return object;
+ // }
public void retractObject(final FactHandle handle) throws FactException {
retractObject( handle,
@@ -641,7 +655,7 @@
try {
final InternalFactHandle handle = (InternalFactHandle) factHandle;
if ( handle.getId() == -1 ) {
- // can't retract an already retracted handle
+ // can't retract an already retracted handle
return;
}
removePropertyChangeListener( handle );
@@ -654,10 +668,12 @@
doRetract( handle,
propagationContext );
- // Update the equality key, which maintains a list of stated FactHandles
+ // Update the equality key, which maintains a list of stated
+ // FactHandles
final EqualityKey key = handle.getEqualityKey();
- // Its justified so attempt to remove any logical dependencies for the handle
+ // Its justified so attempt to remove any logical dependencies for
+ // the handle
if ( key.getStatus() == EqualityKey.JUSTIFIED ) {
this.tms.removeLogicalDependencies( handle );
}
@@ -808,9 +824,13 @@
implements
WorkingMemoryAction {
private InternalFactHandle factHandle;
+
private boolean removeLogical;
+
private boolean updateEqualsMap;
+
private Rule ruleOrigin;
+
private Activation activationOrigin;
public WorkingMemoryRetractAction(final InternalFactHandle factHandle,
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/ReteooRuleBase.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/ReteooRuleBase.java 2006-06-06 09:06:17 UTC (rev 4637)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/ReteooRuleBase.java 2006-06-06 09:59:25 UTC (rev 4638)
@@ -19,6 +19,7 @@
import java.io.IOException;
import java.io.ObjectInput;
import java.io.ObjectOutput;
+import java.io.Serializable;
import java.util.HashMap;
import java.util.WeakHashMap;
@@ -217,7 +218,7 @@
super.addWorkingMemory( workingMemory,
keepReference );
- final InitialFactHandle handle = new InitialFactHandle( workingMemory.getFactHandleFactory().newFactHandle( new Object() ) );
+ final InitialFactHandle handle = new InitialFactHandle( workingMemory.getFactHandleFactory().newFactHandle( new Serializable() {} ) );
final PropagationContext propagationContext = new PropagationContextImpl( workingMemory.getNextPropagationIdCounter(),
PropagationContext.ASSERTION,
@@ -242,29 +243,5 @@
protected void removeRule(final Rule rule) {
this.reteooBuilder.removeRule( rule );
}
- // /**
- // * This is to allow the RuleBase to be serializable.
- // */
- // private void readObject(ObjectInputStream is) throws ClassNotFoundException,
- // IOException,
- // Exception {
- // //always perform the default de-serialization first
- // is.defaultReadObject();
- //
- // this.lock = new Object();
- //
- // ObjectTypeResolver resolver = new ClassObjectTypeResolver();
- // this.rete = new Rete( resolver );
- // this.reteooBuilder = new ReteooBuilder( this,
- // resolver );
- // this.globals = new HashMap();
- // this.workingMemories = new WeakHashMap();
- //
- // Package[] packages = this.getPackages();
- // this.pkgs.clear();
- // for ( int i = 0; i < packages.length; i++ ) {
- // this.addPackage( packages[i] );
- // }
- // }
}
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/TerminalNode.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/TerminalNode.java 2006-06-06 09:06:17 UTC (rev 4637)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/TerminalNode.java 2006-06-06 09:59:25 UTC (rev 4638)
@@ -16,6 +16,7 @@
* limitations under the License.
*/
+import java.io.Serializable;
import java.util.Iterator;
import org.drools.Agenda;
@@ -319,7 +320,7 @@
return this.rule.equals( other.rule );
}
- class TerminalNodeMemory {
+ class TerminalNodeMemory implements Serializable {
private AgendaGroupImpl agendaGroup;
private ActivationGroup activationGroup;
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/beta/BetaLeftMemory.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/beta/BetaLeftMemory.java 2006-06-06 09:06:17 UTC (rev 4637)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/beta/BetaLeftMemory.java 2006-06-06 09:59:25 UTC (rev 4638)
@@ -16,6 +16,7 @@
package org.drools.reteoo.beta;
+import java.io.Serializable;
import java.util.Iterator;
import javax.naming.OperationNotSupportedException;
@@ -43,7 +44,7 @@
*
* Created: 12/02/2006
*/
-public interface BetaLeftMemory {
+public interface BetaLeftMemory extends Serializable {
/**
* Adds the given tuple to the memory
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/beta/BetaRightMemory.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/beta/BetaRightMemory.java 2006-06-06 09:06:17 UTC (rev 4637)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/reteoo/beta/BetaRightMemory.java 2006-06-06 09:59:25 UTC (rev 4638)
@@ -16,6 +16,7 @@
package org.drools.reteoo.beta;
+import java.io.Serializable;
import java.util.Iterator;
import javax.naming.OperationNotSupportedException;
@@ -43,7 +44,7 @@
*
* Created: 12/02/2006
*/
-public interface BetaRightMemory {
+public interface BetaRightMemory extends Serializable {
/**
* Adds an object to the right memory
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/LinkedList.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/LinkedList.java 2006-06-06 09:06:17 UTC (rev 4637)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/LinkedList.java 2006-06-06 09:59:25 UTC (rev 4638)
@@ -1,5 +1,6 @@
package org.drools.util;
+import java.io.Serializable;
import java.util.Iterator;
import java.util.NoSuchElementException;
@@ -42,7 +43,7 @@
* @author <a href="mailto:bo...@we...">Bob McWhirter</a>
*
*/
-public class LinkedList {
+public class LinkedList implements Serializable {
private LinkedListNode firstNode;
private LinkedListNode lastNode;
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/LinkedListNode.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/LinkedListNode.java 2006-06-06 09:06:17 UTC (rev 4637)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/LinkedListNode.java 2006-06-06 09:59:25 UTC (rev 4638)
@@ -16,6 +16,8 @@
* limitations under the License.
*/
+import java.io.Serializable;
+
/**
* Items placed in a <code>LinkedList<code> must implement this interface .
*
@@ -24,7 +26,7 @@
* @author <a href="mailto:mar...@jb...">Mark Proctor</a>
* @author <a href="mailto:bo...@we...">Bob McWhirter</a>
*/
-public interface LinkedListNode {
+public interface LinkedListNode extends Serializable {
/**
* Returns the next node
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/PrimitiveLongMap.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/PrimitiveLongMap.java 2006-06-06 09:06:17 UTC (rev 4637)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/PrimitiveLongMap.java 2006-06-06 09:59:25 UTC (rev 4638)
@@ -32,7 +32,7 @@
*/
private static final long serialVersionUID = 199618748057741463L;
- private final static Object NULL = new Object() {
+ private final static Object NULL = new Serializable() {
/**
*
|
|
From: <jbo...@li...> - 2006-06-06 09:06:24
|
Author: mar...@jb...
Date: 2006-06-06 05:06:17 -0400 (Tue, 06 Jun 2006)
New Revision: 4637
Modified:
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/InitialFact.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/PrimitiveLongMap.java
Log:
-Made initialFact serialisable
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/InitialFact.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/InitialFact.java 2006-06-06 08:52:54 UTC (rev 4636)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/InitialFact.java 2006-06-06 09:06:17 UTC (rev 4637)
@@ -1,5 +1,7 @@
package org.drools;
+import java.io.Serializable;
+
/*
* Copyright 2005 JBoss Inc
*
@@ -16,6 +18,6 @@
* limitations under the License.
*/
-public interface InitialFact {
+public interface InitialFact extends Serializable {
}
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/PrimitiveLongMap.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/PrimitiveLongMap.java 2006-06-06 08:52:54 UTC (rev 4636)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/PrimitiveLongMap.java 2006-06-06 09:06:17 UTC (rev 4637)
@@ -32,7 +32,7 @@
*/
private static final long serialVersionUID = 199618748057741463L;
- private final static Object NULL = new Serializable() {
+ private final static Object NULL = new Object() {
/**
*
|
|
From: <jbo...@li...> - 2006-06-06 08:53:04
|
Author: mar...@jb...
Date: 2006-06-06 04:52:54 -0400 (Tue, 06 Jun 2006)
New Revision: 4636
Modified:
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/EqualityKey.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/TruthMaintenanceSystem.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/rule/Package.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/spi/AgendaGroup.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/spi/PropagationContext.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/BinaryHeapFifoQueue.java
labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/concurrent/locks/ReentrantLock.java
Log:
-updated classes to be serialisable
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/EqualityKey.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/EqualityKey.java 2006-06-06 07:09:12 UTC (rev 4635)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/EqualityKey.java 2006-06-06 08:52:54 UTC (rev 4636)
@@ -15,6 +15,7 @@
* limitations under the License.
*/
+import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
@@ -27,7 +28,7 @@
* @author <a href="mailto:mar...@jb...">Mark Proctor</a>
*
*/
-public class EqualityKey {
+public class EqualityKey implements Serializable {
public final static int STATED = 1;
public final static int JUSTIFIED = 2;
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/TruthMaintenanceSystem.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/TruthMaintenanceSystem.java 2006-06-06 07:09:12 UTC (rev 4635)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/common/TruthMaintenanceSystem.java 2006-06-06 08:52:54 UTC (rev 4636)
@@ -15,6 +15,7 @@
* limitations under the License.
*/
+import java.io.Serializable;
import java.util.HashSet;
import java.util.Iterator;
import java.util.Map;
@@ -37,7 +38,7 @@
* @author <a href="mailto:mar...@jb...">Mark Proctor</a>
*
*/
-public class TruthMaintenanceSystem {
+public class TruthMaintenanceSystem implements Serializable {
private final AbstractWorkingMemory WorkingMemory;
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/rule/Package.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/rule/Package.java 2006-06-06 07:09:12 UTC (rev 4635)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/rule/Package.java 2006-06-06 08:52:54 UTC (rev 4636)
@@ -169,8 +169,6 @@
this.packageCompilationData.getClassLoader() );
this.rules = (Map) streamWithLoader.readObject();
-
- System.out.println( "done package" );
}
private static class ObjectInputStreamWithLoader extends ObjectInputStream {
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/spi/AgendaGroup.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/spi/AgendaGroup.java 2006-06-06 07:09:12 UTC (rev 4635)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/spi/AgendaGroup.java 2006-06-06 08:52:54 UTC (rev 4636)
@@ -1,5 +1,7 @@
package org.drools.spi;
+import java.io.Serializable;
+
import org.drools.common.DefaultAgenda;
/*
@@ -28,7 +30,7 @@
* @author <a href="mailto:bo...@we...">Bob McWhirter</a>
*
*/
-public interface AgendaGroup {
+public interface AgendaGroup extends Serializable {
/**
* Static reference to determine the default <code>AgendaGroup</code> name.
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/spi/PropagationContext.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/spi/PropagationContext.java 2006-06-06 07:09:12 UTC (rev 4635)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/spi/PropagationContext.java 2006-06-06 08:52:54 UTC (rev 4636)
@@ -16,9 +16,11 @@
* limitations under the License.
*/
+import java.io.Serializable;
+
import org.drools.rule.Rule;
-public interface PropagationContext {
+public interface PropagationContext extends Serializable {
public static final int ASSERTION = 0;
public static final int RETRACTION = 1;
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/BinaryHeapFifoQueue.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/BinaryHeapFifoQueue.java 2006-06-06 07:09:12 UTC (rev 4635)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/BinaryHeapFifoQueue.java 2006-06-06 08:52:54 UTC (rev 4636)
@@ -16,12 +16,14 @@
* limitations under the License.
*/
+import java.io.Serializable;
import java.util.Comparator;
import java.util.NoSuchElementException;
public class BinaryHeapFifoQueue
implements
- Queue {
+ Queue,
+ Serializable {
/** The default capacity for a binary heap. */
private final static int DEFAULT_CAPACITY = 13;
Modified: labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/concurrent/locks/ReentrantLock.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/concurrent/locks/ReentrantLock.java 2006-06-06 07:09:12 UTC (rev 4635)
+++ labs/jbossrules/trunk/drools-core/src/main/java/org/drools/util/concurrent/locks/ReentrantLock.java 2006-06-06 08:52:54 UTC (rev 4636)
@@ -6,6 +6,7 @@
package org.drools.util.concurrent.locks;
+import java.io.Serializable;
import java.util.Collection;
/**
@@ -24,7 +25,7 @@
private final NonfairSync sync;
- final static class NonfairSync {
+ final static class NonfairSync implements Serializable {
private static final long serialVersionUID = 7316153563782823691L;
protected transient Thread owner_ = null;
|
|
From: <jbo...@li...> - 2006-06-06 07:09:19
|
Author: jfr...@jb...
Date: 2006-06-06 03:09:12 -0400 (Tue, 06 Jun 2006)
New Revision: 4635
Modified:
labs/jbossweb/trunk/src/share/native/build/buildphp.sh
Log:
Make the copy conditional.
Modified: labs/jbossweb/trunk/src/share/native/build/buildphp.sh
===================================================================
--- labs/jbossweb/trunk/src/share/native/build/buildphp.sh 2006-06-06 06:01:22 UTC (rev 4634)
+++ labs/jbossweb/trunk/src/share/native/build/buildphp.sh 2006-06-06 07:09:12 UTC (rev 4635)
@@ -733,11 +733,31 @@
#
# At that point everything is build.
# Copy the libraries to php/lib
-cp -p $TOOLS/POSTGRESQL/lib/libpq.so* $TOOLS/PHP/lib
-cp -p $TOOLS/SSL/lib/libcrypto.so* $TOOLS/PHP/lib
-cp -p $TOOLS/SSL/lib/libssl.so* $TOOLS/PHP/lib
-cp -p $TOOLS/LPNG/lib/libpng12.so* $TOOLS/PHP/lib
-cp -p $TOOLS/LIBXML2/lib/libxml2.so* $TOOLS/PHP/lib
+if ${BUILDKRB5}
+then
+ cp -p $TOOLS/KRB5/lib/lib*.so* $TOOLS/PHP/lib
+fi
+if ${BUILDGTTX}
+then
+ cp -p $TOOLS/GTTX/lib/lib*.so* $TOOLS/PHP/lib
+fi
+if ${BUILDPSQL}
+then
+ cp -p $TOOLS/POSTGRESQL/lib/libpq.so* $TOOLS/PHP/lib
+fi
+if ${BUILDOSSL}
+then
+ cp -p $TOOLS/SSL/lib/libcrypto.so* $TOOLS/PHP/lib
+ cp -p $TOOLS/SSL/lib/libssl.so* $TOOLS/PHP/lib
+fi
+if ${BUILDLPNG}
+then
+ cp -p $TOOLS/LPNG/lib/libpng12.so* $TOOLS/PHP/lib
+fi
+if ${BUILDXML2}
+then
+ cp -p $TOOLS/LIBXML2/lib/libxml2.so* $TOOLS/PHP/lib
+fi
#
# Build the war file with the demo
|
|
From: <jbo...@li...> - 2006-06-06 06:01:27
|
Author: mic...@jb...
Date: 2006-06-06 02:01:22 -0400 (Tue, 06 Jun 2006)
New Revision: 4634
Modified:
labs/jbossrules/trunk/documentation/training/developers-course/lab-4-rule-formats/src/rules/approval/approval.drl
labs/jbossrules/trunk/documentation/training/developers-course/lab-4-rule-formats/src/rules/approval/archive/raw.drl
Log:
got rid of bad newlines
Modified: labs/jbossrules/trunk/documentation/training/developers-course/lab-4-rule-formats/src/rules/approval/approval.drl
===================================================================
--- labs/jbossrules/trunk/documentation/training/developers-course/lab-4-rule-formats/src/rules/approval/approval.drl 2006-06-06 05:03:43 UTC (rev 4633)
+++ labs/jbossrules/trunk/documentation/training/developers-course/lab-4-rule-formats/src/rules/approval/approval.drl 2006-06-06 06:01:22 UTC (rev 4634)
@@ -11,7 +11,7 @@
rule "Driver has had too many accidents"
when
- Driver has had more than 3 prior claims
+ Driver has had more than 3 prior claims
then
Reject Policy with explanation : 'Too many accidents'
@@ -27,32 +27,34 @@
end
rule "Driver is in marginal age"
- #remember, don't leave any blank lines in between expressions
+ #remember, don't leave any blank lines in between expressions
when
- Driver is between 18 and 24 years old
+ Driver is between 18 and 24 years old
Driver has had more than 1 prior claims
- Policy type is 'COMPREHENSIVE'
- then
- Reject Policy with explanation : 'No accidents allowed if in marginal age group'
+ Policy type is 'COMPREHENSIVE'
+ then
+ Reject Policy with explanation : 'No accidents allowed if in marginal age group'
end
-rule "Driver in unsafe area for marginal age"
- when
- Policy type is 'COMPREHENSIVE'
+rule "Driver in unsafe area for marginal age"
+ when
+ Policy type is 'COMPREHENSIVE'
Driver is less than 25 years old
- Driver has a location risk profile of 'HIGH'
- then
- Reject Policy with explanation : 'Marginal age driver in high risk area'
+ Driver has a location risk profile of 'HIGH'
+
+ then
+ Reject Policy with explanation : 'Marginal age driver in high risk area'
end
-rule "Driver in unsafe area with priors"
- when
+rule "Driver in unsafe area with priors"
+ when
Driver has a location risk profile of 'MED'
Policy type is 'COMPREHENSIVE'
Driver is less than 25 years old
- Driver has had more than 1 prior claims
- then
- Reject Policy with explanation : 'Driver in that area is too risky - given past accidents and age.'
+ Driver has had more than 1 prior claims
+
+ then
+ Reject Policy with explanation : 'Driver in that area is too risky - given past accidents and age.'
end
rule "Driver unsafe for third party"
Modified: labs/jbossrules/trunk/documentation/training/developers-course/lab-4-rule-formats/src/rules/approval/archive/raw.drl
===================================================================
--- labs/jbossrules/trunk/documentation/training/developers-course/lab-4-rule-formats/src/rules/approval/archive/raw.drl 2006-06-06 05:03:43 UTC (rev 4633)
+++ labs/jbossrules/trunk/documentation/training/developers-course/lab-4-rule-formats/src/rules/approval/archive/raw.drl 2006-06-06 06:01:22 UTC (rev 4634)
@@ -1,7 +1,8 @@
#created on: 23/05/2006
package org.acme.insurance
-
+import org.acme.insurance.Approve
+
rule "Driver underage"
when
@@ -40,7 +41,7 @@
d : Driver(locationRiskProfile == "MED")
d : Driver(priorClaims > 1)
d : Driver(age < 25)
- Policy(type == "COMPREHENSIVE")
+ Policy(type == "COMPREHENSIVE")
then
assert(new Rejection("Driver in that area is too risky - given past accidents and age."));
end
@@ -52,7 +53,10 @@
then
assert(new Rejection("Too many priors for third party"));
end
-
+
+
+
+
rule "Driver in bad area for theft"
when
@@ -60,37 +64,38 @@
d : Driver(locationRiskProfile == "HIGH")
then
assert(new Rejection("Unsafe area for theft"));
-end
+end
-rule "Quick approval - safe driver, any policy type"
- when
+rule "Quick approval - safe driver, any policy type"
+ when
not Rejection()
d: Driver(age >= 30)
d: Driver(priorClaims == 0)
- then
- assert(new Approve("Driver is safe, and mature"));
+ then
+ assert(new Approve("Driver is safe, and mature"));
end
-rule "Approve policy affirmative"
- salience 100 #this can short circuit any processing
- when
+rule "Approve policy affirmative"
+ salience 100 #this can short circuit any processing
+ when
a : Approve()
- p : Policy()
- then
+ p : Policy()
+
+ then
p.setApproved(true);
System.out.println("APPROVED: "
+ a.getReason());
- drools.clearAgenda(); #stop processing (bit of a hack ;)
+ drools.clearAgenda(); #stop processing (bit of a hack ;)
end
-rule "Approve if not rejected"
+rule "Approve if not rejected"
salience -100 #approve if there are no objections
- when
+ when
not Rejection()
- p : Policy(approved == false)
+ p : Policy(approved == false)
then
- System.out.println("APPROVED: due to no objections.");
- p.setApproved(true);
+ System.out.println("APPROVED: due to no objections.");
+ p.setApproved(true);
end
rule "Reject application"
|
|
From: <jbo...@li...> - 2006-06-06 05:05:32
|
Author: mic...@jb... Date: 2006-06-06 01:03:43 -0400 (Tue, 06 Jun 2006) New Revision: 4633 Modified: labs/jbossrules/updates/drools-ide-update/plugins/org.drools.ide_3.0.1.jar Log: uses marks core jars Modified: labs/jbossrules/updates/drools-ide-update/plugins/org.drools.ide_3.0.1.jar =================================================================== (Binary files differ) |
|
From: <jbo...@li...> - 2006-06-06 04:33:18
|
Author: mic...@jb... Date: 2006-06-06 00:27:47 -0400 (Tue, 06 Jun 2006) New Revision: 4632 Modified: labs/jbossrules/updates/drools-ide-update/plugins/org.drools.ide_3.0.1.jar Log: fixed the dependencies Modified: labs/jbossrules/updates/drools-ide-update/plugins/org.drools.ide_3.0.1.jar =================================================================== (Binary files differ) |
|
From: <jbo...@li...> - 2006-06-06 04:09:55
|
Author: mic...@jb... Date: 2006-06-06 00:09:43 -0400 (Tue, 06 Jun 2006) New Revision: 4631 Modified: labs/jbossrules/trunk/documentation/training/developers-course/Module 2 - JBoss Rules Intro.odp Log: small changes Modified: labs/jbossrules/trunk/documentation/training/developers-course/Module 2 - JBoss Rules Intro.odp =================================================================== (Binary files differ) |
|
From: <jbo...@li...> - 2006-06-06 04:07:21
|
Author: mic...@jb...
Date: 2006-06-06 00:07:14 -0400 (Tue, 06 Jun 2006)
New Revision: 4630
Modified:
labs/jbossrules/trunk/build.xml
Log:
changed to use non version specific jar names
Modified: labs/jbossrules/trunk/build.xml
===================================================================
--- labs/jbossrules/trunk/build.xml 2006-06-06 04:06:28 UTC (rev 4629)
+++ labs/jbossrules/trunk/build.xml 2006-06-06 04:07:14 UTC (rev 4630)
@@ -136,13 +136,26 @@
<copy todir="drools-ide/lib"
flatten="true">
- <fileset dir="repository" includes="**/*.jar" excludes="**/jsr94-sigtest-1.1.jar **/jsr94-tck-1.0.3.jar" />
+ <fileset dir="repository" includes="**/*.jar" excludes="**/jsr94-sigtest-1.1.jar **/jsr94-tck-1.0.3.jar **/drools-*.jar" />
</copy>
-
+
+ <!-- copy the drools module jars for the plug in. We will remove the version number from them -->
+ <copy tofile="drools-ide/lib/drools-core.jar" flatten="true" file="target/drools-core-${version}.jar" />
+ <copy tofile="drools-ide/lib/drools-compiler.jar" flatten="true" file="target/drools-compiler-${version}.jar" />
+ <copy tofile="drools-ide/lib/drools-decisiontables.jar" flatten="true" file="target/drools-decisiontables-${version}.jar" />
+ <copy tofile="drools-ide/lib/drools-jsr94.jar" flatten="true" file="target/drools-jsr94-${version}.jar" />
+
+
+
+ <!-- Don't want to do it like this anymore....
+ But would be nice is the above copying could be automated like this.
<copy todir="drools-ide/lib"
flatten="true">
<fileset dir="." includes="drools-*/target/drools-*.jar" />
- </copy>
+ </copy>
+
+ -->
+
</target>
<!--
|
|
From: <jbo...@li...> - 2006-06-06 04:06:36
|
Author: mic...@jb... Date: 2006-06-06 00:06:28 -0400 (Tue, 06 Jun 2006) New Revision: 4629 Modified: labs/jbossrules/trunk/drools-ide/.classpath labs/jbossrules/trunk/drools-ide/META-INF/MANIFEST.MF Log: changed to use non version specific jar names Modified: labs/jbossrules/trunk/drools-ide/.classpath =================================================================== --- labs/jbossrules/trunk/drools-ide/.classpath 2006-06-06 00:22:56 UTC (rev 4628) +++ labs/jbossrules/trunk/drools-ide/.classpath 2006-06-06 04:06:28 UTC (rev 4629) @@ -9,7 +9,7 @@ <classpathentry kind="lib" path="lib/junit-3.8.1.jar"/> <classpathentry kind="lib" path="lib/antlr-3.0ea8.jar"/> <classpathentry kind="lib" path="lib/commons-jci-core-1.0-406301.jar"/> - <classpathentry kind="lib" path="lib/drools-compiler-3.0.jar"/> - <classpathentry kind="lib" path="lib/drools-core-3.0.jar"/> + <classpathentry kind="lib" path="lib/drools-compiler.jar"/> + <classpathentry kind="lib" path="lib/drools-core.jar"/> <classpathentry kind="output" path="bin"/> </classpath> Modified: labs/jbossrules/trunk/drools-ide/META-INF/MANIFEST.MF =================================================================== --- labs/jbossrules/trunk/drools-ide/META-INF/MANIFEST.MF 2006-06-06 00:22:56 UTC (rev 4628) +++ labs/jbossrules/trunk/drools-ide/META-INF/MANIFEST.MF 2006-06-06 04:06:28 UTC (rev 4629) @@ -52,7 +52,7 @@ lib/commons-jci-eclipse-3.2.0.666.jar, lib/commons-jci-janino-2.4.3.jar, lib/janino-2.4.3.jar, - lib/drools-compiler-3.0.jar, - lib/drools-core-3.0.jar, - lib/drools-decisiontables-3.0.jar, - lib/drools-jsr94-3.0.jar + lib/drools-compiler.jar, + lib/drools-core.jar, + lib/drools-decisiontables.jar, + lib/drools-jsr94.jar |
|
From: <jbo...@li...> - 2006-06-06 03:07:48
|
Author: adamw Date: 2006-06-05 14:17:12 -0400 (Mon, 05 Jun 2006) New Revision: 4618 Added: labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/ProjectIssueTrackerLink.java labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/ProjectRepositoryLink.java Modified: labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/ForgeHelper.java labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/EntryFactory.java labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/ProjectsMenuEntry.java labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/projects/ProjectDescriptor.java Log: http://jira.jboss.com/jira/browse/JBLAB-685 http://jira.jboss.com/jira/browse/JBLAB-690 Modified: labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/ForgeHelper.java =================================================================== --- labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/ForgeHelper.java 2006-06-05 18:12:42 UTC (rev 4617) +++ labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/ForgeHelper.java 2006-06-05 18:17:12 UTC (rev 4618) @@ -445,6 +445,9 @@ link = removeParameter(link, Constants.PROJECT_LIST_PARAM+"="+Constants.FALSE_VALUE); link = removeParameter(link, Constants.PROJECT_LIST_PARAM+"="+Constants.TRUE_VALUE); + while (link.contains("//")) { + link = link.replace("//", "/"); + } return link; } Modified: labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/EntryFactory.java =================================================================== --- labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/EntryFactory.java 2006-06-05 18:12:42 UTC (rev 4617) +++ labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/EntryFactory.java 2006-06-05 18:17:12 UTC (rev 4618) @@ -37,6 +37,8 @@ private final static String PAGE = "page"; private final static String LINK = "link"; private final static String FREEZONE = "freezone"; + private final static String REPOSITORY = "repository"; + private final static String ISSUE_TRACKER = "issue-tracker"; // This class cannot be instatiated. private EntryFactory() { @@ -97,6 +99,22 @@ } } + if (REPOSITORY.equals(type)) { + if (project != null) { + return new ProjectRepositoryLink(portalName, project, node); + } else { + return null; + } + } + + if (ISSUE_TRACKER.equals(type)) { + if (project != null) { + return new ProjectIssueTrackerLink(portalName, project, node); + } else { + return null; + } + } + return null; } } Added: labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/ProjectIssueTrackerLink.java =================================================================== --- labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/ProjectIssueTrackerLink.java 2006-06-05 18:12:42 UTC (rev 4617) +++ labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/ProjectIssueTrackerLink.java 2006-06-05 18:17:12 UTC (rev 4618) @@ -0,0 +1,19 @@ +package org.jboss.forge.common.navigation; + +import org.jboss.forge.common.projects.ProjectDescriptor; +import org.jboss.forge.common.projects.IssueTracker; +import org.w3c.dom.Node; + +/** + * @author Adam Warski (ad...@as...) + */ +public class ProjectIssueTrackerLink extends LinkEntry { + public ProjectIssueTrackerLink(String portalName, ProjectDescriptor project, Node root) { + super(portalName, project, root); + } + + protected String generateLink(String content) { + IssueTracker it = getProject().getProjectIssueTracker(); + return it == null ? "" : it.getLocation(); + } +} Added: labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/ProjectRepositoryLink.java =================================================================== --- labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/ProjectRepositoryLink.java 2006-06-05 18:12:42 UTC (rev 4617) +++ labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/ProjectRepositoryLink.java 2006-06-05 18:17:12 UTC (rev 4618) @@ -0,0 +1,19 @@ +package org.jboss.forge.common.navigation; + +import org.jboss.forge.common.projects.ProjectDescriptor; +import org.jboss.forge.common.projects.Repository; +import org.w3c.dom.Node; + +/** + * @author Adam Warski (ad...@as...) + */ +public class ProjectRepositoryLink extends LinkEntry { + public ProjectRepositoryLink(String portalName, ProjectDescriptor project, Node root) { + super(portalName, project, root); + } + + protected String generateLink(String content) { + Repository rep = getProject().getProjectRepository(); + return rep == null ? "" : rep.getLocation(); + } +} Modified: labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/ProjectsMenuEntry.java =================================================================== --- labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/ProjectsMenuEntry.java 2006-06-05 18:12:42 UTC (rev 4617) +++ labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/navigation/ProjectsMenuEntry.java 2006-06-05 18:17:12 UTC (rev 4618) @@ -83,8 +83,10 @@ PermissionsChecker pc = new RenderRequestPermissionsChecker(request); if (projectInLevel) { + Menu menu = projects.getProjectMenu(pc, projectId); - return link.equals(projects.getProjectLink(projectId)) || + String projectLink = projects.getProjectLink(projectId); + return link.equals(projectLink) || (link + "/").equals(projectLink) || menu.containsLink(link, projectId, levelId, request); } else { return link.equals(ForgeHelper.prepareLinkForChecking( Modified: labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/projects/ProjectDescriptor.java =================================================================== --- labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/projects/ProjectDescriptor.java 2006-06-05 18:12:42 UTC (rev 4617) +++ labs/jbosslabs/trunk/portal-extensions/forge-common/src/java/org/jboss/forge/common/projects/ProjectDescriptor.java 2006-06-05 18:17:12 UTC (rev 4618) @@ -127,18 +127,20 @@ downloads = null; } - // There should be a menu. - if (menuNode != null) { - menu = new Menu(portalName, menuNode, this); - } - + if (repositoryNode != null) { repository = new Repository(repositoryNode); } - + if (issueTrackerNode != null) { issueTracker = new IssueTracker(issueTrackerNode); } + + // There should be a menu. + if (menuNode != null) { + menu = new Menu(portalName, menuNode, this); + } + } /** |
|
From: <jbo...@li...> - 2006-06-06 03:05:40
|
Author: szimano Date: 2006-06-05 14:47:18 -0400 (Mon, 05 Jun 2006) New Revision: 4619 Modified: labs/jbosslabs/branches/Labs-Portal-2.0-ComTheme/forge/portal-extensions/forge-theme/jbossForgeLayout.war/layouts/jbossForge.jsp Log: redhat theme Modified: labs/jbosslabs/branches/Labs-Portal-2.0-ComTheme/forge/portal-extensions/forge-theme/jbossForgeLayout.war/layouts/jbossForge.jsp =================================================================== --- labs/jbosslabs/branches/Labs-Portal-2.0-ComTheme/forge/portal-extensions/forge-theme/jbossForgeLayout.war/layouts/jbossForge.jsp 2006-06-05 18:17:12 UTC (rev 4618) +++ labs/jbosslabs/branches/Labs-Portal-2.0-ComTheme/forge/portal-extensions/forge-theme/jbossForgeLayout.war/layouts/jbossForge.jsp 2006-06-05 18:47:18 UTC (rev 4619) @@ -49,16 +49,19 @@ <div id="TopLogo"> <img src="http://jboss.com/themes/jbosstheme/img/logo.gif" alt="JBoss - The Professional Open Source Company" /> </div> + <div id="TopMenu"> <table cellpadding="0" cellspacing="0"> - <tbody><tr> - <td class="menu_JBnetwork"><a href="http://network.jboss.com/">Support</a></td> - <td class="menu_JBjems"><a href="http://www.jboss.com/products/index">Products</a></td> - <td class="menu_JBcom"><a href="http://www.jboss.com/partners/index">Partners</a></td> - <td class="menu_JBfed"><a href="http://labs.jboss.com">JBoss Labs</a></td> + <tr> + <td class="menu_JBnetwork"><a href="http://network.jboss.com/">subscription</a></td> + <td class="menu_JBcom"><a href="http://www.jboss.com/">jboss.com</a></td> + + <td class="menu_JBorg"><a href="http://labs.jboss.com">jboss.org</a></td> + <td class="menu_RH"><a href="http://www.redhat.com">redhat.com</a></td> </tr> - </tbody></table> + </table> </div> + <div id="ControlMenu"> <form id="TopSearch" action="http://www.google.com/search" onsubmit="document.forms[0].q.value = document.forms[0].q.value + ' site:jboss.org';"> <ul> |
|
From: Mike L. <mi...@pr...> - 2006-06-06 03:02:15
|
<!-- This plain text message area is for recipients who have email programs that= do not support html emails (almost every modern email client software progra= m can accept html emails). If you want to add an alternate plain text messag= e for those who cannot receive html emails, enter it here. //--> <HTML> <HEAD> <META NAME=3D"GENERATOR" Content=3D"Microsoft DHTML Editing Control"> <TITLE></TITLE> </HEAD> <BODY> <P><B><FONT face=3DArial size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: Arial">Hello,</SP= AN></FONT></B><O:P></O:P></P> <P><B><FONT face=3DArial size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: Arial">I would li= ke to=20 introduce you to Precision Marketing, LLC. If you have been looking for a=20 Quality Lead Source we would like to talk with you. We Offer Exclusive and=20 Semi-Exclusive Telemarketing and Internet Generated Mortgage Leads at Whole= sale=20 Prices. &n= bsp; </SPAN></FONT></B><O:P></O:P></P> <P style=3D"tab-stops: 10.25in"><B><FONT face=3DArial size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: Arial"><U1:P>We=20 Specialize In Selling To Mortgage Professionals Nationwide and Also Other=20 Marketing and Lead Companies.</SPAN></FONT></B><O:P></O:P></P> <P><B><FONT face=3DArial size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: Arial">Please vis= it our=20 web site <A title=3Dhttp://www.PrecisionMktg.net=20 href=3D"http://www.PrecisionMktg.net">www.PrecisionMktg.net</A> and give us= a call=20 if you can see the value in receiving Good Quality Leads at Great=20 Prices.<U1:P><O:P></O:P></SPAN></FONT></B></P> <P><B><I style=3D"mso-bidi-font-style: normal"><U><FONT face=3DArial color= =3Dgreen=20 size=3D5><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 16pt; COLOR: green; FONT-STYLE: ital= ic; FONT-FAMILY: Arial; mso-bidi-font-style: normal">JUNE 2006=20 SPECIALS<O:P></O:P></SPAN></FONT></U></I></B></P> <P><B><FONT face=3DArial size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: Arial">Semi Exclu= sive=20 Internet Leads 100 x $15.00 or 50 x $20.00<O:P></O:P></SPAN></FONT></B></P> <P><B><FONT face=3DArial size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: Arial">Semi Exclu= sive=20 Telemarketing Leads 100 x $20.00 or 50 x $25.00<O:P></O:P></SPAN></FONT></B= ></P> <P><B><FONT face=3DArial size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: Arial">Exclusive=20 Telemarketing Leads 100 x $30.00 or 50 x $35.00</SPAN></FONT></B></P> <P><B><FONT face=3DArial size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: Arial"><SPAN=20 style=3D"mso-spacerun: yes">  = ; &nb= sp; &= nbsp;  = ; &nb= sp; &= nbsp;  = ; &nb= sp; &= nbsp;  = ; &nb= sp; &= nbsp;  = ; &nb= sp; &= nbsp;  = ; </SPAN><SPAN=20 style=3D"mso-spacerun: yes">  = ; &nb= sp; &= nbsp;  = ; </SPAN></SPAN></FONT></B></P> <P><B><FONT face=3DArial size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: Arial"><SPAN=20 style=3D"mso-spacerun: yes"></SPAN></SPAN></FONT></B><B><FONT face=3DArial=20 size=3D3><SPAN style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: Ar= ial">Call=20 for the Details Now!<U1:P></SPAN></FONT></B></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ><U1:P></U1:P></SPAN></FONT></I></B></EM></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ><U1:P>Thank=20 you,</SPAN></FONT></I></B></EM><U1:P><O:P></O:P></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><U1:P><ST1:PERSONNAME w:s= t=3D"on"><EM><B><I><FONT face=3D"Californian FB"=20 size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= >Mike=20 Leath</SPAN></FONT></I></B></EM></ST1:PERSONNAME><U1:P><O:P></O:P></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= >Precision=20 Marketing, LLC</SPAN></FONT></I></B></EM><U1:P><O:P></O:P></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= >561-366-9686=20 - Office</SPAN></FONT></I></B></EM><U1:P><O:P></O:P></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= >561-366=3D9484-=20 Fax</SPAN></FONT></I></B></EM></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ></SPAN></FONT></I></B></EM> </P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ></SPAN></FONT></I></B></EM> </P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ></SPAN></FONT></I></B></EM> </P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ></SPAN></FONT></I></B></EM> </P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ></SPAN></FONT></I></B></EM> </P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ></SPAN></FONT></I></B></EM> </P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ></SPAN></FONT></I></B></EM> </P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ></SPAN></FONT></I></B></EM> </P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ></SPAN></FONT></I></B></EM> </P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ></SPAN></FONT></I></B></EM> </P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ></SPAN></FONT></I></B></EM> </P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ></SPAN></FONT></I></B></EM> </P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><EM><B><I><FONT=20 face=3D"Californian FB" size=3D3><SPAN=20 style=3D"FONT-WEIGHT: bold; FONT-SIZE: 12pt; FONT-FAMILY: 'Californian FB'"= ><U1:P><O:P></O:P></SPAN></FONT></I></B></EM></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT face=3DArial color= =3Dblue=20 size=3D3><SPAN=20 style=3D"FONT-SIZE: 12pt; COLOR: blue; FONT-FAMILY: Arial"><O:P></O:P></SPA= N></FONT></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT face=3DArial color= =3Dblue=20 size=3D3><SPAN=20 style=3D"FONT-SIZE: 12pt; COLOR: blue; FONT-FAMILY: Arial"><O:P></O:P></SPA= N></FONT></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT face=3DArial color= =3Dblue=20 size=3D3><SPAN=20 style=3D"FONT-SIZE: 12pt; COLOR: blue; FONT-FAMILY: Arial"><O:P></O:P></SPA= N></FONT></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT face=3DArial color= =3Dblue=20 size=3D3><SPAN=20 style=3D"FONT-SIZE: 12pt; COLOR: blue; FONT-FAMILY: Arial"><O:P></O:P></SPA= N></FONT></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT face=3DArial color= =3Dblue=20 size=3D3><SPAN=20 style=3D"FONT-SIZE: 12pt; COLOR: blue; FONT-FAMILY: Arial"><O:P></O:P></SPA= N></FONT></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT face=3DArial color= =3Dblue=20 size=3D3><SPAN=20 style=3D"FONT-SIZE: 12pt; COLOR: blue; FONT-FAMILY: Arial"><O:P></O:P></SPA= N></FONT></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT face=3DArial color= =3Dblue=20 size=3D3><SPAN=20 style=3D"FONT-SIZE: 12pt; COLOR: blue; FONT-FAMILY: Arial"><O:P></O:P></SPA= N></FONT></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT face=3DArial color= =3Dblue=20 size=3D3><SPAN=20 style=3D"FONT-SIZE: 12pt; COLOR: blue; FONT-FAMILY: Arial"><O:P></O:P></SPA= N></FONT></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT face=3DArial color= =3Dblue=20 size=3D3><SPAN=20 style=3D"FONT-SIZE: 12pt; COLOR: blue; FONT-FAMILY: Arial"><O:P></O:P></SPA= N></FONT></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT face=3DArial color= =3Dblue=20 size=3D3><SPAN=20 style=3D"FONT-SIZE: 12pt; COLOR: blue; FONT-FAMILY: Arial"><O:P></O:P></SPA= N></FONT></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT face=3DArial color= =3Dblue=20 size=3D3><SPAN=20 style=3D"FONT-SIZE: 12pt; COLOR: blue; FONT-FAMILY: Arial"><O:P></O:P></SPA= N></FONT></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT face=3DArial color= =3Dblue=20 size=3D3><SPAN=20 style=3D"FONT-SIZE: 12pt; COLOR: blue; FONT-FAMILY: Arial"><O:P></O:P></SPA= N></FONT></P> <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT face=3DArial color= =3Dblue=20 size=3D3><SPAN=20 style=3D"FONT-SIZE: 12pt; COLOR: blue; FONT-FAMILY: Arial"><O:P></O:P></SPA= N></FONT></P> <P><U1:P><FONT face=3D"Times New Roman" size=3D3><SPAN=20 style=3D"FONT-SIZE: 12pt"><U1:P><U1:P><U1:P><U1:P><U1:P><U1:P>If you prefer= not to get promotional information from=20 Precision Marketing, LLC please let us know my sending a brief message=20 in the "subject line" back to=20 us.<O:P></O:P></SPAN></FONT></P> </U1:P> </U1:P> </U1:P> </U1:P> </U1:P> </U1:P> </U1:P> </U1:P> </U1:P> </U1:P> </U1:P> </U1:P> </U1:P> </U1:P> </BODY> </HTML> |
Author: mic...@jb...
Date: 2006-06-04 22:29:02 -0400 (Sun, 04 Jun 2006)
New Revision: 4602
Added:
labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/TestParam.java
labs/jbossrules/trunk/drools-compiler/src/test/resources/org/drools/integrationtests/field_bindings.drl
Modified:
labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/IntegrationCases.java
Log:
test for eval node sharing
Added: labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/TestParam.java
===================================================================
--- labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/TestParam.java 2006-06-05 00:57:35 UTC (rev 4601)
+++ labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/TestParam.java 2006-06-05 02:29:02 UTC (rev 4602)
@@ -0,0 +1,21 @@
+package org.drools;
+
+public class TestParam {
+
+ private String value1;
+ private String value2;
+ public String getValue1() {
+ return value1;
+ }
+ public void setValue1(String value1) {
+ this.value1 = value1;
+ }
+ public String getValue2() {
+ return value2;
+ }
+ public void setValue2(String value2) {
+ this.value2 = value2;
+ }
+
+
+}
Property changes on: labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/TestParam.java
___________________________________________________________________
Name: svn:eol-style
+ native
Modified: labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/IntegrationCases.java
===================================================================
--- labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/IntegrationCases.java 2006-06-05 00:57:35 UTC (rev 4601)
+++ labs/jbossrules/trunk/drools-compiler/src/test/java/org/drools/integrationtests/IntegrationCases.java 2006-06-05 02:29:02 UTC (rev 4602)
@@ -43,9 +43,11 @@
import org.drools.RuleBase;
import org.drools.Sensor;
import org.drools.State;
+import org.drools.TestParam;
import org.drools.WorkingMemory;
import org.drools.compiler.DrlParser;
import org.drools.compiler.DroolsError;
+import org.drools.compiler.DroolsParserException;
import org.drools.compiler.PackageBuilder;
import org.drools.compiler.ParserError;
import org.drools.compiler.RuleError;
@@ -94,7 +96,33 @@
assertEquals( new Integer( 5 ),
list.get( 0 ) );
}
+
+ public void FIXME_testFieldBiningsAndEvalSharing() throws Exception {
+
+ String drl = "field_bindings.drl";
+ final PackageBuilder builder = new PackageBuilder();
+ builder.addPackageFromDrl( new InputStreamReader( getClass().getResourceAsStream( drl ) ) );
+ final Package pkg = builder.getPackage();
+
+ final RuleBase ruleBase = getRuleBase();
+ ruleBase.addPackage( pkg );
+ WorkingMemory wm = ruleBase.newWorkingMemory();
+
+ List list = new ArrayList();
+ wm.setGlobal( "list", list );
+
+ TestParam tp1 = new TestParam();
+ tp1.setValue2( "boo" );
+ wm.assertObject( tp1 );
+
+
+ wm.fireAllRules();
+
+ assertEquals(1, list.size());
+ }
+
+
public void testEmptyColumn() throws Exception {
//pre build the package
final PackageBuilder builder = new PackageBuilder();
Added: labs/jbossrules/trunk/drools-compiler/src/test/resources/org/drools/integrationtests/field_bindings.drl
===================================================================
--- labs/jbossrules/trunk/drools-compiler/src/test/resources/org/drools/integrationtests/field_bindings.drl 2006-06-05 00:57:35 UTC (rev 4601)
+++ labs/jbossrules/trunk/drools-compiler/src/test/resources/org/drools/integrationtests/field_bindings.drl 2006-06-05 02:29:02 UTC (rev 4602)
@@ -0,0 +1,21 @@
+package org.drools;
+
+global java.util.List list;
+
+#this is to test eval condition node sharing working properly
+rule rule1
+ when
+ TestParam(val: value1)
+ eval(val == null)
+ then
+ list.add("rule1 fired");
+end
+
+
+rule rule2
+ when
+ TestParam(val: value2)
+ eval(val == null) #note its the same guts, but different binding
+ then
+ list.add("rule2 fired");
+end
\ No newline at end of file
Property changes on: labs/jbossrules/trunk/drools-compiler/src/test/resources/org/drools/integrationtests/field_bindings.drl
___________________________________________________________________
Name: svn:eol-style
+ native
|
|
From: <jbo...@li...> - 2006-06-06 02:46:24
|
Author: jfr...@jb...
Date: 2006-06-04 15:00:33 -0400 (Sun, 04 Jun 2006)
New Revision: 4600
Modified:
labs/jbossweb/trunk/src/share/native/build/buildphp.sh
Log:
Arrange gd configure parameters.
Modified: labs/jbossweb/trunk/src/share/native/build/buildphp.sh
===================================================================
--- labs/jbossweb/trunk/src/share/native/build/buildphp.sh 2006-06-04 13:05:09 UTC (rev 4599)
+++ labs/jbossweb/trunk/src/share/native/build/buildphp.sh 2006-06-04 19:00:33 UTC (rev 4600)
@@ -127,6 +127,9 @@
ADDCON=$3
ADDINS=$4
SUBDIR=$5
+echo "************************* Configure in ${BASDIR} ********************"
+echo "prefix: ${INSDIR}"
+echo "parameters: ${ADDCON}"
if [ -z "${SUBDIR}" ]
then
SRCDIR=${BASDIR}
@@ -198,6 +201,8 @@
BUILDICNV=true
BUILDFTT2=true
BUILDPSQL=true
+ BUILDJPEG=true
+ BUILDMSQL=true
;;
*)
echo "$i: not (yet) supported"
@@ -379,10 +384,9 @@
Extract freetype ${FTT2URL} ${FTT2VER}
Build freetype-${FTT2VER} ${TOOLS}/FTT2 "--enable-shared" "" ""
ADDCONF="$ADDCONF --with-freetype-dir=$TOOLS/FTT2"
- LGDCONF="$LGDCONF --with-freetype-dir=$TOOLS/FTT2"
+ LGDCONF="$LGDCONF --with-freetype=$TOOLS/FTT2"
else
ADDCONF="$ADDCONF --with-freetype-dir"
- LGDCONF="$LGDCONF --with-freetype-dir"
fi
#
@@ -392,6 +396,7 @@
Extract libiconv ${ICNVURL} ${ICNVVER}
Build libiconv-${ICNVVER} ${TOOLS}/ICNV "--enable-shared" "" ""
ADDCONF="$ADDCONF --with-iconv-dir=$TOOLS/ICNV"
+ LGDCONF="$LGDCONF --with-libiconv-prefix=$TOOLS/ICNV"
fi
#
@@ -437,10 +442,9 @@
Extract jpeg ${JPEGURL} ${JPEGVER}
Build jpeg-${JPEGVER} ${TOOLS}/JPEG "--enable-shared" "" ""
ADDCONF="$ADDCONF --with-jpeg-dir=$TOOLS/JPEG"
- LGDCONF="$LGDCONF --with-jpeg-dir=$TOOLS/JPEG"
+ LGDCONF="$LGDCONF --with-jpeg=$TOOLS/JPEG"
else
ADDCONF="$ADDCONF --with-jpeg-dir"
- LGDCONF="$LGDCONF --with-jpeg-dir"
fi
#
@@ -450,10 +454,16 @@
Extract libpng ${LPNGURL} ${LPNGVER}
Build libpng-${LPNGVER} ${TOOLS}/LPNG "" ""
ADDCONF="$ADDCONF --with-png-dir=$TOOLS/LPNG"
- LGDCONF="$LGDCONF --with-png-dir=$TOOLS/LPNG"
+ LGDCONF="$LGDCONF --with-png=$TOOLS/LPNG"
+ # libgd makes _very_ strange things with png.
+ LIBPNG_CONFIG=${TOOLS}/LPNG/bin/libpng-config
+ LIBPNG12_CONFIG=${TOOLS}/LPNG/bin/libpng12-config
+ CPPFLAGS="$CPPFLAGS -I${TOOLS}/LPNG/include/libpng12"
+ export LIBPNG_CONFIG
+ export LIBPNG12_CONFIG
+ export CPPFLAGS
else
ADDCONF="$ADDCONF --with-png-dir"
- LGDCONF="$LGDCONF --with-png-dir"
fi
#
@@ -461,7 +471,7 @@
if ${BUILDLBGD}
then
Extract gd ${LBGDURL} ${LBGDVER}
- Build gd-${LBGDVER} ${TOOLS}/LBGD "$LGDCONF" ""
+ Build gd-${LBGDVER} ${TOOLS}/LBGD "--without-xpm $LGDCONF" ""
ADDCONF="$ADDCONF --with-gd=$TOOLS/LBGD \
--enable-gd-native-ttf \
--without-xpm \
|
|
From: <jbo...@li...> - 2006-06-06 02:46:05
|
Author: jfr...@jb...
Date: 2006-06-05 05:44:39 -0400 (Mon, 05 Jun 2006)
New Revision: 4607
Modified:
labs/jbossweb/trunk/src/share/native/build/buildphp.sh
Log:
Make sure php uses our ldap with we build it.
Modified: labs/jbossweb/trunk/src/share/native/build/buildphp.sh
===================================================================
--- labs/jbossweb/trunk/src/share/native/build/buildphp.sh 2006-06-05 07:32:53 UTC (rev 4606)
+++ labs/jbossweb/trunk/src/share/native/build/buildphp.sh 2006-06-05 09:44:39 UTC (rev 4607)
@@ -582,6 +582,13 @@
LIBS=-liconv
export LIBS
fi
+if ${BUILDLDAP}
+then
+ EXTRA_LDFLAGS=-L$TOOLS/LDAP/lib
+ EXTRA_LDFLAGS_PROGRAM=-L$TOOLS/LDAP/lib
+ export EXTRA_LDFLAGS
+ export EXTRA_LDFLAGS_PROGRAM
+fi
# configure php
if [ ${CC} = "cc" ]
|
|
From: <jbo...@li...> - 2006-06-06 02:45:59
|
Author: mar...@jb...
Date: 2006-06-05 05:58:05 -0400 (Mon, 05 Jun 2006)
New Revision: 4608
Modified:
labs/jbossrules/trunk/documentation/manual/en/Chapter-Rule_Engine/Section-What_is_a_Rule_Engine.xml
Log:
-fixed spelling mistake
Modified: labs/jbossrules/trunk/documentation/manual/en/Chapter-Rule_Engine/Section-What_is_a_Rule_Engine.xml
===================================================================
--- labs/jbossrules/trunk/documentation/manual/en/Chapter-Rule_Engine/Section-What_is_a_Rule_Engine.xml 2006-06-05 09:44:39 UTC (rev 4607)
+++ labs/jbossrules/trunk/documentation/manual/en/Chapter-Rule_Engine/Section-What_is_a_Rule_Engine.xml 2006-06-05 09:58:05 UTC (rev 4608)
@@ -190,7 +190,7 @@
<para>Backward chaining is 'goal-driven', we start with a conclusion which
the engine tries to satisfy. If it can't it searches for conclusions, 'sub
- goals', that help satisfy an unknown part fo the current goal - it
+ goals', that help satisfy an unknown part for the current goal - it
continues this process untill either the initial conclusion is proven or
there are no more sub goals. Prolog is an example of a Backward Chaining
engine; Drools will adding support for Backward Chaining in its next major
|