Details
-
Bug
-
Resolution: Solved By
-
Critical
-
12.10.10, 13.4.5, 13.10
-
Windows 11 Pro 64 bit, Chrome 96, using a local instance XWiki 13.10 on MariaDB 10.6, Tomcat 9.0.56 and Jetty+HSQLDB instance, Java 17.0.1 build 17.0.1+12-LTS-39 from Oracle
-
Unknown
-
Description
STEPS TO REPRODUCE
- Start XWiki on Java 17
- Click on Search magnifier in top right corner, enter some text in the input field (e.g. "wiki") and press Enter
- Observe the XWiki console
- Click on Date filtering facets ('Last modification date', ' Creation date', Upload date')
EXPECTED RESULTS
Under every Date filtering facet are displayed selectable sub-filters ('Today', ' Last 7 days', 'Last 30 days', 'Custom date & time interval').
ACTUAL RESULTS
An error is displayed instead:
Failed to execute the [velocity] macro. Cause: [class org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl cannot access class sun.util.calendar.ZoneInfo (in module java.base) because module java.base does not export sun.util.calendar to unnamed module @51b1a8f6]. Click on this message for details.
In console, there is the following stacktrace (partial):
2021-12-13 15:17:46,137 [http-nio-1115-exec-9 - http://localhost:1115/xwiki/bin/view/Main/Search?text=wiki&f_type=DOCUMENT&f_locale=en&f_locale=&r=1] ERROR o.a.v.rendering - ASTMethod.execute() : exception invoking method 'getOffset' in class sun.util.calendar.ZoneInfo java.lang.IllegalAccessException: class org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl cannot access class sun.util.calendar.ZoneInfo (in module java.base) because module java.base does not export sun.util.calendar to unnamed module @5dbbb292 at java.base/jdk.internal.reflect.Reflection.newIllegalAccessException(Reflection.java:392) at java.base/java.lang.reflect.AccessibleObject.checkAccess(AccessibleObject.java:674) at java.base/java.lang.reflect.Method.invoke(Method.java:560) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:571) ... at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.base/java.lang.Thread.run(Thread.java:833) 2021-12-13 15:17:46,154 [http-nio-1115-exec-9 - http://localhost:1115/xwiki/bin/view/Main/Search?text=wiki&f_type=DOCUMENT&f_locale=en&f_locale=&r=1] ERROR o.a.v.d.null - Exception in macro #displaySearchFacetValue_customDateInterval called at xwiki:Main.Search[line 116, column 1] 2021-12-13 15:17:46,158 [http-nio-1115-exec-9 - http://localhost:1115/xwiki/bin/view/Main/Search?text=wiki&f_type=DOCUMENT&f_locale=en&f_locale=&r=1] ERROR o.a.v.d.null - Exception in macro #displaySearchFacetValues_date called at xwiki:Main.Search[line 4, column 23] 2021-12-13 15:17:46,174 [http-nio-1115-exec-9 - http://localhost:1115/xwiki/bin/view/Main/Search?text=wiki&f_type=DOCUMENT&f_locale=en&f_locale=&r=1] ERROR o.a.v.rendering - ASTMethod.execute() : exception invoking method 'getOffset' in class sun.util.calendar.ZoneInfo java.lang.IllegalAccessException: class org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl cannot access class sun.util.calendar.ZoneInfo (in module java.base) because module java.base does not export sun.util.calendar to unnamed module @5dbbb292 at java.base/jdk.internal.reflect.Reflection.newIllegalAccessException(Reflection.java:392) at java.base/java.lang.reflect.AccessibleObject.checkAccess(AccessibleObject.java:674) at java.base/java.lang.reflect.Method.invoke(Method.java:560) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:571) ... at java.base/java.lang.Thread.run(Thread.java:833) 2021-12-13 15:17:46,190 [http-nio-1115-exec-9 - http://localhost:1115/xwiki/bin/view/Main/Search?text=wiki&f_type=DOCUMENT&f_locale=en&f_locale=&r=1] ERROR o.a.v.d.null - Exception in macro #displaySearchFacetValue_customDateInterval called at xwiki:Main.Search[line 116, column 1] 2021-12-13 15:17:46,196 [http-nio-1115-exec-9 - http://localhost:1115/xwiki/bin/view/Main/Search?text=wiki&f_type=DOCUMENT&f_locale=en&f_locale=&r=1] ERROR o.a.v.d.null - Exception in macro #displaySearchFacetValues_date called at xwiki:Main.Search[line 4, column 23] 2021-12-13 15:17:46,247 [http-nio-1115-exec-9 - http://localhost:1115/xwiki/bin/view/Main/Search?text=wiki&f_type=DOCUMENT&f_locale=en&f_locale=&r=1] ERROR o.a.v.rendering - ASTMethod.execute() : exception invoking method 'getOffset' in class sun.util.calendar.ZoneInfo java.lang.IllegalAccessException: class org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl cannot access class sun.util.calendar.ZoneInfo (in module java.base) because module java.base does not export sun.util.calendar to unnamed module @5dbbb292 at java.base/jdk.internal.reflect.Reflection.newIllegalAccessException(Reflection.java:392) at java.base/java.lang.reflect.AccessibleObject.checkAccess(AccessibleObject.java:674) at java.base/java.lang.reflect.Method.invoke(Method.java:560) ... at java.base/java.lang.Thread.run(Thread.java:833) 2021-12-13 15:17:46,266 [http-nio-1115-exec-9 - http://localhost:1115/xwiki/bin/view/Main/Search?text=wiki&f_type=DOCUMENT&f_locale=en&f_locale=&r=1] ERROR o.a.v.d.null - Exception in macro #displaySearchFacetValue_customDateInterval called at xwiki:Main.Search[line 116, column 1] 2021-12-13 15:17:46,271 [http-nio-1115-exec-9 - http://localhost:1115/xwiki/bin/view/Main/Search?text=wiki&f_type=DOCUMENT&f_locale=en&f_locale=&r=1] ERROR o.a.v.d.null - Exception in macro #displaySearchFacetValues_date called at xwiki:Main.Search[line 4, column 23]
The full stacktrace from console is available here: https://up1.xwikisas.com/#ovzf3rRZcs26Q-tgjIYCBw
The issue does not reproduce on Java 11.
Attachments
Issue Links
- duplicates
-
XCOMMONS-2678 Velocity is calling the wrong Method override sometime
- Closed