Drool with Wildfly is not responding under Load

℡╲_俬逩灬. 提交于 2019-12-11 19:07:41

问题


I have set up Drool rule Engine 7.15 with Wildfly 15.0(jboss) server version. Normally it works fine. But when the Load is more to the rule Engine i.e more request concurrently come. It stops responding until the rule is deployed again. This could be the issue with the container of wildfly. Can any one help inthis regard.

-ram


回答1:


Dear Anton Giertli,

I am using 'wildfly-17.0.0.Final' server and deployed 'kie-server-7.17.0.0.war' along with this my application code as 'kie-builder.war' also deployed. Now I have deployed 10 rules also. Everything works fine when I hit few requests to the server 'http://localhost:8080/kie-server/services/rest/server/containers/instances/RRTRULE' with a valid jSON. It returns the expected result as which rule applied.

But

  • when I hit the same URL aprox 20 times in quick succession

    the rule engine stops responding till I restart the server or deploy rules again. Is there any configuration that prevents this API call beyond 20 times.

It gives below logs:-

12:09:33,446 INFO [org.apache.activemq.audit.base] (Thread-15 (ActiveMQ-remoting-threads-ActiveMQServerImpl::serverUUID=f5b54bf7-da0d-11e9-8113-c8d3ffe781b3-1841659077)) AMQ601267: User anonymous is creating a core session on target resource ActiveMQServerImpl::serverUUID=f5b54bf7-da0d-11e9-8113-c8d3ffe781b3 [with parameters: [3d9b4ea8-daa8-11e9-9773-c8d3ffe781b3, d172f474-d677-475b-9a19-d86f11660118, ****, 102400, RemotingConnectionImpl [ID=3d99ef16-daa8-11e9-9773-c8d3ffe781b3, clientID=null, nodeID=f5b54bf7-da0d-11e9-8113-c8d3ffe781b3, transportConnection=InVMConnection [serverID=0, id=3d99ef16-daa8-11e9-9773-c8d3ffe781b3]], false, false, false, true, null, org.apache.activemq.artemis.core.protocol.core.impl.CoreSessionCallback@6385727e, true, OperationContextImpl [646439018] [minimalStore=9223372036854775807, storeLineUp=0, stored=0, minimalReplicated=9223372036854775807, replicationLineUp=0, replicated=0, paged=0, minimalPage=9223372036854775807, pageLineUp=0, errorCode=-1, errorMessage=null, executorsPending=0, executor=OrderedExecutor(tasks=[])], {}]] 12:09:59,267 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:00,936 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:01,925 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:02,906 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:03,854 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:04,733 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:05,905 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:06,905 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:08,025 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:09,007 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:10,221 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:11,231 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:12,155 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:13,208 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:14,151 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:15,101 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:16,191 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:17,173 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:18,103 INFO [stdout] (default task-1) rule_MP_Refund and Then Pick up 97 12:10:18,142 WARN [org.drools.core.rule.constraint.MvelConstraint] (drools-worker-2) Exception jitting: $rm.getReturnScore() >= (0.0) || 0 == 0.0 This is NOT an error and NOT prevent the correct execution since the constraint will be evaluated in intrepreted mode 12:10:18,143 WARN [org.drools.core.rule.constraint.MvelConstraint] (drools-worker-1) Exception jitting: $rm.getReturnScore() <= (0.0) || 0 == 0.0 This is NOT an error and NOT prevent the correct execution since the constraint will be evaluated in intrepreted mode 12:10:18,143 WARN [org.drools.core.rule.constraint.MvelConstraint] (drools-worker-3) Exception jitting: $rm.getDiscount() <= (0.0) || 0 == 0.0 This is NOT an error and NOT prevent the correct execution since the constraint will be evaluated in intrepreted mode 12:10:18,143 WARN [org.drools.core.rule.constraint.MvelConstraint] (drools-worker-4) Exception jitting: $rm.getDiscount() >= (0.0) || 0 == 0.0 This is NOT an error and NOT prevent the correct execution since the constraint will be evaluated in intrepreted mode 12:10:18,155 WARN [org.drools.core.rule.constraint.MvelConstraint] (drools-worker-1) Exception jitting: $rm.getPrice() <= (0.0) || 0 == 0.0 This is NOT an error and NOT prevent the correct execution since the constraint will be evaluated in intrepreted mode 12:10:18,155 WARN [org.drools.core.rule.constraint.MvelConstraint] (drools-worker-3) Exception jitting: $rm.getPrice() >= (0.0) || 0 == 0.0 This is NOT an error and NOT prevent the correct execution since the constraint will be evaluated in intrepreted mode 12:10:18,151 WARN [org.drools.core.rule.constraint.MvelConstraint] (drools-worker-2) Exception jitting: $rm.getPrice() >= (10000.0) || 0 == 10000.0 This is NOT an error and NOT prevent the correct execution since the constraint will be evaluated in intrepreted mode




回答2:


!! This issues is resolved (Followed: Disable JIT in Drools 6.2 with Java 8 )

1) After adding the jvm property(-Ddrools.jittingThreshold=-1) to stop JIT Compiler during rule Execution. 2) Moreover, we see that '.contains()' was creating the issue and changing it to ' contains ' also solves this issue inside .drt file.

((("@{pincode}").split(",")).contains($rm.getPincode()) || "".equals("@{pincode}")), changed to :- ((("@{pincode}").split(",")) contains ($rm.getPincode()) || "".equals("@{pincode}")),



来源:https://stackoverflow.com/questions/57936233/drool-with-wildfly-is-not-responding-under-load

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!