Error while creating datasource using WLST - java.lang.ClassCastException
When we are creating the datasource through WLST script in weblogic server may may receive the following exception in create method.Creating DataSource: EAISOAMetadataSource ....
Problem invoking WLST - Traceback (innermost last):
File "/reuters/oracle/as01/wlst/GridLinkDatasourceCreation.py", line 115, in ?
File "/reuters/oracle/as01/wlst/GridLinkDatasourceCreation.py", line 108, in main
File "/reuters/oracle/as01/wlst/GridLinkDatasourceCreation.py", line 39, in createGridLinkJDBCResources
File "<iostream>", line 528, in create
at weblogic.management.scripting.EditHandler.create(EditHandler.java:531)
at weblogic.management.scripting.WLScriptContext.create(WLScriptContext.java:332)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
java.lang.ClassCastException: java.lang.ClassCastException: java.lang.reflect.InvocationTargetException cannot be cast to weblogic.management.scripting.ScriptException
I colud not able to find the exact root cause but able to resolve the issue "Undo All Changes" from weblogic console and re-exectiong the script.
Steps to resolve the issue
Login to weblogic admin consoleVerify whether any changes are pending to be activated.
Perform Activate Changes or Undo All Changes
Re-execute the script, this time script will create the datasource successfully.
No comments:
Post a Comment