Problem Statement: Post upgrade to Clarity 15.9.3, if Gel Scripts were using APACHE POI classes it started to fail using the below error
org.apache.commons.jelly.JellyTagException: null:31:121: <core:getStatic> Could not access org.apache.poi.hssf.usermodel.HSSFCell.CELL_TYPE_NUMERIC. Original exception message: CELL_TYPE_NUMERIC
at org.apache.commons.jelly.tags.core.GetStaticTag.doTag(GetStaticTag.java:114)
at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:248)
at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:96)
at org.apache.commons.jelly.TagSupport.invokeBody(TagSupport.java:187)
at com.niku.union.gel.tags.ScriptTag.doTag(ScriptTag.java:20)
at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:248)
at com.niku.union.gel.GELScript.run(GELScript.java:58)
at com.niku.union.gel.GELController.invoke(GELController.java:79)
at com.niku.bpm.services.ExecuteCustomAction.run(ExecuteCustomAction.java:207)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:829)
Caused by: java.lang.NoSuchFieldException: CELL_TYPE_NUMERIC
at java.base/java.lang.Class.getField(Class.java:1999)
at org.apache.commons.jelly.tags.core.GetStaticTag.doTag(GetStaticTag.java:108)
... 11 more
Clarity 15.9.3 with Apache POI usage
This is because with Apache POI has been upgrade to Apache POI: OOXML 4.1.2 : Apache License 2.0
Actions Required:
If your organization has deployed any custom processes that contain classes from old Apache POI, those GEL scripts need to be reviewed and updated
With APACHE POI 4.1.2 upgrade will deprecate the getCellTypeEnum() and it looks like the CellType enum has changed in the 4.0 release. See the CellType 4.0 documentation.
The details Third-Party Software Agreements has been documented in our release notes, please review the Clarity 15.9.3 TPSR's and make necessary changes if any of the old libraries are used in custom code.
Not working sample code:
<!--
<core:getStatic var="CELL_TYPE_NUMERIC" className="org.apache.poi.hssf.usermodel.HSSFCell" field="CELL_TYPE_NUMERIC"/>
<core:getStatic var="CELL_TYPE_FORMULA" className="org.apache.poi.hssf.usermodel.HSSFCell" field="CELL_TYPE_FORMULA"/>
<core:getStatic var="CELL_TYPE_BLANK" className="org.apache.poi.hssf.usermodel.HSSFCell" field="CELL_TYPE_BLANK"/>
-->
---
Working sample code:
<core:set var="CELL_TYPE_NUMERIC" value="${0}" />
<core:set var="CELL_TYPE_FORMULA" value="${2}" />
<core:set var="CELL_TYPE_BLANK" value="${3}" />