baldimir commented on PR #5888: URL: https://github.com/apache/incubator-kie-drools/pull/5888#issuecomment-2095604555
> That's ok, but I wonder if it makes sense to make the `KieSession` to also implement `Autocloseable` and maybe implement the `close()` method just like an alias for the `dispose()` one. I did something similar for the [RuleUnitInstance](https://github.com/apache/incubator-kie-drools/blob/79a21195741c75da2270693c0a933c8d4d31b2b8/drools-ruleunits/drools-ruleunits-api/src/main/java/org/drools/ruleunits/api/RuleUnitInstance.java#L30) and this allows you to use try-with-resource like [this](https://github.com/apache/incubator-kie-drools/blob/79a21195741c75da2270693c0a933c8d4d31b2b8/drools-ruleunits/drools-ruleunits-impl/src/test/java/org/drools/ruleunits/impl/CepTest.java#L41). WDYT? Yes, that sounds fine. However I think it would be better done in a separate PR. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
