Multi-Release JARs in Java 9

While developing Java-based solutions, one would have to often include third party libraries to code better. These third-party libraries usually release different releases according to the support matrix they have. This would result in having different library versions targeted for different Java versions. As a result, it would be difficult to ensure that everything works […]

Read More

Stack-Walking API – Java 9

A stack trace is a list of method calls arranged in such a way that the method at which an exception was thrown will be at the top followed by the caller to that method and so on till the main method of the program. We can print a stack trace to the console by […]

Read More

Multi-Resolution Images API – Java 9

Java 9 introduced a new interface called MultiResolutionImage (JEP 251) to encapsulate a set of images with different resolutions into a single multi-resolution image. The APIs related to multi-resolution images are available under java.awt.image package and helps us to programmatically: Get all variants of a particular image. Get an image specific to the resolution required based […]

Read More

Tiered Attribution for javac – Java 9

In Java 8, the implementation of type-checking at compiler level was based on Speculative Attribution. In Speculative Attribution, the same tree can be type-checked against multiple targets at runtime. This is particularly used in target typing for lambda expressions, resolving diamond expressions for generics, etc. To understand more about target typing in lambda expressions, we […]

Read More

HTTP/2 Client In Java 9

HTTP/1.1 is one of the most successful protocols widely used on the web today. For the past 15 years, HTTP/1.1 had been beneficial for growth of the internet but there were subtle problems with the protocol which have started to show up of late. For example, a web application which is resource intensive has a […]

Read More