Skip to content

Commit 308c2a8

Browse files
authored
Release 1.1.0 (#23)
3PP Version Bumps
1 parent 2e1aca2 commit 308c2a8

File tree

11 files changed

+52
-37
lines changed

11 files changed

+52
-37
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,10 @@ in maintenance mode. Current plan is to support community with minor enhancement
2424

2525
## Latest news
2626

27+
* 01/15/2024: Version 1.1.0 is out
28+
* 3PP Version bumps
29+
* easy-rules-jexl - Breaking change due to bump to Jexl 3.3
30+
2731
* 02/13/2023: Version 1.0.7 is out
2832
Minor release to fix jackson vulnerability
2933

easy-rules-archetype/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<parent>
33
<groupId>io.github.dvgaba</groupId>
44
<artifactId>easy-rules</artifactId>
5-
<version>1.0.7</version>
5+
<version>1.1.0</version>
66
</parent>
77
<modelVersion>4.0.0</modelVersion>
88

easy-rules-core/pom.xml

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<parent>
55
<groupId>io.github.dvgaba</groupId>
66
<artifactId>easy-rules</artifactId>
7-
<version>1.0.7</version>
7+
<version>1.1.0</version>
88
</parent>
99

1010
<artifactId>easy-rules-core</artifactId>
@@ -68,26 +68,23 @@
6868
<scope>test</scope>
6969
</dependency>
7070
<dependency>
71-
<groupId>org.junit.jupiter</groupId>
72-
<artifactId>junit-jupiter-api</artifactId>
73-
<version>5.8.2</version>
71+
<groupId>org.mockito</groupId>
72+
<artifactId>mockito-core</artifactId>
7473
<scope>test</scope>
7574
</dependency>
7675
<dependency>
7776
<groupId>org.junit.jupiter</groupId>
78-
<artifactId>junit-jupiter-engine</artifactId>
79-
<version>5.8.2</version>
77+
<artifactId>junit-jupiter-api</artifactId>
8078
<scope>test</scope>
8179
</dependency>
8280
<dependency>
83-
<groupId>org.mockito</groupId>
84-
<artifactId>mockito-core</artifactId>
81+
<groupId>org.junit.jupiter</groupId>
82+
<artifactId>junit-jupiter-engine</artifactId>
8583
<scope>test</scope>
8684
</dependency>
8785
<dependency>
8886
<groupId>org.mockito</groupId>
8987
<artifactId>mockito-junit-jupiter</artifactId>
90-
<version>4.2.0</version>
9188
<scope>test</scope>
9289
</dependency>
9390
<dependency>

easy-rules-jexl/pom.xml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<parent>
55
<groupId>io.github.dvgaba</groupId>
66
<artifactId>easy-rules</artifactId>
7-
<version>1.0.7</version>
7+
<version>1.1.0</version>
88
</parent>
99

1010
<artifactId>easy-rules-jexl</artifactId>
@@ -13,7 +13,7 @@
1313
<description>JEXL integration module</description>
1414

1515
<properties>
16-
<jexl.version>3.2.1</jexl.version>
16+
<jexl.version>3.3</jexl.version>
1717
</properties>
1818

1919
<scm>
@@ -79,19 +79,16 @@
7979
<dependency>
8080
<groupId>org.junit.jupiter</groupId>
8181
<artifactId>junit-jupiter-api</artifactId>
82-
<version>5.8.2</version>
8382
<scope>test</scope>
8483
</dependency>
8584
<dependency>
8685
<groupId>org.junit.jupiter</groupId>
8786
<artifactId>junit-jupiter-engine</artifactId>
88-
<version>5.8.2</version>
8987
<scope>test</scope>
9088
</dependency>
9189
<dependency>
9290
<groupId>org.junit.jupiter</groupId>
9391
<artifactId>junit-jupiter-params</artifactId>
94-
<version>5.8.2</version>
9592
<scope>test</scope>
9693
</dependency>
9794
</dependencies>

easy-rules-jexl/src/main/java/org/jeasy/rules/jexl/JexlRule.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
import java.util.Objects;
2929
import org.apache.commons.jexl3.JexlBuilder;
3030
import org.apache.commons.jexl3.JexlEngine;
31+
import org.apache.commons.jexl3.introspection.JexlPermissions;
3132
import org.jeasy.rules.api.Action;
3233
import org.jeasy.rules.api.Condition;
3334
import org.jeasy.rules.api.Facts;
@@ -40,7 +41,7 @@
4041
*/
4142
public class JexlRule extends BasicRule {
4243

43-
static final JexlEngine DEFAULT_JEXL = new JexlBuilder().safe(false).create();
44+
static final JexlEngine DEFAULT_JEXL = new JexlBuilder().permissions(JexlPermissions.UNRESTRICTED).safe(false).create();
4445

4546
private Condition condition = Condition.FALSE;
4647
private final List<Action> actions = new ArrayList<>();

easy-rules-jexl/src/test/java/org/jeasy/rules/jexl/JexlActionTest.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
import org.apache.commons.jexl3.JexlBuilder;
3535
import org.apache.commons.jexl3.JexlEngine;
3636
import org.apache.commons.jexl3.JexlException;
37+
import org.apache.commons.jexl3.introspection.JexlPermissions;
3738
import org.apache.commons.jexl3.introspection.JexlSandbox;
3839
import org.assertj.core.api.Assertions;
3940
import org.jeasy.rules.api.Action;
@@ -49,7 +50,7 @@ public class JexlActionTest {
4950
@Test
5051
void testJexlActionExecution() throws Exception {
5152
// given
52-
Action markAsAdult = new JexlAction("person.setAdult(true);");
53+
Action markAsAdult = new JexlAction("person.setAdult(true)");
5354
Facts facts = new Facts();
5455
Person foo = new Person("foo", 20);
5556
facts.put("person", foo);
@@ -94,7 +95,7 @@ void testJexlActionExecutionWithFailure() throws Exception {
9495
Assertions.assertThatThrownBy(() -> action.execute(facts))
9596
.isInstanceOf(JexlException.Method.class)
9697
.hasMessage(
97-
"org.jeasy.rules.jexl.JexlAction.<init>:49 unsolvable function/method 'setBlah(Boolean)'");
98+
"org.jeasy.rules.jexl.JexlAction.<init>:49@1:7 unsolvable function/method 'setBlah(Boolean)'");
9899

99100
// then
100101
// excepted exception
@@ -147,7 +148,7 @@ void testWithWhiteSandbox() {
147148
sandbox.white(System.class.getName()).execute("currentTimeMillis");
148149
Map<String, Object> namespaces = new HashMap<>();
149150
namespaces.put("s", System.class);
150-
JexlEngine jexl = new JexlBuilder().sandbox(sandbox).namespaces(namespaces).create();
151+
JexlEngine jexl = new JexlBuilder().permissions(JexlPermissions.UNRESTRICTED).sandbox(sandbox).namespaces(namespaces).create();
151152
Facts facts = new Facts();
152153
AtomicLong atomicLong = new AtomicLong();
153154
facts.put("result", atomicLong);

easy-rules-mvel/pom.xml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<parent>
55
<groupId>io.github.dvgaba</groupId>
66
<artifactId>easy-rules</artifactId>
7-
<version>1.0.7</version>
7+
<version>1.1.0</version>
88
</parent>
99

1010
<artifactId>easy-rules-mvel</artifactId>
@@ -79,19 +79,16 @@
7979
<dependency>
8080
<groupId>org.junit.jupiter</groupId>
8181
<artifactId>junit-jupiter-api</artifactId>
82-
<version>5.8.2</version>
8382
<scope>test</scope>
8483
</dependency>
8584
<dependency>
8685
<groupId>org.junit.jupiter</groupId>
8786
<artifactId>junit-jupiter-engine</artifactId>
88-
<version>5.8.2</version>
8987
<scope>test</scope>
9088
</dependency>
9189
<dependency>
9290
<groupId>org.junit.jupiter</groupId>
9391
<artifactId>junit-jupiter-params</artifactId>
94-
<version>5.8.2</version>
9592
<scope>test</scope>
9693
</dependency>
9794
<dependency>

easy-rules-spel/pom.xml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<parent>
55
<groupId>io.github.dvgaba</groupId>
66
<artifactId>easy-rules</artifactId>
7-
<version>1.0.7</version>
7+
<version>1.1.0</version>
88
</parent>
99

1010
<artifactId>easy-rules-spel</artifactId>
@@ -85,19 +85,16 @@
8585
<dependency>
8686
<groupId>org.junit.jupiter</groupId>
8787
<artifactId>junit-jupiter-api</artifactId>
88-
<version>5.8.2</version>
8988
<scope>test</scope>
9089
</dependency>
9190
<dependency>
9291
<groupId>org.junit.jupiter</groupId>
9392
<artifactId>junit-jupiter-engine</artifactId>
94-
<version>5.8.2</version>
9593
<scope>test</scope>
9694
</dependency>
9795
<dependency>
9896
<groupId>org.junit.jupiter</groupId>
9997
<artifactId>junit-jupiter-params</artifactId>
100-
<version>5.8.2</version>
10198
<scope>test</scope>
10299
</dependency>
103100
<dependency>

easy-rules-support/pom.xml

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<parent>
55
<groupId>io.github.dvgaba</groupId>
66
<artifactId>easy-rules</artifactId>
7-
<version>1.0.7</version>
7+
<version>1.1.0</version>
88
</parent>
99

1010
<artifactId>easy-rules-support</artifactId>
@@ -80,19 +80,16 @@
8080
<dependency>
8181
<groupId>org.junit.jupiter</groupId>
8282
<artifactId>junit-jupiter-api</artifactId>
83-
<version>5.8.2</version>
8483
<scope>test</scope>
8584
</dependency>
8685
<dependency>
8786
<groupId>org.junit.jupiter</groupId>
8887
<artifactId>junit-jupiter-engine</artifactId>
89-
<version>5.8.2</version>
9088
<scope>test</scope>
9189
</dependency>
9290
<dependency>
9391
<groupId>org.junit.jupiter</groupId>
9492
<artifactId>junit-jupiter-params</artifactId>
95-
<version>5.8.2</version>
9693
<scope>test</scope>
9794
</dependency>
9895
<dependency>
@@ -103,7 +100,6 @@
103100
<dependency>
104101
<groupId>org.mockito</groupId>
105102
<artifactId>mockito-junit-jupiter</artifactId>
106-
<version>4.2.0</version>
107103
<scope>test</scope>
108104
</dependency>
109105
</dependencies>

easy-rules-tutorials/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<parent>
55
<groupId>io.github.dvgaba</groupId>
66
<artifactId>easy-rules</artifactId>
7-
<version>1.0.7</version>
7+
<version>1.1.0</version>
88
</parent>
99

1010
<artifactId>easy-rules-tutorials</artifactId>

0 commit comments

Comments
 (0)