Decision Management (ODM,ADS)

Decision Management (ODM, ADS)

Connect with experts and peers to elevate technical expertise, solve problems and share insights

 View Only
Expand all | Collapse all

Cannot access resource from data provider in DC/Decision Runner

  • 1.  Cannot access resource from data provider in DC/Decision Runner

    Posted Thu September 10, 2020 12:02 AM

    Working on a scenario provider for simulations. I can hard code my database connection info into Java, and it works great in Decision Center. My next step is to to move the configuration into Spring beans instead of Java hardcoding, and I was able to successfully run that using a simple java app that uses the same .jar file as I deploy to RES. However, when I deploy the .jar file to RES and run it, I get the following error:

    <Sep 9, 2020 11:20:10,808 AM MDT> <Warning> <Connector> <BEA-190110> <Resource adapter is calling BootstrapContext.createTimer() and allocating a Timer Thread that is not managed by WebLogic Server. This may adversely impact the performance or operation of WebLogic Server.> Sep 09, 2020 11:20:23 AM com.ibm.jbatch.container.impl.ChunkStepControllerImpl invokeChunk SEVERE: Failure in Read-Process-Write Loop com.ibm.jbatch.container.exception.BatchContainerRuntimeException: org.springframework.beans.factory.BeanDefinitionStoreException: IOException parsing XML document from class path resource [Myfilename.xml]; nested exception is java.io.FileNotFoundException: class path resource [Myfilename.xml] cannot be opened because it does not exist at com.ibm.jbatch.container.artifact.proxy.ItemReaderProxy.open(ItemReaderProxy.java:57) at com.ibm.jbatch.container.impl.ChunkStepControllerImpl.openReaderAndWriter(ChunkStepControllerImpl.java:854) (snip)

    I can see the .xml file in the .jar archive, which isn't surprising considering it works when I run a test from Eclipse. I can use an absolute path in the filesystem rather than a classpath path in the resource, and it finds the .xml file, but then it complains that it can't find the class I'm referring to in the bean.

    I feel like these two things are related: essentially, there are elements that clearly exist in the .jar file, but don't get loaded correctly when run from RES/Decision Runner. Maybe a classloader issue?

    ODM version: 8.9.2.3

    Application server: Weblogic 12c



    #OperationalDecisionManager(ODM)
    #Support
    #SupportMigration


  • 2.  RE: Cannot access resource from data provider in DC/Decision Runner

    Posted Fri September 18, 2020 04:35 PM

    Small update: I was able to come up with a workaround, but I feel like I'm doing all kinds of wrong things here. Steps performed:

    1. Remove Apache BCEL directory from my custom .jar file
    2. Use deprecated ssp-setup ant script to incorporate the .jar file into the SSP .war file inside the SSP .ear file (needs BCEL removed in step 1)
    3. Open SSP .ear file and SSP .war file inside of that. Copy the .jar file in WEB-INF/lib to the WEB-INF/lib of the DecisionRunner .war file
    4. Deploy SSP .ear file to application server
    5. Deploy custom .jar file as RES resource

    Is there another option that doesn't require so many deprecated/unorthodox/tedious steps - mainly 2-4? Even if it works, it doesn't feel like this is the right approach.

    Thanks!



    #OperationalDecisionManager(ODM)
    #Support
    #SupportMigration