JDK 11.0.2 compilation fails with javac NPE on anonymous parameterized class type inference

Bug (JDK-8212586) has been already submitted and fixed in version 12. Minimal, verifiable example: public static void main(String[] args) { new Bug<>(){}; } static class Bug<T> { Bug() { test(new ParameterizedTypeReference<>(){}); } void test(ParameterizedTypeReference<T> typeReference) { } } Some Details. Fix has been also backported to JDK 11 – https://bugs.openjdk.java.net/browse/JDK-8220578. Available starting JDK 11.0.4.

Is log4j2 compatible with Java 11?

If someone is using Maven and is having the same issue while assembling a flat jar, here is what I did to fix the same issue: <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-shade-plugin</artifactId> <version>3.2.1</version> <executions> <execution> <phase>package</phase> <goals> <goal>shade</goal> </goals> <configuration> <transformers> <transformer implementation=”org.apache.maven.plugins.shade.resource.ManifestResourceTransformer”> <mainClass>foo.bar.Generate</mainClass> <manifestEntries> <Multi-Release>true</Multi-Release> </manifestEntries> </transformer> <transformer implementation=”org.apache.maven.plugins.shade.resource.ServicesResourceTransformer”/> </transformers> </configuration> </execution> </executions> </plugin> The important part … Read more

Where is JRE 11? [duplicate]

The whole structure with Java 11 has changed. Java is now a modular platform, where you can create your own “JRE” distribution with specifically the modules that you need to run your application. The release notes at https://www.oracle.com/technetwork/java/javase/11-relnote-issues-5012449.html have the following sentence: In this release, the JRE or Server JRE is no longer offered. Only … Read more

Java 11 application as lightweight docker image

UPD from 07.2019: https://stackoverflow.com/a/57145029/907576 Taking as an example of simple spring boot application (with only one REST endpoint) so far i was able to figure out the following solutions (considering application jar is located at build/libs/spring-boot-demo.jar before Docker build: Jedi path if we want to use official Oracle OpenJDK distribution on stable slim Linux version … Read more

Spring Boot 2.6.0 / Spring fox 3 – Failed to start bean ‘documentationPluginsBootstrapper’

This problem’s caused by a bug in Springfox. It’s making an assumption about how Spring MVC is set up that doesn’t always hold true. Specifically, it’s assuming that MVC’s path matching will use the Ant-based path matcher and not the PathPattern-based matcher. PathPattern-based matching has been an option for some time now and is the … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)