I need to override one class file in the spring-boot application from an external library io.external.libraryuntil they update their code. This works for me by creating one file with the same package name and class name in my own project.
src/main/java/io/external/library/TheirFile.java
I am a little worried that this is just happening, and under different conditions, the original file may be loaded into memory.
I have seen that there can be ways to achieve this in Gradle by unpacking and repackaging the jar file. This seems to overwhelm me a bit, although this is a temporary solution until a third party updates their code.
What is the easiest or best way to achieve this?
This is a spring-boot application, and my build system is Gradle.
source
share