-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
DBZ-7007 Use DebeziumEngine API instead of EmbeddedEngine in the testsuite #4960
Conversation
MySQL 5.7 error is unrelated:
DB2 failures are unrelated ( Server error is unrelated and should be fixed by debezium/debezium-server#44 However, Vitess error may be related. |
It seems also Vitess failure is not related but a bug in the test - filed DBZ-7104 for it. |
DB2 failures are unrelated:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@vjuranek LGTM, thanks! I left one comment WRT renaming of the isRunning
attribute. When done please feel free to merge PR yourself.
debezium-embedded/src/test/java/io/debezium/embedded/AbstractConnectorTest.java
Outdated
Show resolved
Hide resolved
This config will be re-used by possible other implementations of DebeiumEngine API in the embedded package. As DebeziumEngine API can have completely different implementations and thus also config, the class is called `EmbeddedEngineConfig` as it's assumed to be used only by embedded engine "family" of implementations. To keep backward compatibility, the config options are extracted into an interface and `EmbeddedEngine` implements this interface, thus allowing to use these options in custom classes without any need for the code changes.
After fixing start method to really start the connector, this wait loop is not needed any more.
In the second case replace infinite loop by one minute wait. If this is not sufficient for any case, we can increase the timeout in the future.
…ConnectorTest Postgres `RecordsStreamProducerIT` reliaes on EmebeddedEngine.runWithTask(). As this method effectively expose engine's internal task and tests do the asserts against the state of the task, it's hard to replace it. If we want to keep the tests, the most simple approach seems to expose engine task in similar way how EmbeddedEngine does that. Add interface for testing Debezium engine, which would define minimal set of methods which needs to be exposed by the implementing classes to be able to run the testsuite against the Debezium engine. The number of such methods should be as low as possible. Implementing classes would typically act as proxies to actual `DebeziumEngine` implementations. Add `TestingDebeziumEngine` implementation for `EmbeddedEngine` and switch to `TestingDebeziumEngine` in `AbstractConnectorTest`.
@vjuranek Applied, thanks |
https://issues.redhat.com/browse/DBZ-7007