ExpressionFactoryImpl with properties

Hi,

I am reading the doc below, i am embedding the process engine into a third party framework, which does not allow accessing outside, suche as JAVA_HOME/lib/el.properties.

So i am thinking manually calling the ExpressionFactory.newInstance() during start up and pass the properties, but i dont know what need to be passed (just the defaults)

Thanks
Shannon


Expression factory implementation. This class is also used as an EL “service provider”. The JUEL jar file specifies this class as el expression factory implementation in META-INF/services/javax.el.ExpressionFactory. Calling ExpressionFactory.newInstance() will then return an instance of this class, configured as described below. If no properties are specified at construction time, properties are read from
If the file JAVA_HOME/lib/el.properties exists and if it contains property javax.el.ExpressionFactory whose value is the name of this class, these properties are taken as default properties.
Otherwise, if system property javax.el.ExpressionFactory is set to the name of this class, the system properties System.getProperties() are taken as default properties.
el.properties on your classpath. These properties override the properties from JAVA_HOME/lib/el.properties or System.getProperties().
There are also constructors to explicitly pass in an instance of Properties. Having this, the following properties are read:
javax.el.cacheSize - cache size (int, default is 1000)
javax.el.methodInvocations - allow method invocations as in ${foo.bar(baz)} (boolean, default is false).
javax.el.nullProperties - resolve null properties as in ${foo[null]} (boolean, default is false).
javax.el.varArgs - support function/method calls using varargs (boolean, default is false).

Hi,

I did this, but i dont know how to make process engine to use this,

Properties props = new Properties();
	props.put("javax.el.cacheSize", "1000");
	props.put("javax.el.methodInvocations", false);
	props.put("javax.el.nullProperties", false);
	props.put("javax.el.varArgs", false);
	ExpressionFactory.newInstance(props);

------------------------------------- this is the error

Caused by: java.security.AccessControlException: access denied (“java.io.FilePermission” “C:\Program Files\Java\jdk1.8.0_91\jre\lib\el.properties” “read”)
at java.security.AccessControlContext.checkPermission(AccessControlContext.java:472)
at java.security.AccessController.checkPermission(AccessController.java:884)
at java.lang.SecurityManager.checkPermission(SecurityManager.java:549)
at java.lang.SecurityManager.checkRead(SecurityManager.java:888)
at java.io.File.exists(File.java:814)
at org.camunda.bpm.engine.impl.juel.ExpressionFactoryImpl.loadDefaultProperties(ExpressionFactoryImpl.java:248)
at org.camunda.bpm.engine.impl.juel.ExpressionFactoryImpl.loadProperties(ExpressionFactoryImpl.java:273)
at org.camunda.bpm.engine.impl.juel.ExpressionFactoryImpl.(ExpressionFactoryImpl.java:152)
at org.camunda.bpm.engine.impl.juel.ExpressionFactoryImpl.(ExpressionFactoryImpl.java:137)
at org.camunda.bpm.engine.impl.el.ExpressionManager.(ExpressionManager.java:68)
at org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl.initExpressionManager(ProcessEngineConfigurationImpl.java:1996)