Rules Book engine behaves differently on same input
nitinsridar opened this issue · 1 comments
nitinsridar commented
Implementing rules engine service using Spring boot.
Every time If I hit the API with the below request I'm seeing different responses.
The first 5 times it is behaving as expected then if I start sending requests continuously for every 10ms then responses are different and it continues to behave weird.
<dependency><groupId>com.deliveredtechnologies</groupId><artifactId>rulebook-spring</artifactId><version>0.11</version></dependency>
This is the dependency we are using for the rules engine service in our project.
Request:
{
"division":12,
"itemId":609372131802,
"lcoation":"bengaluru",
"buy":false,
"sell":false,
"home":null,
"store":null,
}
Response 1:
{
"division": 12,
"itemId": 609372131802,
"location": "bengaluru",
"re": [
"sellDB",
"calculateAll",
"buyDB"
]
}
Response 2:
{
"division": 12,
"itemId": 609372131802,
"location": "bengaluru",
"fulfillmentTypeList": [
"buyDB"
]
}
Expected Response:
{
"division": 12,
"itemId": 609372131802,
"location": "bengaluru",
"fulfillmentTypeList": [
"buyDB",
"sellDB"
]
}
Clayton7510 commented
Can you attach the code that is having the issues? It would be helpful to see how you configured it. That way, I can determine if it's an issue with how the state is managed across threads or the spring config or something else.