2

The WSO2 Business Rule Manager fails when deploy. I'm using Docker to comunicate WSO2-dashboard and WSO2-worker.

The error logs shows the following:

ERROR {org.wso2.carbon.business.rules.core.services.TemplateManagerService} - Failed to update the deployed artifact for business rule myRule org.wso2.carbon.business.rules.core.exceptions.SiddhiAppsApiHelperException: Failed to update the siddhi app '@App:name('MyApp')  
@App:description('MyDescription')
.
.
.
Siddi Template Code
.
.
.'
on node 'wso2sp-worker:9443' due to a validation error occurred when updating the siddhi app
    at org.wso2.carbon.business.rules.core.deployer.SiddhiAppApiHelper.update(SiddhiAppApiHelper.java:139)
    at org.wso2.carbon.business.rules.core.services.TemplateManagerService.updateDeployedSiddhiApp(TemplateManagerService.java:1400)
    at org.wso2.carbon.business.rules.core.services.TemplateManagerService.updateDeployedArtifacts(TemplateManagerService.java:1388)
    at org.wso2.carbon.business.rules.core.services.TemplateManagerService.redeployBusinessRule(TemplateManagerService.java:663)
    at org.wso2.carbon.business.rules.core.api.impl.BusinessRulesApiServiceImpl.redeployBusinessRule(BusinessRulesApiServiceImpl.java:412)
    at org.wso2.carbon.business.rules.core.api.BusinessRulesApi.redeployBusinessRule(BusinessRulesApi.java:235)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.wso2.msf4j.internal.router.HttpMethodInfo.invokeResource(HttpMethodInfo.java:187)
    at org.wso2.msf4j.internal.router.HttpMethodInfo.invoke(HttpMethodInfo.java:143)
    at org.wso2.msf4j.internal.MSF4JHttpConnectorListener.dispatchMethod(MSF4JHttpConnectorListener.java:218)
    at org.wso2.msf4j.internal.MSF4JHttpConnectorListener.lambda$onMessage$57(MSF4JHttpConnectorListener.java:129)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)
Aura
  • 1,283
  • 2
  • 16
  • 30
Diegox
  • 29
  • 7
  • 1
    Most probably, there could be a problem with your template. Will you be able to include the template file's json in the question (edit the question) please? – Senthuran Ambalavanar Apr 11 '19 at 18:49

1 Answers1

2

This can occur if the siddhi app created by the business rules manager is incorrect. One possible reason for this is using an invalid siddhi app template to create business rules.

Therefore, can you check the following?

  1. Create a siddhi app by filling up the templated fields in your templated siddhi app.
  2. Copy that siddhi file to $SP_HOME/wso2/worker/deployment/siddhi-files directory.
  3. Start the worker runtime.

If there is any issue with the template, it worker will fail to deploy that siddhi app and it will log the relevant error.

Minudika
  • 851
  • 6
  • 23