Skip to content

Commit 3955168

Browse files
author
Henri Biestro
committed
JEXL: getting ready for 3.4;
- release notes; - remove useless code;
1 parent 33ca4a8 commit 3955168

File tree

4 files changed

+158
-14
lines changed

4 files changed

+158
-14
lines changed

src/main/java/org/apache/commons/jexl3/internal/introspection/ArrayIterator.java

-8
Original file line numberDiff line numberDiff line change
@@ -87,12 +87,4 @@ public Object next() {
8787
public boolean hasNext() {
8888
return pos < size;
8989
}
90-
91-
/**
92-
* No op--merely added to satify the <code>Iterator</code> interface.
93-
*/
94-
@Override
95-
public void remove() {
96-
throw new UnsupportedOperationException();
97-
}
9890
}

src/main/java/org/apache/commons/jexl3/internal/introspection/EnumerationIterator.java

-5
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,4 @@ public T next() {
5050
public boolean hasNext() {
5151
return enumeration.hasMoreElements();
5252
}
53-
54-
@Override
55-
public void remove() {
56-
// not implemented
57-
}
5853
}

src/site/site.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
<body>
2626
<menu name="JEXL">
2727
<item name="Overview" href="index.html" />
28-
<item name="Release Notes" href="relnotes33.html"/>
28+
<item name="Release Notes" href="relnotes34.html"/>
2929
<item name="Javadoc 3.4" href="apidocs/index.html"/>
3030
<item name="Javadoc 2.1.1" href="javadocs/apidocs-2.1.1/index.html"/>
3131
<item name="Javadoc 1.1" href="javadocs/apidocs-1.1/index.html"/>

src/site/xdoc/relnotes34.xml

+157
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,157 @@
1+
<?xml version="1.0"?>
2+
<!--
3+
Licensed to the Apache Software Foundation (ASF) under one or more
4+
contributor license agreements. See the NOTICE file distributed with
5+
this work for additional information regarding copyright ownership.
6+
The ASF licenses this file to You under the Apache License, Version 2.0
7+
(the "License"); you may not use this file except in compliance with
8+
the License. You may obtain a copy of the License at
9+
10+
http://www.apache.org/licenses/LICENSE-2.0
11+
12+
Unless required by applicable law or agreed to in writing, software
13+
distributed under the License is distributed on an "AS IS" BASIS,
14+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15+
See the License for the specific language governing permissions and
16+
limitations under the License.
17+
-->
18+
19+
<document>
20+
<properties>
21+
<title>Apache Commons JEXL 3.4 Release Notes</title>
22+
</properties>
23+
24+
<body>
25+
<section name="Compatibility with previous release">
26+
<p>
27+
Version 3.4 is source and binary compatible with 3.3.
28+
</p>
29+
</section>
30+
<section name="Compatibility with older releases (&lt; 3.3, 2.x)">
31+
<p>
32+
Since 3.3 release, the default setting for permissions that determine which packages, classes and methods are
33+
accessible to scripts has been reduced to a very narrow set. When migrating from previous version of JEXL,
34+
this may result in breaking your application behavior ; this breaking change requires remediation in your code.
35+
</p>
36+
<p>
37+
Despite the obvious inconvenience - our sincere apologies on the matter -, how much functional and semantic
38+
power is accessible through scripts has a real impact on your application security and stability ;
39+
that potential risk requires an informed review and conscious choice on your end.
40+
</p>
41+
<p>
42+
To mitigate the change, you can revert to the previous behavior with one line of code
43+
(see <a href="apidocs/org/apache/commons/jexl3/introspection/JexlPermissions.html">JexlPermissions</a>,
44+
<a href="apidocs/org/apache/commons/jexl3/JexlBuilder.html">JexlBuilder</a>
45+
and
46+
<a href="apidocs/org/apache/commons/jexl3/scripting/JexlScriptEngine.html">JexlScriptEngine</a>
47+
) or use this
48+
opportunity to reduce exposure. Whether Files, URLs, networking, processes, class-loaders or reflection classes
49+
or whether loops or side effects are accessible are part of your choice to make.
50+
</p>
51+
</section>
52+
<section name="What's new in 3.4:">
53+
<p>
54+
Features and permissions are easier to define through new methods.
55+
</p>
56+
<p>
57+
Some new syntaxes are introduced ; try/catch/finally (including with resources),
58+
an array-access safe navigation ((x?[y]), strict equality/inequality operators (===, !==),
59+
instanceof/!instanceof operators and more permissive structured literals.
60+
</p>
61+
</section>
62+
63+
<section name="New Features in 3.4:">
64+
<p>
65+
<table>
66+
<tr>
67+
<td><a href="https://issues.apache.org/jira/browse/JEXL-423>">JEXL-423:</a></td>
68+
<td>Add support for instanceof / !instanceof</td>
69+
</tr>
70+
<tr>
71+
<td><a href="https://issues.apache.org/jira/browse/JEXL-422>">JEXL-422:</a></td>
72+
<td>Add strict equality (===) and inequality (!==) operators</td>
73+
</tr>
74+
<tr>
75+
<td><a href="https://issues.apache.org/jira/browse/JEXL-421>">JEXL-421:</a></td>
76+
<td>ArrayBuilder: array type should reflect common class of its entries</td>
77+
</tr>
78+
<tr>
79+
<td><a href="https://issues.apache.org/jira/browse/JEXL-419>">JEXL-419:</a></td>
80+
<td>Add permission syntax to allow class/method/field</td>
81+
</tr>
82+
<tr>
83+
<td><a href="https://issues.apache.org/jira/browse/JEXL-418>">JEXL-418:</a></td>
84+
<td>Add try-catch-finally support</td>
85+
</tr>
86+
<tr>
87+
<td><a href="https://issues.apache.org/jira/browse/JEXL-408>">JEXL-408:</a></td>
88+
<td>Using JexlFeatures is tedious</td>
89+
</tr>
90+
<tr>
91+
<td><a href="https://issues.apache.org/jira/browse/JEXL-404>">JEXL-404:</a></td>
92+
<td>Support array-access safe navigation (x?[y])</td>
93+
</tr>
94+
<tr>
95+
<td><a href="https://issues.apache.org/jira/browse/JEXL-401>">JEXL-401:</a></td>
96+
<td>Captured variables should be read-only</td>
97+
</tr>
98+
<tr>
99+
<td><a href="https://issues.apache.org/jira/browse/JEXL-398>">JEXL-398:</a></td>
100+
<td>Allow 'trailing commas' or ellipsis while defining array, map and set literals</td>
101+
</tr>
102+
</table>
103+
</p>
104+
</section>
105+
106+
<section name="Bugs Fixed in 3.4:">
107+
<p>
108+
<table>
109+
<tr>
110+
<td><a href="https://issues.apache.org/jira/browse/JEXL-420>">JEXL-420:</a></td>
111+
<td>Error while comparing float and string value</td>
112+
</tr>
113+
<tr>
114+
<td><a href="https://issues.apache.org/jira/browse/JEXL-417>">JEXL-417:</a></td>
115+
<td>JexlArithmetic looses precision during arithmetic operator execution</td>
116+
</tr>
117+
<tr>
118+
<td><a href="https://issues.apache.org/jira/browse/JEXL-416>">JEXL-416:</a></td>
119+
<td>Null-valued pragma throws NPE in 3.3</td>
120+
</tr>
121+
<tr>
122+
<td><a href="https://issues.apache.org/jira/browse/JEXL-415>">JEXL-415:</a></td>
123+
<td>Incorrect template eval result</td>
124+
</tr>
125+
<tr>
126+
<td><a href="https://issues.apache.org/jira/browse/JEXL-414>">JEXL-414:</a></td>
127+
<td>SoftCache may suffer from race conditions</td>
128+
</tr>
129+
<tr>
130+
<td><a href="https://issues.apache.org/jira/browse/JEXL-412>">JEXL-412:</a></td>
131+
<td>Ambiguous syntax between namespace function call and map object definition.</td>
132+
</tr>
133+
<tr>
134+
<td><a href="https://issues.apache.org/jira/browse/JEXL-410>">JEXL-410:</a></td>
135+
<td>JexlFeatures: ctor does not enable all features</td>
136+
</tr>
137+
<tr>
138+
<td><a href="https://issues.apache.org/jira/browse/JEXL-409>">JEXL-409:</a></td>
139+
<td>Disable LEXICAL should disable LEXICAL_SHADE</td>
140+
</tr>
141+
<tr>
142+
<td><a href="https://issues.apache.org/jira/browse/JEXL-405>">JEXL-405:</a></td>
143+
<td>Recursive functions corrupt evaluation frame if reassigned</td>
144+
</tr>
145+
<tr>
146+
<td><a href="https://issues.apache.org/jira/browse/JEXL-403>">JEXL-403:</a></td>
147+
<td>Exception while evaluating template literal used in array assignment in loop.</td>
148+
</tr>
149+
<tr>
150+
<td><a href="https://issues.apache.org/jira/browse/JEXL-423>">JEXL-402:</a></td>
151+
<td>parse failed with empty return value.</td>
152+
</tr>
153+
</table>
154+
</p>
155+
</section>
156+
</body>
157+
</document>

0 commit comments

Comments
 (0)