Should Testcontainers modules drop the default image version? #1470
Replies: 2 comments 1 reply
-
|
NodeJs TC did the same recently. Seems like this is the way to go. The only downside is that newer images could be incompatible with builder internal implementation, like Kafka #1353 (comment). |
Beta Was this translation helpful? Give feedback.
-
Migrating to the new constructorStarting with release Old usage: var builder = new ModuleContainerBuilder();New usage: var builder = new ModuleContainerBuilder("repository:tag");Why the change?
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
The Testcontainers for .NET modules always come with a pre-configured image version. Updating the version is tricky because we don't want to cause breaking changes for developers. On the other hand, we also don't want to include versions that are too outdated or possibly affected by security issues. In our best practices, we already recommend that developers override and pin the image version.
I'd like to discuss whether we should do the same as Java (and probably other language implementations) and remove the default image version. Instead, developers would need to provide the image/version up front when creating a container builder instance or at least call
WithImage(string).See also: #1407
WDYT?
Beta Was this translation helpful? Give feedback.
All reactions