Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Close Workers when Manager is closed #60

Open
meehaws opened this issue Sep 26, 2024 · 0 comments · May be fixed by #66
Open

Close Workers when Manager is closed #60

meehaws opened this issue Sep 26, 2024 · 0 comments · May be fixed by #66

Comments

@meehaws
Copy link
Contributor

meehaws commented Sep 26, 2024

When MongoCseManager is closed, workers are still working and keep throwing the exception:

java.lang.IllegalStateException: state should be: open
	at com.mongodb.assertions.Assertions.isTrue(Assertions.java:81) ~[mongodb-driver-core-4.10.1.jar:?]
	at com.mongodb.internal.connection.BaseCluster.getDescription(BaseCluster.java:170) ~[mongodb-driver-core-4.10.1.jar:?]
	at com.mongodb.internal.connection.AbstractMultiServerCluster.getDescription(AbstractMultiServerCluster.java:54) ~[mongodb-driver-core-4.10.1.jar:?]
	at com.mongodb.client.internal.ClientSessionBinding.isConnectionSourcePinningRequired(ClientSessionBinding.java:135) ~[mongodb-driver-sync-4.10.1.jar:?]
	at com.mongodb.client.internal.ClientSessionBinding.getReadConnectionSource(ClientSessionBinding.java:89) ~[mongodb-driver-sync-4.10.1.jar:?]
	at com.mongodb.internal.operation.OperationHelper.withReadConnectionSource(OperationHelper.java:306) ~[mongodb-driver-core-4.10.1.jar:?]
	at com.mongodb.internal.operation.ChangeStreamOperation.execute(ChangeStreamOperation.java:185) ~[mongodb-driver-core-4.10.1.jar:?]
	at com.mongodb.internal.operation.ChangeStreamOperation.execute(ChangeStreamOperation.java:55) ~[mongodb-driver-core-4.10.1.jar:?]
	at com.mongodb.client.internal.MongoClientDelegate$DelegateOperationExecutor.execute(MongoClientDelegate.java:153) ~[mongodb-driver-sync-4.10.1.jar:?]
	at com.mongodb.client.internal.ChangeStreamIterableImpl.execute(ChangeStreamIterableImpl.java:212) ~[mongodb-driver-sync-4.10.1.jar:?]
	at com.mongodb.client.internal.ChangeStreamIterableImpl.cursor(ChangeStreamIterableImpl.java:187) ~[mongodb-driver-sync-4.10.1.jar:?]
	at com.gravity9.mongocse.MongoChangeStreamWorker.processData(MongoChangeStreamWorker.java:95) [mongo-change-stream-enhancer-1.0.0-beta.jar:?]
	at com.gravity9.mongocse.MongoChangeStreamWorker.run(MongoChangeStreamWorker.java:83) [mongo-change-stream-enhancer-1.0.0-beta.jar:?]
	at java.base/java.lang.Thread.run(Thread.java:833) [?:?]
14:49:11.039 [Thread-0] ERROR com.gravity9.mongocse.MongoChangeStreamWorker csem_sample_mflix_commnets_0_partition_0 - Exception while processing change
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant