Spring Boot 3.x upgrade. Could not resolve org.springframework.boot:spring-boot-gradle-plugin:3.0.1

I see you’re using IntelliJ IDEA for this. This is what worked for me: Go to the settings –> Build, Execution, Deployment –> Build Tools –> Gradle. Click on your gradle project under ‘Gradle Projects’. Choose your Gradle JVM for the project… in my case it was openjdk-19. Now it should work.

Apache Spark 3.3.0 breaks on Java 17 with “cannot access class sun.nio.ch.DirectBuffer”

Solution A similar question was asked at Running unit tests with Spark 3.3.0 on Java 17 fails with IllegalAccessError: class StorageUtils cannot access class sun.nio.ch.DirectBuffer, but that question (and solution) was only about unit tests. For me Spark is breaking actually running the program. Please, consider adding the appropriate Java Virtual Machine command-line options. The … Read more

In Java 17 how do I avoid resorting to –add-opens?

From this article it seems that you can avoid resorting to –add-opens by exporting the modules at runtime through the methods of the Burningwave Core library: org.burningwave.core.assembler.StaticComponentContainer.Modules.exportAllToAll() org.burningwave.core.assembler.StaticComponentContainer.Modules.exportPackageToAllUnnamed(“java.base”,”java.lang”)

What are sealed classes in Java 17?

You can follow this link for examples. In short sealed classes gives you the control of which models, classes etc. that can implement or extend that class/interface. Example from the link: public sealed interface Service permits Car, Truck { int getMaxServiceIntervalInMonths(); default int getMaxDistanceBetweenServicesInKilometers() { return 100000; } } This interface only permits Car and … Read more