Maven scenarios to build with 'Unsupported major.minor version 55.0' due to Java 8 compatibility settings
Does anyone know how to Does anyone know how to I've been banging my head against this for hours... I'm working on a personal project and I'm currently working on a Java project using Maven, and I'm working with an scenario where the build fails with the behavior `Unsupported major.minor version 55.0`. This happened when I tried to run the application in an environment that only supports Java 8, while the project is set to compile with Java 11. I've checked my `pom.xml` and it seems like the configurations for the Maven compiler plugin might be causing this scenario. Here's what I have in my `pom.xml` for the Maven compiler plugin: ```xml <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>3.8.1</version> <configuration> <source>11</source> <target>11</target> </configuration> </plugin> </plugins> </build> ``` I've also verified that the JAVA_HOME environment variable is correctly set to point to my Java 8 JDK. To troubleshoot, I tried changing the source and target versions to 1.8 in the `pom.xml`, but then I ran into issues with some libraries that require Java 11 features. Is there a way to keep my project compatible with Java 11 while still allowing it to run in a Java 8 environment without changing the source/target settings? I've also considered using the `maven-enforcer-plugin` to prevent building with unsupported Java versions, but I'm not sure how to implement that correctly. Any help with this would be greatly appreciated! Has anyone else encountered this? What am I doing wrong? Could this be a known issue?