OES11g - updateResource script fails to create the Attribute throwing java.lang.IllegalArgumentException (Doc ID 2126897.1)

Last updated on APRIL 20, 2016

Applies to:

Oracle Entitlements Server - Version 11.1.2.3.0 and later
Information in this document applies to any platform.

Symptoms

OES11g - updateResource script fails to create the Attribute throwing java.lang.IllegalArgumentException

The issue is observed when using the updateResource script to create the Attribute containing colon (:),

while Writing scripts to programmatically manage OES policies using WLS, In order to set values of attributes for a resource.

This the documentation related

F.2.3 updateResource

Although we can modify the attribute value using console but WLST generates exception for values containing colon.

Below is a snippet from a WLST session using Attribute containing colon (:)

wls:/oes_admin/serverConfig> updateResource(appStripe='UserRegistry',resourceName='Test',type='App_Constants_Type',attributes="URN_EHEALTH_UPI:testvalue")
Already in Domain Runtime Tree

updateResource(appStripe='ehealth',resourceName='eRES1',type='eRTY1',attributes="MyMultipAttribute:test,:testvalue3")

COMMAND FAILED due to an unknown reason, Check the stack trace for details
Traceback (innermost last):
File "<console>", line 1, in ?
File "/opt/Oracle/Middleware/OESR2PS3/oracle_common/common/wlst/Opss.py", line 256, in updateResource
File "/opt/Oracle/Middleware/OESR2PS3/oracle_common/common/script_handlers/Opss_handler.py", line 764, in updateResourceImpl
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:526)

java.lang.IllegalArgumentException: java.lang.IllegalArgumentException: Attribute MyMultipAttribute:test,:testvalue3 is not in valid format

updateResource(appStripe='ehealth',resourceName='eRES1',type='eRTY1',attributes="MyMultipAttribute:test:testvalue3");
java.lang.IllegalArgumentException: java.lang.IllegalArgumentException: Attribute MyMultipAttribute:test:testvalue3 is not in valid format

 

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms