davidmoten / davidmoten/rxjava2-jdbc

When using NonBlockingConnectionPool the ExecutorService is not shutdown on close

Open
#51 1 comment 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Java
Stars
394
Forks
41
Avg merge
2m
Merged PRs (30d)
1

Description

When using Database.nonBlocking() and not providing a custom scheduler the ExecutorService created is never shutdown. This will prevent JVM shutdown. The responsibility to close it lies in the library because it is created there. It is also impossible to access it through getters from the outside so closing it by hand is only possible using some weird reflection.

```kotlin
val db = Database.nonBlocking().build()
// use at least one connection
db.close()
// ExecutorService still running and never stopped
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.