-
Notifications
You must be signed in to change notification settings - Fork 350
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
Upgrade Oracle Database version to the latest 23c version #1528
Comments
Hi Gerald, thanks for letting us know. Just replacing the image name wasn't sufficient. I got
So I use this as instructed:
But that now leads to
My interpretation is that TestContainers things the database is ready, when it really isn't. I updated to the latest TestContainers version (1.18.3) but that didn't help. I'm currently not sure how to proceed. @gvenzl do you have any suggestion? |
@schauder, there is a minor change to do regarding the connection string since the exposed database service is no more |
Thanks for the hint. Setting the name in Testcontainers to And all our tests pass without further changes. Are you going to create a ticket with TestContainers so we get better direct support? Or will you consider changing the image to better work with the current TestContainers integration? |
The new image is configured as compatible with the old image, which it actually isn't. The default database names are different, so we also set a database name that is different both from the one used by TestContainers as default and the one used by the Docker image. If the TestContainers default is used the database is not found, because the image just creates the default one and the name doesn't mach. If the Docker image default is used, the image creates its default database and then tries to create it again, which fails. These workarounds may be removed once TestContainers properly supports the new image. Closing #1528
Resolved by 3cac9d1 |
Indeed, you have to change the connection string only, as the FREEPDB1 database is created by default but XEPDB1 is hardcoded in TestContainers. Creating a second pluggable database works obviously as well. For tickets, I'd ask to @gvenzl... |
Hi @schauder, First of all, thanks a lot for updating the tests to the new version of Oracle DB! I apologize for not mentioning the database name change and that I was unaware that Testcontainers verifies the image and hence requires I can confirm that I am talking with Testcontainers to enhance their support for the new Oracle Database Free Docker image. If you have any opinions or insights on that approach, I'm sure both the Testcontainers team and certainly I would be grateful! |
Hey @schauder, Just a quick update, today Testcontainers merged a new Oracle Free module, see testcontainers/testcontainers-java@fa23ae4 It should be available for use soon. |
Hi all,
I wanted to let you know that Oracle released a new version of its database, Oracle Database 23c Free which will also be the next LTS version.
I have already made Docker images for that version available too and if you like, you can upgrade from:
spring-data-relational/spring-data-jdbc/src/test/java/org/springframework/data/jdbc/testing/OracleDataSourceConfiguration.java
Line 53 in 9b2032d
to
gvenzl/oracle-free:23-slim
.If you always want to be on the latest version, you could also just opt for
gvenzl/oracle-free:slim
and whenever a new free Oracle DB version releases, I will move thatslim
pointer to that new Docker image version.If I can help with a PR or similar, I'm also happy to do so.
Thanks,
The text was updated successfully, but these errors were encountered: