In this ppt, we will explore quick and practical guide to the most interesting features coming to Java 9/11.
Agenda:
1. Jshell
2. Improvements
3. StackWalker
4. Http2 Client
5. Modularity
3. (Java REPL)
➢ Jshell is nothing it’s just java repl
How to start jshell
>> jshell
How to exit from jshell
>> /exit
>> /ex
4. Lorem Ipsum comes from section Contrary to
popular belief, Lorem Ipsum is not simply random
text.
➢ Convenience factory methods for collections.
eg. List.of(1, 2 , 3, 4 , 5)
eg. Map.of(1, “Kunal”, 2, “Jasmine”)
eg. Set.of(1, 2, 2 ,3 , 5 , 9)
5. Lorem Ipsum comes from section Contrary to
popular belief, Lorem Ipsum is not simply random
text.
➢ Streams API
Methods: dropWhile(), takeWhile()
Method: Intstream.iterate()
Method: Stream.ofNullable()
6. Lorem Ipsum comes from section Contrary to
popular belief, Lorem Ipsum is not simply random
text.
➢ Interface
Interface with private methods.
➢ try with resource
Effectively final try with resource.
➢ Optional
ifPresentOrElse()
Optional.stream()
7. Lorem Ipsum comes from section Contrary to
popular belief, Lorem Ipsum is not simply random
text.
➢ CompletableFutures
Methods: completeOnTimeout()
orTimeout()
copy()
8. Lorem Ipsum comes from section Contrary to
popular belief, Lorem Ipsum is not simply random
text.
❏ StackWalker is thread-safe. Multiple threads can share a single
StackWalker object to traverse its own stack.
eg. StackWalker.getInstance.walk()
9. Lorem Ipsum comes from section Contrary to
popular belief, Lorem Ipsum is not simply random
text.
❏ The protocol-specific requirements are defined in the Hypertext
Transfer Protocol Version 2 (HTTP/2), the Hypertext Transfer Protocol
(HTTP/1.1), and The WebSocket Protocol.
❏ This new API is kind of built around three main classes these are:
● HttpClient
● HttpRequest
● HttpResponse
10. Lorem Ipsum comes from section Contrary to
popular belief, Lorem Ipsum is not simply random
text.
Comparison between Java 1.8 and Java 1.9
❏ NoClassDefFoundError
❏ Version Conflict
❏ Security Issues
❏ Bigger size
11. Lorem Ipsum comes from section Contrary to
popular belief, Lorem Ipsum is not simply random
text.
❏ Module Structure
12. Lorem Ipsum comes from section Contrary to
popular belief, Lorem Ipsum is not simply random
text.
What If???
13. Lorem Ipsum comes from section Contrary to
popular belief, Lorem Ipsum is not simply random
text.
❏ https://www.youtube.com/watch?v=K8Jc_EaBVMI
❏ https://www.youtube.com/watch?v=0RegttLUXeU
❏ https://blog.knoldus.com/
❏ https://www.youtube.com/watch?v=Yacu1yUktjY