SlideShare a Scribd company logo
Preparing for Java 9
Modules
Ryan Cuprak
About
Twitter: @ctjava
Email: rcuprak@gmail.com / r5k@3ds.com
Blog: cuprak.info
Linkedin: www.linkedin.com/in/rcuprak
Project Jigsaw Goals
• Make the Java platform scalable for small computing
devices.
• Improve platform security and maintainability
• Enable improved application performance
• Simplify library creation and application development
Reliable configuration
Strong Encapsulation
Why Modules?
• Java currently suffers from JAR ”hell”
• Maven tracks dependencies but no runtime enforcement
• No guarantee an application can start:
NoClassDefFoundError
• Possible to mix library versions on classpath:
• commons-io-2.5 and commons-io-1.6 – what happens?
• Existing module frameworks (OSGi) can’t be used to
modularize the Java platform.

Recommended for you

Spring Framework 3.2 - What's New
Spring Framework 3.2 - What's NewSpring Framework 3.2 - What's New
Spring Framework 3.2 - What's New

As the leading full-stack application framework for Java SE and EE, the Spring Framework continues to deliver significant benefits to Java developers, increasing development productivity and runtime performance while improving test coverage and application quality. In this talk, core Spring Framework committer Sam Brannen will provide attendees an overview of the new features in Spring 3.2 as well as a sneak peak at the roadmap for 4.0. Spring Framework 3.2 builds on several themes delivered in 3.1 with a continued focus on asynchronous MVC processing with Servlet 3.0, support for using @Autowired and @Value as meta-annotations, support for custom @Bean definition annotations, and early support for JCache 0.5. Regarding the internals, CGLIB 3.0 and ASM 4.0 have been inlined, and the framework is now built with Gradle and hosted on GitHub. For those interested in testing their Spring-based web applications, Spring 3.2 offers new support for loading WebApplicationContexts in the TestContext framework, and the formerly standalone Spring MVC Test project is now included in the spring-test module, allowing for first-class testing of Spring MVC applications.

springjavamvc
Spring 3.1 to 3.2 in a Nutshell - Spring I/O 2012
Spring 3.1 to 3.2 in a Nutshell - Spring I/O 2012Spring 3.1 to 3.2 in a Nutshell - Spring I/O 2012
Spring 3.1 to 3.2 in a Nutshell - Spring I/O 2012

Spring 3.1 introduced several eagerly awaited features including bean definition profiles (a.k.a., environment-specific configuration), enhanced Java-based application and infrastructure configuration (a la XML namespaces), and a new cache abstraction. This session will provide attendees a high-level overview of these major new features plus a quick look at additional enhancements to the framework such as the new c: namespace for constructor arguments, support for Servlet 3.0, improvements to Spring MVC and REST, and Spring's new integration testing support for profiles and configuration classes. In addition, this talk will introduce new features under development in the Spring 3.2 roadmap.

springiospringjava
Java 9 preview
Java 9 previewJava 9 preview
Java 9 preview

Java 9 will introduce a new module system that will provide code encapsulation and a way to explicitly declare dependencies between modules. Some key changes include the ability to define modules using a module-info.java file, and new parameters for javac and java to support modules. There are still some unresolved issues around module declarations, artifacts, descriptors, graphs, reflection, and versioning that need to be addressed prior to final release. The new module system is aimed at addressing problems like large runtime footprints, classpath issues, and lack of visibility controls between packages.

java 9
Project Jigsaw Pieces
• JEPs
• 200: Modular JDK
• 201: Modular Source Code
• 220: Modular Run-time Images
• 260: Encapsulate Most Internal APIs
• 261: Module System
• 282: jlink: Java Linker
• JSR 376 Java Platform Module System
Project Jigsaw
• Target Release Date: July 27th now September 21st 2017
You now have time!
Comparing Jigsaw / OSGi / Java EE
Feature Jigsaw OSGi Java EE
Allows cycles between packages in different modules ❌ ✅ ✅
Isolated package namespaces ❌ ✅ ✅
Allows lazy loading ❌ ✅ ✅
Allows dynamic package addition ❌ ✅ ✅
Unrestricted naming ❌ ❌ ✅
Allows multiple versions of an artifact* ❌ ✅ ✅
Allows split packages ❌ ✅ ✅
Allows textual descriptor ❌ ✅ ✅
Source: https://goo.gl/7RKqQx
Class Loading & Module System
Bootstrap Loader Platform Loader Application Loader
Java Platform Module System
Java Virtual Machine
java.base java.logging java.sql java.corba jdk.compiler log4j

Recommended for you

Web application development using Play Framework (with Java)
Web application development using Play Framework (with Java)Web application development using Play Framework (with Java)
Web application development using Play Framework (with Java)

This document provides an overview of the Play Framework for web application development using Java. It discusses the history and architecture of Play, how to set up a Play project, the MVC structure, routing, controllers, views, sessions, assets, hot code reloading, databases, testing, deployment, and scaling. Play uses Netty as its web server, is stateless, supports hot code reloading, and allows building asynchronous and reactive applications. It also has integrations for Akka, WebSockets, caching, internationalization, and more.

java play framework
Java 9 Module System Introduction
Java 9 Module System IntroductionJava 9 Module System Introduction
Java 9 Module System Introduction

The document provides an overview of the Java Platform Module System (JPMS) introduced in Java 9. Key points include: - JPMS addresses issues with strong encapsulation, reliable dependency management, and API evolution in Java applications and libraries. - The module is a new abstraction that more finely controls access and dependencies through package exports and module declarations. - The module path replaces the classpath, and the modularized JDK itself is composed of platform modules. - Projects can begin adopting a modular structure immediately while the ecosystem transitions over time.

Play Framework and Activator
Play Framework and ActivatorPlay Framework and Activator
Play Framework and Activator

The document provides an introduction to Typesafe Activator and the Play Framework. It discusses how Activator is a tool that helps developers get started with the Typesafe Reactive Platform and Play applications. It also covers some core features of Play like routing, templates, assets, data access with Slick and JSON, and concurrency with Futures, Actors, and WebSockets.

play activator typesafe
Common Questions
• Do I have to modularize my application to run on Java 9?
• Will my Java 6/7/8 application compile on Java 9?
• Will my Java 6/7/8 application run un-modified on Java 9?
• How do I identify problems today?
- NO -
- Depends – using private APIs? -
- Depends – using private APIs? -
- jdeps -
Common Questions…
• Can I partially leverage modules?
• Is tooling ready? (Maven/Gradle/IntelliJ/NetBeans/etc.)
• Do application containers work on 9 today?
• Can I try out Java 9 today?
- YES -
- Absolutely NOT -
- Maybe -
- YES -
JEP 200: Modular JDK
JDK is fully modularized!
jdeps
• Command line tool included with Java 8
• Static class dependency checker
• Key parameters
• -jdkinternals – flags internal API usage that will break in Java 9
• -dotoutput <dir> - dot output files
• -cp – classpath to analyze
• -verbose:class/package – package/class level dependencies
• Use jdeps on all generated output and dependencies

Recommended for you

Why Play Framework is fast
Why Play Framework is fastWhy Play Framework is fast
Why Play Framework is fast

Typesafe trainer and consultant Will Sargent describes just how Play Framework is so "fast" for Java and Scala production apps. More Play, Akka, Scala and Apache Spark webinars, presentations, and videos: http://typesafe.com/resources/videos

scalajavaplay framework
Migrating to Java 9 Modules
Migrating to Java 9 ModulesMigrating to Java 9 Modules
Migrating to Java 9 Modules

With Java 9 modules coming to us soon, you want your existing code to be fully ready for the module system. Making code modular can be a daunting task, but Java 9 comes with a number features to ease migration. This includes automatic modules, the unnamed module and a number of command line arguments. In this talk we will look at examples of migrating real code. It discusses common problems you’ll run into during migration, leading to practical tips and the ability to set realistic goals. It’s also a good way to understand the module system itself and the various migration paths it supports. This talk is an excellent preparation to start migrating your own code. * Understanding modules and the module path * Automatic modules * Mixing classpath and modulepath * Dealing with reflection * Escape switches * Jdeps All topics will be based on examples of often used libraries and frameworks.

javajdk9migration
Java(ee) mongo db applications in the cloud
Java(ee) mongo db applications in the cloud Java(ee) mongo db applications in the cloud
Java(ee) mongo db applications in the cloud

This document provides an agenda and summary for a workshop on developing MongoDB applications on OpenShift presented by Shekhar Gulati. The agenda includes getting started with OpenShift, developing a location-aware Java EE application using JAX-RS and CDI for REST services, and MongoDB for the database. The document discusses OpenShift, JAX-RS, CDI, and MongoDB concepts. It also outlines code samples and steps to create and deploy a sample Twitter-like application on OpenShift that supports creating, finding, and geo-searching statuses.

jdeps – Example
jdeps -jdkinternals jide-common.jar
jide-common.jar -> /Library/Java/JavaVirtualMachines/jdk1.8.0_121.jdk/Contents/Home/jre/lib/rt.jar
com.jidesoft.plaf.aqua.AquaJidePopupMenuUI (jide-common.jar)
-> com.apple.laf.AquaPopupMenuUI JDK internal API (rt.jar)
com.jidesoft.plaf.aqua.AquaRangeSliderUI (jide-common.jar)
-> apple.laf.JRSUIConstants JDK internal API (rt.jar)
-> apple.laf.JRSUIConstants$Orientation JDK internal API (rt.jar)
-> apple.laf.JRSUIConstants$State JDK internal API (rt.jar)
-> com.apple.laf.AquaSliderUI JDK internal API (rt.jar)
com.jidesoft.plaf.basic.BasicFolderChooserUI (jide-common.jar)
-> sun.awt.shell.ShellFolder JDK internal API (rt.jar)
com.jidesoft.plaf.basic.BasicPainter (jide-common.jar)
-> sun.swing.plaf.synth.SynthIcon JDK internal API (rt.jar)
com.jidesoft.plaf.metal.MetalUtils$GradientPainter (jide-common.jar)
-> sun.swing.CachedPainter JDK internal API (rt.jar)
com.jidesoft.plaf.windows.AnimationController (jide-common.jar)
-> sun.awt.AppContext JDK internal API (rt.jar)
-> sun.security.action.GetBooleanAction JDK internal API (rt.jar)
…
JIDE: Widely used
Swing component
library (jidesoft.com)
jdeps – Fixing/Alternatives
https://goo.gl/fxzKwP
jdeps: Build Integration
Maven JDeps Plugin: https://goo.gl/thr88W
Goals:
• jdeps:jdkinternals
• jdeps:test-jdkinternals
MODULE BASICS

Recommended for you

Java build tool_comparison
Java build tool_comparisonJava build tool_comparison
Java build tool_comparison

The document compares several Java build tools: Ant + Ivy, Maven, Gradle, and Buildr. It describes their key features such as dependency management, build lifecycles, and conventions. A results matrix shows how well each tool supports desired build features such as compiling Java code, running tests, and property expansion. The evaluation notes that Ant, Ivy and Maven have been around longest but Gradle is promising. Buildr is considered very flexible but has potential platform issues being built on Ruby.

Introduction tomaven
Introduction tomavenIntroduction tomaven
Introduction tomaven

Maven is a build tool that focuses on project structure, dependencies, and conventions. It allows for easy creation of multi-module projects and provides excellent dependency management. Key features include a consistent project structure, dependency management that handles transitive dependencies, and a lifecycle of goals like compile and test. Maven uses a POM file to describe a project's structure, dependencies, and plugins.

Getting Started with Java EE 7
Getting Started with Java EE 7Getting Started with Java EE 7
Getting Started with Java EE 7

The document provides an overview of new features in Java EE 7, including WebSocket support, JSON processing, batch applications, concurrency utilities, simplified JMS API, and enhancements to other Java EE technologies. It discusses 10 top features in more depth and includes code examples. The goal is to help developers get started with Java EE 7.

glassfishwildflyjavaee
Java Visibility Today
How do you hide the implementation class?
Java Accessibility
JDK 1-8 JDK 9+
public public
protected public to specific modules
<package> public only within a module
private protected
<package>
private
Module Definition
• module-info.java defines a module
• Contents define the following:
• Unique name of the module
• Dependencies of the module
• Packages to be exported for use by other modules
• Placed at root of the namespace
Module Name
exports
requires
Module Definition
<open> module <module-name> {
[export <java package> [to <module name>]
[requires [transitive] <module-name>]
[opens <module name> [to <module name]]
[provides <interface> with <implementation>]
[uses <interface>]
}

Recommended for you

Apache maven and its impact on java 9 (Java One 2017)
Apache maven and its impact on java 9 (Java One 2017)Apache maven and its impact on java 9 (Java One 2017)
Apache maven and its impact on java 9 (Java One 2017)

Maven is a build tool that manages projects and dependencies. It aims to make the build process easy and provide a uniform system. With Java 9, Maven faces challenges due to the module system's differences from the classpath. Specifically, the modulepath does not support all file types like the classpath. This causes issues for Maven which relies on dependencies being on the classpath. Additionally, automatic modules generated from JAR files can cause problems for projects. Maven cannot directly generate module descriptors but tools like Jdeps can assist with initial descriptors. Overall, while challenges exist, Maven can still be used for most projects with Java 9.

mavenjava
Migrating to java 9 modules
Migrating to java 9 modulesMigrating to java 9 modules
Migrating to java 9 modules

JavaOne 2017 presentation about migration existing code to Java 9 modules. Demos used during the presentation can be found on GitHub: https://github.com/java9-modularity/java9-migration-demos

javamodularityjava9
Scala play-framework
Scala play-frameworkScala play-framework
Scala play-framework

The Play Framework is a web framework for Java and Scala that provides a lightweight and scalable architecture built on Akka. It allows for the creation of RESTful applications with non-blocking I/O and real-time capabilities. Play embraces modern web technologies and includes features for persistence, security, internationalization and more.

scalaplay framework
Module Basics
• Module names must be unique
• Names should follow reverse domain name pattern
• Modules are eagerly loaded
• Dependency graph is built and checked on startup
• Application won’t start if modules are missing
• No support for versioning
• Only one version of a module may be loaded
• Layers maybe used to load different versions of a module
About Versioning…
• Two modules with the same package names in them are
considered to be different versions of the same module.
• Two modules with the same name are considered to be
two versions of the same module.
• Concealed package conflicts:
• When two modules have the same package name in them, but the
package is private in both modules, the module system cannot load
both modules into the same layer
Introducing the Module Path
• Module path augments / extends the classpath
• All command line tools now include both
--module-path
--upgrade-module-path
--add-modules
--describe-module
--dry-run
--validate-modules
• Use java –list-modules to see all available modules
Parameters on java command
JDK Modules
• jdk.base is included by default.
• java.se and java.se.ee are aggregator modules
• java.se.ee contains the following modules:
• java.corba
• java.transaction
• java.xml.ws.annotation
• javax.xml.ws
• java.xml.bind
• java.activation
• java runs with java.se modules – not java.se.ee

Recommended for you

Workshop Framework(J2EE/OSGi/RCP)
Workshop Framework(J2EE/OSGi/RCP)Workshop Framework(J2EE/OSGi/RCP)
Workshop Framework(J2EE/OSGi/RCP)

The document discusses various aspects of developing modular applications using J2EE, OSGi, and RCP frameworks. It covers: 1. The structure and organization of modules, projects, and dependencies when using different frameworks like J2EE, Spring, Maven, and OSGi. 2. How modules, plugins, and bundles can be developed and packaged for each framework. This includes module/plugin sources, views, packaging, and dependencies. 3. Integration aspects like how to integrate databases, connection pools, templating engines, and more through extension bundles/plugins across frameworks.

Preparing your code for Java 9
Preparing your code for Java 9Preparing your code for Java 9
Preparing your code for Java 9

This presentation covers some of the aspects that a developer should be aware of while moving to Java 9.

java 9jdk9java 9 jeps
Java Platform Module System
Java Platform Module SystemJava Platform Module System
Java Platform Module System

Vignesh Ramesh gives an overview of Java modules in Java 9. Modules allow for strong encapsulation by only exporting certain packages. This addresses issues in Java 8 where all packages were effectively public. The module system solves problems like weak encapsulation and jar hell. Key aspects include module descriptors, exports, requires, and the new jlink tool for creating custom runtime images.

javajpmsjigsaw
Dependency Cycles
java.base
org.ctjava.model org.ctjava.util
Dependency Cycles
org.ctjava.admin
org.ctjava.model org.ctjava.util
Simple Module Example
javac -d out src/org/ctjava/services/MeetingService.java
src/org/ctjava/services/impl/MeetingServiceImpl.java src/module-info.java
Cannot use reflection to find
MeetingServiceImpl
Simple Module Example…
Compiler Output:
Module Definition

Recommended for you

Modules in Java? Finally! (OpenJDK 9 Jigsaw, JSR376)
Modules in Java? Finally! (OpenJDK 9 Jigsaw, JSR376)Modules in Java? Finally! (OpenJDK 9 Jigsaw, JSR376)
Modules in Java? Finally! (OpenJDK 9 Jigsaw, JSR376)

This talk is for a very important new feature in Java SE 9. Code named Jigsaw, this feature modularizes the Java SE platform. The coolest thing we do here is to create a custom JRE Code: https://bitbucket.org/stybz/jigsaw.sty/ PPT: https://www.slideshare.net/mihailstoynov/modules-in-java-finally-openjdk-jigsaw Video: https://www.youtube.com/watch?v=W5LeNPtPrqw

openjdk jigsaw jsr376 java java9 jdk9
What we can expect from Java 9 by Ivan Krylov
What we can expect from Java 9 by Ivan KrylovWhat we can expect from Java 9 by Ivan Krylov
What we can expect from Java 9 by Ivan Krylov

Java 9 is currently scheduled to become generally available in less then 1 year. Perhaps now is a good time to have a closer look at language proposals and API changes in Java 9. There are over 70 proposals targeted to Java 9, we will have a looks at some key ones, starting with java modularity. We will look at some breaking changes and ways to develop both short and long term solutions for adoption of new upcoming version of Java.

big datajavapresentation
Java 9 and the impact on Maven Projects (JavaOne 2016)
Java 9 and the impact on Maven Projects (JavaOne 2016)Java 9 and the impact on Maven Projects (JavaOne 2016)
Java 9 and the impact on Maven Projects (JavaOne 2016)

The JavaOne presentation describes the new Java 9 features related to Maven and the way how developers can apply these on their Maven projects.

mavenjigsawjava
Multiple Modules
Compiling
javac -d out --module-source-path src
$(find . -name "*.java")
Module
Module
Directory containing module uses module name.
Names must match or compiler error.
Packaging
jar --create --file=org.ctjava.model@1.0.jar
--module-version=1.0 -C out/org.ctjava.model .
jar --create --file=org.ctjava.service@1.0.jar
--module-version=1.0 -C out/org.ctjava.service .
Note: Module version isn’t used for module
resolution. It is recorded in module-info.class.
Transitive Dependencies

Recommended for you

Java9 and the impact on Maven Projects (JFall 2016)
Java9 and the impact on Maven Projects (JFall 2016)Java9 and the impact on Maven Projects (JFall 2016)
Java9 and the impact on Maven Projects (JFall 2016)

The JFall presentation describes the new Java 9 features related to Maven and the way how developers can apply these on their Maven projects.

jigsawjavamaven
Java 9, JShell, and Modularity
Java 9, JShell, and ModularityJava 9, JShell, and Modularity
Java 9, JShell, and Modularity

Java 9 introduced several new features including JShell, modules, and services. JShell allows developers to test Java code interactively from the command line. Modules allow Java code to be modularized by defining explicit dependencies and encapsulating packages. Services allow modules to discover implementations of an interface at runtime through a service loader. The modularization of Java aims to improve maintainability, security, and performance of Java applications.

java9jigsawmodularity
Java modules
Java modulesJava modules
Java modules

Huge JRE images were a huge problem for packaging and deploying small and lightweight tools based on Java. Have you tried to reduce Java runtime images? You will be surprised how well that works. From JDK 9 a minimal image targeting desktops can be as small as 18MB!This is a huge improvement but how does this black-magic work? I will be wowing you with an overview of Java’s custom runtime image tooling and present a interactive demo on how to create a mini Java runtime image file. We bust the myths around Java cloud computing and show you how to embraced Cloud Orientated development with Java. See how the new Java module system works with general patterns for developing a modular Java Cloud application.

javamodulesjigsaw
Transitive Dependencies…
Qualified Exports
Admin utility uses a JavaFX UI
Qualified Exports…
Exception in thread "main" java.lang.reflect.InvocationTargetException
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:564)
at java.base/sun.launcher.LauncherHelper$FXHelper.main(LauncherHelper.java:946)
Caused by: java.lang.RuntimeException: Unable to construct Application instance: class org.ctjava.admin.AdminConsole
at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:963)
at javafx.graphics/com.sun.javafx.application.LauncherImpl.lambda$launchApplication$2(LauncherImpl.java:198)
at java.base/java.lang.Thread.run(Thread.java:844)
Caused by: java.lang.IllegalAccessException:
class com.sun.javafx.application.LauncherImpl (in module javafx.graphics) cannot access class
org.ctjava.admin.AdminConsole (in module org.ctjava.admin) because module org.ctjava.admin does not export
org.ctjava.admin to module javafx.graphics
• JavaFX LauncherImpl cannot access AdminConsole
• Class in javafx.graphics tried to instantiate AdminConsole in
org.ctjava.admin
Qualified Exports

Recommended for you

Java 9 and the impact on Maven Projects (ApacheCon Europe 2016)
Java 9 and the impact on Maven Projects (ApacheCon Europe 2016)Java 9 and the impact on Maven Projects (ApacheCon Europe 2016)
Java 9 and the impact on Maven Projects (ApacheCon Europe 2016)

The document discusses the impact of Java 9 on Maven projects and provides strategies for Maven and plugins to support Java 9. It outlines changes in Java 9 like the module system and new JAR format that Maven must accommodate. It recommends verifying that plugins work with Java 9 and do not use internal APIs or have duplicate packages. Maven plugins may need to select the module path for compilation in some cases.

javaapacheconjigsaw
S/W Design and Modularity using Maven
S/W Design and Modularity using MavenS/W Design and Modularity using Maven
S/W Design and Modularity using Maven

Here are the steps to filter the resource properties in the example: 1. Define the my.filter.value property in a filter file (e.g. src/main/filters/filter.properties): my.filter.value=hello 2. Define the command.line.prop property in the pom.xml: <properties> <command.line.prop>hello</command.line.prop> </properties> 3. The settings.offline property will be filtered from the <offline>true</offline> value defined in settings.xml 4. Add filtering configuration to the pom.xml: <build> <filters> <filter>src

mavenjavamodularity
As7 jbug j_boss_modules_yang yong
As7 jbug j_boss_modules_yang yongAs7 jbug j_boss_modules_yang yong
As7 jbug j_boss_modules_yang yong

This document discusses JBoss Modules, which provides a module system for loading and running modules in Application Server 7. It describes modules as collections of code and resources that implement specific domain requirements. JBoss Modules defines each module as having its own classloader, allowing isolation and preventing conflicts between modules. It manages module dependencies by only loading required imports and exporting specified APIs. The presentation demonstrates how JBoss Modules loads and executes modules quickly and efficiently to serve as the core of Application Server 7.

jlink
• Generates a runtime-image including
the JVM.
• Only required modules are included
• Basic invocation:
jlink --module-path <modulepath>
--add-modules <modules>
--limit-modules <modules>
--output <path>
Demo used
JavaFX: 95 mb
Full JDK: 454 mb
DIGGING DEEPER
Deprecated Modules
Code compiled using Java 8:
Deprecated Modules…
java -jar WebEndpointTest.jar
Worked on Java 8 – what happened?
Fix:
java --add-modules java.xml.ws -jar WebEndpointTest.jar

Recommended for you

Java 9 / Jigsaw - AJUG/VJUG session
Java 9 / Jigsaw - AJUG/VJUG  sessionJava 9 / Jigsaw - AJUG/VJUG  session
Java 9 / Jigsaw - AJUG/VJUG session

This document provides an agenda and information for a Java 9/Jigsaw hack day event hosted by the Atlanta Java Users Group. The agenda includes sessions on Java 9 modularization, JLink, migrating non-modular apps to Java 9, and feedback. Presenters will discuss what modularization means in Java 9, including splitting the JDK into named modules that declare dependencies. Attendees will have hands-on exercises and are encouraged to provide live feedback.

javajava9jdk9
OOP with Java
OOP with JavaOOP with Java
OOP with Java

Here are the key differences: Reserved words: These are words that have special meaning in Java like class, public, etc. They cannot be used as regular identifiers. Modifiers: Modifiers like public, private, static etc. specify attributes of classes, methods and variables. Package: A package is a namespace that organizes related classes and interfaces. It provides access protection. Libraries: Libraries are pre-compiled classes that provide useful functionality that can be included in programs using import statements. JVM version: The Java Virtual Machine version specifies the Java runtime environment. Programs need to be compatible with the JVM version. JVM: The Java Virtual Machine is an abstract computing machine that

Modern Java Workshop
Modern Java WorkshopModern Java Workshop
Modern Java Workshop

This document summarizes changes to the Java programming language from JDK 9 to JDK 16, including new features and modules. Some key points: - Java has moved to a six-month release cycle, delivering more features faster than before. - Modules were introduced in JDK 9 to improve modularity. Modules group related code and dependencies. - Incubator modules and preview features allow testing of non-final APIs before inclusion in the Java SE platform. - Local variable type inference using 'var' was added in JDK 10 for simpler declaration of local variables when types can be inferred. - Modules, the module system, and tools like jlink and jdeps help manage dependencies

javajdkopenjdk
Module Types
Automatic Modules • Mechanism for using JARs which do not
include a module-info.java configuration
• Export all of the JAR packages
• Reads all other modules
• Module name is dynamically generated
Unamed Module • Alls JARs and classes on the classpath will
be contained un the Unamed Module.
• Similar to Automatic Modules
• Does not possess a name
Platform Modules • JDK modules
JARs & Module System
--module-path -classpath
Modular JAR Application Module Unnamed Module
Non-modular JAR Automatic Module Unnamed Module
Unnamed module name: ALL-UNNAMED
Readability
Module Type Origin Export
Packages
Read Modules
Named Platform Provided by platform Explicitly
Named Application All JARS containing
module-info on the
module path
Explicitly • Platform
• Application
• Automatic
Automatic All JARs without module-
info but on module path
All • Platform
• Application
• Automatic
• Unnamed
Unnamed Classpath All • Platform
• Automatic
• Application
Automatic Modules

Recommended for you

An overview of Scalable Web Application Front-end
An overview of Scalable Web Application Front-endAn overview of Scalable Web Application Front-end
An overview of Scalable Web Application Front-end

Problem Definition: Building large web applications with dozens of developers is a difficult task. Organizing the engineers around a common goal is one thing, but organizing your code so that people can work efficiently is another. Many large applications suffer from growing pains after just a few months in production due to poorly designed JavaScript with unclear upgrade and extension paths. Scalable JavaScript Application Framework: Yahoo! home page engineer Nicholas Zakas, author of Professional JavaScript for Web Developers, introduced front-end architecture for complex, modular web applications with significant JavaScript elements.

web applicationjavascriptscaleapp
Apache Maven supports all Java (JokerConf 2018)
Apache Maven supports all Java (JokerConf 2018)Apache Maven supports all Java (JokerConf 2018)
Apache Maven supports all Java (JokerConf 2018)

With the release train we can expect a new version of Java every 6 months. This means that tools like Maven should try to keep with this pace. Especially Java 9 came with some new features, and Maven managed to support these features. Maven found an elegant solution to work with modulepaths and classpaths without any need for developers to specify which jars belongs where. This session will highlight the most important features developers should know to work with Java 9 and 10, combined with some practical tips and warnings.

mavenjavajava11
JavaOne 2016: Life after Modularity
JavaOne 2016: Life after ModularityJavaOne 2016: Life after Modularity
JavaOne 2016: Life after Modularity

Covers the common issues seen when migrating from Java 8 to Java 9. This deck shows simplified examples of the issues and code snippets of how to address them.

#jigsaw #ibm #modularity #java9#javaone2016
Automatic Modules…
Code in MyInvocationLibrary:
Code in org.ctjava.admin – module:
Automatic Modules…
java.lang.IllegalAccessException: class org.ctjava.util.InstantiateUtility (in module MyInvocationLibrary) cannot
access class org.ctjava.admin.AdminCallback (in module org.ctjava.admin) because module org.ctjava.admin
does not export org.ctjava.admin to module MyInvocationLibrary
Escape & Encapsulation Kill Switch
Important javac command line options:
--add-opens – opens a package
--permit-illegal-access - All code in the unnamed module
can access other types regardless of any limitations.
Will result in a WARNING: to be removed
in Java 10.
SERVICES

Recommended for you

OpenJDK Penrose Presentation (JavaOne 2012)
OpenJDK Penrose Presentation (JavaOne 2012)OpenJDK Penrose Presentation (JavaOne 2012)
OpenJDK Penrose Presentation (JavaOne 2012)

Presentation given on OpenJDK project Penrose by Tim Ellison and David Bosschaert at Penrose BOF at JavaOne 2012

javaonejigsawmodularity
Java Core | Java 8 and OSGi Modularisation | Tim Ellison & Neil Bartlett
Java Core | Java 8 and OSGi Modularisation | Tim Ellison & Neil BartlettJava Core | Java 8 and OSGi Modularisation | Tim Ellison & Neil Bartlett
Java Core | Java 8 and OSGi Modularisation | Tim Ellison & Neil Bartlett

The talk will cover a bit of background first to set things up: what is a module, why do we need a module system, summary of Java's existing support for modularity. Then it will move on to give a comparison of OSGi's and Jigsaw's dependency models. Pros and cons of each model in different environments will be discussed. Finally, opportunities and challenges for interoperability: from the perspective of both application developers (who may need to integrate modules from both kinds) and from library module developers (who may need to target both module systems)

jaxjax londonjava
Jax london 2011
Jax london 2011Jax london 2011
Jax london 2011

The document discusses modularization in Java 8 and OSGi. It describes what modules are and why they are needed, including for managing dependencies and versioning. It outlines the characteristics of a good module system and compares how Java 8's Project Jigsaw and OSGi handle modularization. Key points include how both aim to address issues like class loading performance and dependency management, but OSGi has existing tools and does not require language changes.

Services
• API first added in Java 6
• Rarely used outside of JDK
• Enhanced/altered for Jigsaw
Services Example
Defining Service API
Service Implementation

Recommended for you

Leaner microservices with Java 10
Leaner microservices with Java 10Leaner microservices with Java 10
Leaner microservices with Java 10

This is the material for Tampere workshop on 14th May 2018. How to combine modern technologies such as Java 10, Spring Boot 2, Docker, to create more lightweight and modern microservices - or any services you like.

java 10microservicesdocker
Jakarta EE Test Strategies (2022)
Jakarta EE Test Strategies (2022)Jakarta EE Test Strategies (2022)
Jakarta EE Test Strategies (2022)

Embracing Jakarta EE 10 not only enable you to write better structured applications, it also enables you to write more testable applications. Correctly leveraging CDI enables integration testing where you can simulate a database error and verify that JMS messages are lost due to a RuntimeException. This session will focus on strategies and techniques for testing message handing, transaction management, security, and data model integrity. You will see how you can check message delivery and error handling, session failover, database versioning, and two-phase commits with JMS and databases. All too often assumptions are made that are proven wrong in production. This session will show you how to take your testing to the next level.

javajakartaeeaquillian
DIY Home Weather Station (Devoxx Poland 2023)
DIY Home Weather Station (Devoxx Poland 2023)DIY Home Weather Station (Devoxx Poland 2023)
DIY Home Weather Station (Devoxx Poland 2023)

Weather is a fascinating and important aspect of our lives, and with the rise of smart home technology, it has become easier than ever to track and monitor weather conditions in your own backyard. In this presentation, I will explore the process of building a home weather station. I will discuss the hardware components needed to build a weather station, including sensors for temperature, humidity, pressure, and precipitation, as well as the embedded board itself. I will also cover the programming aspect of the project, including how to read data from the sensors and transmit it wirelessly to the cloud. By the end of this presentation, you will have a solid understanding of how to build and program a home weather station using Arduino, and how to customize and expand the project to fit your specific needs.

arduinoweatheresp32
Service in Action
JAVA 9 TOOLING
June 2017 Status
Tooling Support
• Early access JDK 9 builds:
http://jdk.java.net/9/
• Use jenv to swich between Java 8 & 9
http://www.jenv.io/
Examples:
jenv local 9-ea (locally switch to Java 9)
jevn global 1.8 (globally use Java 8)
Note: rt.jar and tools.jar were removed.
Tooling Support
Tool Status
NetBeans 9 🔶 Developer Preview
IntelliJ 2017.1 ✅
Eclipse 🔶
Maven ❌
Gradle ❌
• Maven & Gradle do not generate module-info.java.
• Gradle 3.4 doesn’t work on Java 9
• Maven 3.5 doesn’t completely work (not all plugins compatible)
• Eclipse Neon won’t start with Java 9 edit ini file.

Recommended for you

Containerless in the Cloud with AWS Lambda
Containerless in the Cloud with AWS LambdaContainerless in the Cloud with AWS Lambda
Containerless in the Cloud with AWS Lambda

Slides from ConFoo (confoo.ca) 2017 presentation on Amazon Lambda. Covers AWS Lambda, AWS Cognito, and AWS API-Gateway.

javaaws api-gatewayaws
Java script nirvana in netbeans [con5679]
Java script nirvana in netbeans [con5679]Java script nirvana in netbeans [con5679]
Java script nirvana in netbeans [con5679]

This document discusses using NetBeans as an IDE for JavaScript development. It provides an overview of NetBeans' features for JavaScript including syntax highlighting, code completion, debugging, support for frameworks like Angular and Node.js, and mobile development with Apache Cordova. It also demonstrates how to set up and configure NetBeans for common JavaScript tasks like adding libraries, using build tools like Grunt and Gulp, and setting up unit testing with Karma and Jasmine.

htmljavascriptnetbeans
Jms deep dive [con4864]
Jms deep dive [con4864]Jms deep dive [con4864]
Jms deep dive [con4864]

JavaOne 2016 JMS is pretty simple, right? Once you’ve mastered topics and queues, the rest can appear trivial, but that isn’t the case. The queuing system, whether ActiveMQ, OpenMQ, or WebLogic JMS, provides many more features and settings than appear in the Java EE documentation. This session looks at some of the important extended features and configuration settings. What would you need to optimize if your messages are large or you need to minimize prefetching? What is the best way to implement time-delayed messages? The presentation also looks at dangerous bugs that can be introduced via simple misconfigurations with pooled beans. The JMS APIs are deceptively simple, but getting an implementation into production and tuned correctly can be a bit trickier.

java ee7jmsactivemq
Maven
Maven status: https://goo.gl/PxuqZF
Maven
• Maven Shade Plugin and Jigsaw don’t mix (uber jar)
• Example project with Maven and Java 9/Jigsaw:
• https://goo.gl/rmzKBa
NetBeans & Java 9
• NetBeans Developer Preview required for Java 9.
• New project template for modular projects.
• Creates Ant build files
NetBeans & Java 9
• Module structure not compatible with javac:
• <module>/classes/<source code>
• Detects imports where the module is not imported.
• Does not auto-import yet.

Recommended for you

Top 50 java ee 7 best practices [con5669]
Top 50 java ee 7 best practices [con5669]Top 50 java ee 7 best practices [con5669]
Top 50 java ee 7 best practices [con5669]

JavaOne 2016 This session provides 50 best practices for Java EE 7, with examples. The best practices covered focus primarily on JPA, CDI, JAX-WS, and JAX-RS. In addition, topics involving testing and deployment are covered. This presentation points out where best practices have changed, common misconceptions, and antipatterns that should be avoided. This is a fast-paced presentation with many code samples.

cdijavaone 2016java ee7
Developing in the Cloud
Developing in the CloudDeveloping in the Cloud
Developing in the Cloud

Configuring and maintaining a continuous integration environment is quite a bit of work. It requires ongoing resources both in terms of manpower and hardware infrastructure. As an application evolves so does the number of ongoing projects. The challenge is creating a scalable continuous integration environment which does not impede development and can handle the complexities of Java EE testing. This session covers how to setup and configure a cloud-based continuous integration environment for Java EE applications. The presentation will focus on demonstrating how to use Atlassian Bamboo running on AWS to build and test a Maven/Gradle Java EE project that uses Arquillian for testing. Topics that will be covered include creating a custom AWS VM for use with Bamboo, creating an Amazon VPC (Virtual Private Cloud) along with test database using Amazon RDS. The presentation will delve into the specifics of testing EJBs, WebSocket endpoints, RESTful web services, as well as performing load testing in this environment. Security, cost control, and build monitoring will be covered as well.

atlassianjavaaws
Combining R With Java For Data Analysis (Devoxx UK 2015 Session)
Combining R With Java For Data Analysis (Devoxx UK 2015 Session)Combining R With Java For Data Analysis (Devoxx UK 2015 Session)
Combining R With Java For Data Analysis (Devoxx UK 2015 Session)

Java is a general-purpose language and is not particularly well suited for performing statistical analysis. Special languages and software environments have been created by and for statisticians to use. Statisticians think about programming and data analysis much different from Java programmers. These languages and tools make it easy to perform very sophisticated analyses on large data sets easily. Tools, such as R and SAS, contain a large toolbox of statistical tools that are well tested, documented and validated. For data analysis you want to use these tools. In this session we will provide an overview of how to leverage the power of R from Java. R is the leading open source statistical package/language/environment. The first part of the presentation will provide an overview of R focusing on the differences between R and Java at the language level. We’ll also look at some of the basic and more advanced tests to illustrate the power of R. The second half of the presentation will cover how to integrate R and Java using rJava. We’ll look at leverage R from the new Java EE Batching (JSR 352) to provide robust statistical analysis for enterprise applications.

r java javaee
IntelliJ
• Support added in 2017.1 (release March 2017)
• For multi-module project:
1. Start with Empty Project
2. Add new module for each Jigsaw module
• IntelliJ detects when an import requires a module
definition
Demo
BEST PRACTICES
Java 9 Preparation
• Analyze dependencies using jdeps
• Immediately fix code using internal APIs
• Check transitive dependencies for internal JDK APIs
• Integrate jdeps into continuous integration
• Use Maven JDeps Plugin
• Analyze reflection code: setAccessible(true)
• Refactor code to remove duplicate packages across JARs
• common.jar: com.foo.utilities
• Server.jar com.foo.utilitie

Recommended for you

Hybrid Mobile Development with Apache Cordova and
Hybrid Mobile Development with Apache Cordova and Hybrid Mobile Development with Apache Cordova and
Hybrid Mobile Development with Apache Cordova and

Apache Cordova is used to wrap HTML5 applications into native mobile applications that can access device capabilities. A demo application was shown that used Cordova for the mobile portion and Java EE 7 on the server side. Key technologies discussed included Cordova plugins, RESTful web services, Java API for JSON, and Java API for WebSockets for bidirectional communication between the mobile app and server. jQuery Mobile was also mentioned as a potential UI framework.

JavaFX Versus HTML5 - JavaOne 2014
JavaFX Versus HTML5 - JavaOne 2014JavaFX Versus HTML5 - JavaOne 2014
JavaFX Versus HTML5 - JavaOne 2014

This document provides an overview comparison of JavaFX and HTML5 for building mobile applications. It includes a demo of a sailboat racing application built with both JavaFX and HTML5. The technical comparison section analyzes the architectures, controls, data binding, tables, multimedia support and other features of JavaFX and HTML5. It finds that while HTML5 has broader deployment options, JavaFX provides more robust and integrated core features out of the box. The document also discusses the perspectives and limitations of both JavaFX and HTML5.

java ee7apache cordovajava
50 EJB 3 Best Practices in 50 Minutes - JavaOne 2014
50 EJB 3 Best Practices in 50 Minutes - JavaOne 201450 EJB 3 Best Practices in 50 Minutes - JavaOne 2014
50 EJB 3 Best Practices in 50 Minutes - JavaOne 2014

This session provides 50 best practices for EJB 3 in 50 minutes with examples. These best practices involve not only EJB 3.2 but also its integration with other Java EE 7 technologies, not only coding best practices but also testing and production practices. The presentation targets Java EE 7 and also points out where best practices have changed, what patterns you should embrace, and antipatterns to avoid. This is a fast-paced presentation with many code samples. Categories covered include configuration, JPA, concurrency, testing, performance tuning, exception handling, CDI integration, JMS queue patterns, pattern changes, and many more.

javaone 2014ejbjava ee7
Legacy Code
• If using internal JDK API, fix or use flag:
--add-exports, --add-opens, --permit-illegal-access
• If using removed JDK module: (ex. Activation):
--add-modules <module>
Analyze Project Structure
IntelliJ DSM
Analyzer
https://goo.gl/FLzCL7
Remove cycles!
Java EE & Spring
• Support for Jigsaw unknown
• Major effort required for containers to support Jigsaw
• Concerns raised in JCP voting over Jigsaw and EE
• Regardless: Dependencies on JDK internal APIs must be
immediately resolved.
Desktop App Impact
• Impacts of JDK internal dependencies maybe felt more on
Java desktop applications
• Many hacks were required to work around
limitations/bugs in Swing
• Older applications may need to be ported to JavaFX
Technical Debt Bill is NOW DUE.

Recommended for you

Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)
Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)
Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)

Java EE 7 provides a strong foundation for developing the back end for your HTML5 mobile applications. This heavily code-driven session shows you how you can effectively utilize Java EE 7 as a back end for your Apache Cordova mobile applications. The session demonstrates Java EE 7 technologies such as JAX-RS 2.0, WebSocket, JSON-P, CDI, and Bean Validation. It provides an overview of the basics of Apache Cordova as well as the tooling support added in NetBeans 8. The session also demonstrates an integrated approach to rapidly developing HTML5 mobile applications with Java EE 7 and NetBeans and concludes with best practices and pitfalls.

apache cordovajava ee 7javaone 2014
JavaOne 2013: Organizing Your Local Community
JavaOne 2013: Organizing Your Local CommunityJavaOne 2013: Organizing Your Local Community
JavaOne 2013: Organizing Your Local Community

The document provides background information on user groups and describes the history of the CT Java User Group, which the author helped restart in 2002. It discusses how the group was initially dormant but grew over time through regular meetings, connecting with speakers, and acquiring a website and domain names. Lessons learned include that user groups require dedication, investment of time and money, and don't require the leader to be a "Java rockstar." The document provides tips for starting a new user group, including legal and financial considerations, logos, websites, recruitment, scheduling meetings, and selecting meeting topics and venues.

jug sundayjavaone 2012jug
Intro to Amazon Web Services (AWS) and Gen AI
Intro to Amazon Web Services (AWS) and Gen AIIntro to Amazon Web Services (AWS) and Gen AI
Intro to Amazon Web Services (AWS) and Gen AI

Sami provided a beginner-friendly introduction to Amazon Web Services (AWS), covering essential terms, products, and services for cloud deployment. Participants explored AWS' latest Gen AI offerings, making it accessible for those starting their cloud journey or integrating AI into coding practices.

cfmlcoldfusionboxlang
Best Practice
• Don’t depend upon java.se
• Avoid using qualified exports
• Don’t remove exports from a module in future releases
• Keep modules-info clean:
• requires javafx.controls
• requires javafx.base; -- controls already includes base
Resources
• Books
• The Java 9 Module System (https://goo.gl/QM1LS1)
• Java 9 Modularity (https://goo.gl/zJeYsd)
• Links
• Issues: https://goo.gl/xK4ymJ
• Oracle Talks: http://openjdk.java.net/projects/jigsaw/talks/
• Tutorial: https://goo.gl/ET9Hn1
• Tutorial: https://goo.gl/GzPXTw
• Jigsaw vote explanation: https://goo.gl/sWUZvX
Focus on newer Jigsaw material (2016 or later)
Q&A
Twitter: @ctjava
Email: rcuprak@gmail.com / r5k@3ds.com
Blog: cuprak.info
Linkedin: www.linkedin.com/in/rcuprak
Slides: www.slideshare.net/rcuprak/presentations

More Related Content

What's hot

Java EE 8 Update
Java EE 8 UpdateJava EE 8 Update
Java EE 8 Update
Ryan Cuprak
 
Faster Java EE Builds with Gradle
Faster Java EE Builds with GradleFaster Java EE Builds with Gradle
Faster Java EE Builds with Gradle
Ryan Cuprak
 
Scala and Play with Gradle
Scala and Play with GradleScala and Play with Gradle
Scala and Play with Gradle
Wei Chen
 
Spring Framework 3.2 - What's New
Spring Framework 3.2 - What's NewSpring Framework 3.2 - What's New
Spring Framework 3.2 - What's New
Sam Brannen
 
Spring 3.1 to 3.2 in a Nutshell - Spring I/O 2012
Spring 3.1 to 3.2 in a Nutshell - Spring I/O 2012Spring 3.1 to 3.2 in a Nutshell - Spring I/O 2012
Spring 3.1 to 3.2 in a Nutshell - Spring I/O 2012
Sam Brannen
 
Java 9 preview
Java 9 previewJava 9 preview
Java 9 preview
Ivan Krylov
 
Web application development using Play Framework (with Java)
Web application development using Play Framework (with Java)Web application development using Play Framework (with Java)
Web application development using Play Framework (with Java)
Saeed Zarinfam
 
Java 9 Module System Introduction
Java 9 Module System IntroductionJava 9 Module System Introduction
Java 9 Module System Introduction
Dan Stine
 
Play Framework and Activator
Play Framework and ActivatorPlay Framework and Activator
Play Framework and Activator
Kevin Webber
 
Why Play Framework is fast
Why Play Framework is fastWhy Play Framework is fast
Why Play Framework is fast
Legacy Typesafe (now Lightbend)
 
Migrating to Java 9 Modules
Migrating to Java 9 ModulesMigrating to Java 9 Modules
Migrating to Java 9 Modules
Sander Mak (@Sander_Mak)
 
Java(ee) mongo db applications in the cloud
Java(ee) mongo db applications in the cloud Java(ee) mongo db applications in the cloud
Java(ee) mongo db applications in the cloud
Shekhar Gulati
 
Java build tool_comparison
Java build tool_comparisonJava build tool_comparison
Java build tool_comparison
Manav Prasad
 
Introduction tomaven
Introduction tomavenIntroduction tomaven
Introduction tomaven
Manav Prasad
 
Getting Started with Java EE 7
Getting Started with Java EE 7Getting Started with Java EE 7
Getting Started with Java EE 7
Arun Gupta
 
Apache maven and its impact on java 9 (Java One 2017)
Apache maven and its impact on java 9 (Java One 2017)Apache maven and its impact on java 9 (Java One 2017)
Apache maven and its impact on java 9 (Java One 2017)
Robert Scholte
 
Migrating to java 9 modules
Migrating to java 9 modulesMigrating to java 9 modules
Migrating to java 9 modules
Paul Bakker
 
Scala play-framework
Scala play-frameworkScala play-framework
Scala play-framework
Abdhesh Kumar
 
Workshop Framework(J2EE/OSGi/RCP)
Workshop Framework(J2EE/OSGi/RCP)Workshop Framework(J2EE/OSGi/RCP)
Workshop Framework(J2EE/OSGi/RCP)
Summer Lu
 
Preparing your code for Java 9
Preparing your code for Java 9Preparing your code for Java 9
Preparing your code for Java 9
Deepu Xavier
 

What's hot (20)

Java EE 8 Update
Java EE 8 UpdateJava EE 8 Update
Java EE 8 Update
 
Faster Java EE Builds with Gradle
Faster Java EE Builds with GradleFaster Java EE Builds with Gradle
Faster Java EE Builds with Gradle
 
Scala and Play with Gradle
Scala and Play with GradleScala and Play with Gradle
Scala and Play with Gradle
 
Spring Framework 3.2 - What's New
Spring Framework 3.2 - What's NewSpring Framework 3.2 - What's New
Spring Framework 3.2 - What's New
 
Spring 3.1 to 3.2 in a Nutshell - Spring I/O 2012
Spring 3.1 to 3.2 in a Nutshell - Spring I/O 2012Spring 3.1 to 3.2 in a Nutshell - Spring I/O 2012
Spring 3.1 to 3.2 in a Nutshell - Spring I/O 2012
 
Java 9 preview
Java 9 previewJava 9 preview
Java 9 preview
 
Web application development using Play Framework (with Java)
Web application development using Play Framework (with Java)Web application development using Play Framework (with Java)
Web application development using Play Framework (with Java)
 
Java 9 Module System Introduction
Java 9 Module System IntroductionJava 9 Module System Introduction
Java 9 Module System Introduction
 
Play Framework and Activator
Play Framework and ActivatorPlay Framework and Activator
Play Framework and Activator
 
Why Play Framework is fast
Why Play Framework is fastWhy Play Framework is fast
Why Play Framework is fast
 
Migrating to Java 9 Modules
Migrating to Java 9 ModulesMigrating to Java 9 Modules
Migrating to Java 9 Modules
 
Java(ee) mongo db applications in the cloud
Java(ee) mongo db applications in the cloud Java(ee) mongo db applications in the cloud
Java(ee) mongo db applications in the cloud
 
Java build tool_comparison
Java build tool_comparisonJava build tool_comparison
Java build tool_comparison
 
Introduction tomaven
Introduction tomavenIntroduction tomaven
Introduction tomaven
 
Getting Started with Java EE 7
Getting Started with Java EE 7Getting Started with Java EE 7
Getting Started with Java EE 7
 
Apache maven and its impact on java 9 (Java One 2017)
Apache maven and its impact on java 9 (Java One 2017)Apache maven and its impact on java 9 (Java One 2017)
Apache maven and its impact on java 9 (Java One 2017)
 
Migrating to java 9 modules
Migrating to java 9 modulesMigrating to java 9 modules
Migrating to java 9 modules
 
Scala play-framework
Scala play-frameworkScala play-framework
Scala play-framework
 
Workshop Framework(J2EE/OSGi/RCP)
Workshop Framework(J2EE/OSGi/RCP)Workshop Framework(J2EE/OSGi/RCP)
Workshop Framework(J2EE/OSGi/RCP)
 
Preparing your code for Java 9
Preparing your code for Java 9Preparing your code for Java 9
Preparing your code for Java 9
 

Similar to Preparing for java 9 modules upload

Java Platform Module System
Java Platform Module SystemJava Platform Module System
Java Platform Module System
Vignesh Ramesh
 
Modules in Java? Finally! (OpenJDK 9 Jigsaw, JSR376)
Modules in Java? Finally! (OpenJDK 9 Jigsaw, JSR376)Modules in Java? Finally! (OpenJDK 9 Jigsaw, JSR376)
Modules in Java? Finally! (OpenJDK 9 Jigsaw, JSR376)
Mihail Stoynov
 
What we can expect from Java 9 by Ivan Krylov
What we can expect from Java 9 by Ivan KrylovWhat we can expect from Java 9 by Ivan Krylov
What we can expect from Java 9 by Ivan Krylov
J On The Beach
 
Java 9 and the impact on Maven Projects (JavaOne 2016)
Java 9 and the impact on Maven Projects (JavaOne 2016)Java 9 and the impact on Maven Projects (JavaOne 2016)
Java 9 and the impact on Maven Projects (JavaOne 2016)
Robert Scholte
 
Java9 and the impact on Maven Projects (JFall 2016)
Java9 and the impact on Maven Projects (JFall 2016)Java9 and the impact on Maven Projects (JFall 2016)
Java9 and the impact on Maven Projects (JFall 2016)
Robert Scholte
 
Java 9, JShell, and Modularity
Java 9, JShell, and ModularityJava 9, JShell, and Modularity
Java 9, JShell, and Modularity
Mohammad Hossein Rimaz
 
Java modules
Java modulesJava modules
Java modules
Rory Preddy
 
Java 9 and the impact on Maven Projects (ApacheCon Europe 2016)
Java 9 and the impact on Maven Projects (ApacheCon Europe 2016)Java 9 and the impact on Maven Projects (ApacheCon Europe 2016)
Java 9 and the impact on Maven Projects (ApacheCon Europe 2016)
Robert Scholte
 
S/W Design and Modularity using Maven
S/W Design and Modularity using MavenS/W Design and Modularity using Maven
S/W Design and Modularity using Maven
Scheidt & Bachmann
 
As7 jbug j_boss_modules_yang yong
As7 jbug j_boss_modules_yang yongAs7 jbug j_boss_modules_yang yong
As7 jbug j_boss_modules_yang yong
jbossug
 
Java 9 / Jigsaw - AJUG/VJUG session
Java 9 / Jigsaw - AJUG/VJUG  sessionJava 9 / Jigsaw - AJUG/VJUG  session
Java 9 / Jigsaw - AJUG/VJUG session
Mani Sarkar
 
OOP with Java
OOP with JavaOOP with Java
OOP with Java
OmegaHub
 
Modern Java Workshop
Modern Java WorkshopModern Java Workshop
Modern Java Workshop
Simon Ritter
 
An overview of Scalable Web Application Front-end
An overview of Scalable Web Application Front-endAn overview of Scalable Web Application Front-end
An overview of Scalable Web Application Front-end
Saeid Zebardast
 
Apache Maven supports all Java (JokerConf 2018)
Apache Maven supports all Java (JokerConf 2018)Apache Maven supports all Java (JokerConf 2018)
Apache Maven supports all Java (JokerConf 2018)
Robert Scholte
 
JavaOne 2016: Life after Modularity
JavaOne 2016: Life after ModularityJavaOne 2016: Life after Modularity
JavaOne 2016: Life after Modularity
DanHeidinga
 
OpenJDK Penrose Presentation (JavaOne 2012)
OpenJDK Penrose Presentation (JavaOne 2012)OpenJDK Penrose Presentation (JavaOne 2012)
OpenJDK Penrose Presentation (JavaOne 2012)
David Bosschaert
 
Java Core | Java 8 and OSGi Modularisation | Tim Ellison & Neil Bartlett
Java Core | Java 8 and OSGi Modularisation | Tim Ellison & Neil BartlettJava Core | Java 8 and OSGi Modularisation | Tim Ellison & Neil Bartlett
Java Core | Java 8 and OSGi Modularisation | Tim Ellison & Neil Bartlett
JAX London
 
Jax london 2011
Jax london 2011Jax london 2011
Jax london 2011
njbartlett
 
Leaner microservices with Java 10
Leaner microservices with Java 10Leaner microservices with Java 10
Leaner microservices with Java 10
Arto Santala
 

Similar to Preparing for java 9 modules upload (20)

Java Platform Module System
Java Platform Module SystemJava Platform Module System
Java Platform Module System
 
Modules in Java? Finally! (OpenJDK 9 Jigsaw, JSR376)
Modules in Java? Finally! (OpenJDK 9 Jigsaw, JSR376)Modules in Java? Finally! (OpenJDK 9 Jigsaw, JSR376)
Modules in Java? Finally! (OpenJDK 9 Jigsaw, JSR376)
 
What we can expect from Java 9 by Ivan Krylov
What we can expect from Java 9 by Ivan KrylovWhat we can expect from Java 9 by Ivan Krylov
What we can expect from Java 9 by Ivan Krylov
 
Java 9 and the impact on Maven Projects (JavaOne 2016)
Java 9 and the impact on Maven Projects (JavaOne 2016)Java 9 and the impact on Maven Projects (JavaOne 2016)
Java 9 and the impact on Maven Projects (JavaOne 2016)
 
Java9 and the impact on Maven Projects (JFall 2016)
Java9 and the impact on Maven Projects (JFall 2016)Java9 and the impact on Maven Projects (JFall 2016)
Java9 and the impact on Maven Projects (JFall 2016)
 
Java 9, JShell, and Modularity
Java 9, JShell, and ModularityJava 9, JShell, and Modularity
Java 9, JShell, and Modularity
 
Java modules
Java modulesJava modules
Java modules
 
Java 9 and the impact on Maven Projects (ApacheCon Europe 2016)
Java 9 and the impact on Maven Projects (ApacheCon Europe 2016)Java 9 and the impact on Maven Projects (ApacheCon Europe 2016)
Java 9 and the impact on Maven Projects (ApacheCon Europe 2016)
 
S/W Design and Modularity using Maven
S/W Design and Modularity using MavenS/W Design and Modularity using Maven
S/W Design and Modularity using Maven
 
As7 jbug j_boss_modules_yang yong
As7 jbug j_boss_modules_yang yongAs7 jbug j_boss_modules_yang yong
As7 jbug j_boss_modules_yang yong
 
Java 9 / Jigsaw - AJUG/VJUG session
Java 9 / Jigsaw - AJUG/VJUG  sessionJava 9 / Jigsaw - AJUG/VJUG  session
Java 9 / Jigsaw - AJUG/VJUG session
 
OOP with Java
OOP with JavaOOP with Java
OOP with Java
 
Modern Java Workshop
Modern Java WorkshopModern Java Workshop
Modern Java Workshop
 
An overview of Scalable Web Application Front-end
An overview of Scalable Web Application Front-endAn overview of Scalable Web Application Front-end
An overview of Scalable Web Application Front-end
 
Apache Maven supports all Java (JokerConf 2018)
Apache Maven supports all Java (JokerConf 2018)Apache Maven supports all Java (JokerConf 2018)
Apache Maven supports all Java (JokerConf 2018)
 
JavaOne 2016: Life after Modularity
JavaOne 2016: Life after ModularityJavaOne 2016: Life after Modularity
JavaOne 2016: Life after Modularity
 
OpenJDK Penrose Presentation (JavaOne 2012)
OpenJDK Penrose Presentation (JavaOne 2012)OpenJDK Penrose Presentation (JavaOne 2012)
OpenJDK Penrose Presentation (JavaOne 2012)
 
Java Core | Java 8 and OSGi Modularisation | Tim Ellison & Neil Bartlett
Java Core | Java 8 and OSGi Modularisation | Tim Ellison & Neil BartlettJava Core | Java 8 and OSGi Modularisation | Tim Ellison & Neil Bartlett
Java Core | Java 8 and OSGi Modularisation | Tim Ellison & Neil Bartlett
 
Jax london 2011
Jax london 2011Jax london 2011
Jax london 2011
 
Leaner microservices with Java 10
Leaner microservices with Java 10Leaner microservices with Java 10
Leaner microservices with Java 10
 

More from Ryan Cuprak

Jakarta EE Test Strategies (2022)
Jakarta EE Test Strategies (2022)Jakarta EE Test Strategies (2022)
Jakarta EE Test Strategies (2022)
Ryan Cuprak
 
DIY Home Weather Station (Devoxx Poland 2023)
DIY Home Weather Station (Devoxx Poland 2023)DIY Home Weather Station (Devoxx Poland 2023)
DIY Home Weather Station (Devoxx Poland 2023)
Ryan Cuprak
 
Containerless in the Cloud with AWS Lambda
Containerless in the Cloud with AWS LambdaContainerless in the Cloud with AWS Lambda
Containerless in the Cloud with AWS Lambda
Ryan Cuprak
 
Java script nirvana in netbeans [con5679]
Java script nirvana in netbeans [con5679]Java script nirvana in netbeans [con5679]
Java script nirvana in netbeans [con5679]
Ryan Cuprak
 
Jms deep dive [con4864]
Jms deep dive [con4864]Jms deep dive [con4864]
Jms deep dive [con4864]
Ryan Cuprak
 
Top 50 java ee 7 best practices [con5669]
Top 50 java ee 7 best practices [con5669]Top 50 java ee 7 best practices [con5669]
Top 50 java ee 7 best practices [con5669]
Ryan Cuprak
 
Developing in the Cloud
Developing in the CloudDeveloping in the Cloud
Developing in the Cloud
Ryan Cuprak
 
Combining R With Java For Data Analysis (Devoxx UK 2015 Session)
Combining R With Java For Data Analysis (Devoxx UK 2015 Session)Combining R With Java For Data Analysis (Devoxx UK 2015 Session)
Combining R With Java For Data Analysis (Devoxx UK 2015 Session)
Ryan Cuprak
 
Hybrid Mobile Development with Apache Cordova and
Hybrid Mobile Development with Apache Cordova and Hybrid Mobile Development with Apache Cordova and
Hybrid Mobile Development with Apache Cordova and
Ryan Cuprak
 
JavaFX Versus HTML5 - JavaOne 2014
JavaFX Versus HTML5 - JavaOne 2014JavaFX Versus HTML5 - JavaOne 2014
JavaFX Versus HTML5 - JavaOne 2014
Ryan Cuprak
 
50 EJB 3 Best Practices in 50 Minutes - JavaOne 2014
50 EJB 3 Best Practices in 50 Minutes - JavaOne 201450 EJB 3 Best Practices in 50 Minutes - JavaOne 2014
50 EJB 3 Best Practices in 50 Minutes - JavaOne 2014
Ryan Cuprak
 
Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)
Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)
Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)
Ryan Cuprak
 
JavaOne 2013: Organizing Your Local Community
JavaOne 2013: Organizing Your Local CommunityJavaOne 2013: Organizing Your Local Community
JavaOne 2013: Organizing Your Local Community
Ryan Cuprak
 

More from Ryan Cuprak (13)

Jakarta EE Test Strategies (2022)
Jakarta EE Test Strategies (2022)Jakarta EE Test Strategies (2022)
Jakarta EE Test Strategies (2022)
 
DIY Home Weather Station (Devoxx Poland 2023)
DIY Home Weather Station (Devoxx Poland 2023)DIY Home Weather Station (Devoxx Poland 2023)
DIY Home Weather Station (Devoxx Poland 2023)
 
Containerless in the Cloud with AWS Lambda
Containerless in the Cloud with AWS LambdaContainerless in the Cloud with AWS Lambda
Containerless in the Cloud with AWS Lambda
 
Java script nirvana in netbeans [con5679]
Java script nirvana in netbeans [con5679]Java script nirvana in netbeans [con5679]
Java script nirvana in netbeans [con5679]
 
Jms deep dive [con4864]
Jms deep dive [con4864]Jms deep dive [con4864]
Jms deep dive [con4864]
 
Top 50 java ee 7 best practices [con5669]
Top 50 java ee 7 best practices [con5669]Top 50 java ee 7 best practices [con5669]
Top 50 java ee 7 best practices [con5669]
 
Developing in the Cloud
Developing in the CloudDeveloping in the Cloud
Developing in the Cloud
 
Combining R With Java For Data Analysis (Devoxx UK 2015 Session)
Combining R With Java For Data Analysis (Devoxx UK 2015 Session)Combining R With Java For Data Analysis (Devoxx UK 2015 Session)
Combining R With Java For Data Analysis (Devoxx UK 2015 Session)
 
Hybrid Mobile Development with Apache Cordova and
Hybrid Mobile Development with Apache Cordova and Hybrid Mobile Development with Apache Cordova and
Hybrid Mobile Development with Apache Cordova and
 
JavaFX Versus HTML5 - JavaOne 2014
JavaFX Versus HTML5 - JavaOne 2014JavaFX Versus HTML5 - JavaOne 2014
JavaFX Versus HTML5 - JavaOne 2014
 
50 EJB 3 Best Practices in 50 Minutes - JavaOne 2014
50 EJB 3 Best Practices in 50 Minutes - JavaOne 201450 EJB 3 Best Practices in 50 Minutes - JavaOne 2014
50 EJB 3 Best Practices in 50 Minutes - JavaOne 2014
 
Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)
Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)
Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)
 
JavaOne 2013: Organizing Your Local Community
JavaOne 2013: Organizing Your Local CommunityJavaOne 2013: Organizing Your Local Community
JavaOne 2013: Organizing Your Local Community
 

Recently uploaded

Intro to Amazon Web Services (AWS) and Gen AI
Intro to Amazon Web Services (AWS) and Gen AIIntro to Amazon Web Services (AWS) and Gen AI
Intro to Amazon Web Services (AWS) and Gen AI
Ortus Solutions, Corp
 
Wired_2.0_Create_AmsterdamJUG_09072024.pptx
Wired_2.0_Create_AmsterdamJUG_09072024.pptxWired_2.0_Create_AmsterdamJUG_09072024.pptx
Wired_2.0_Create_AmsterdamJUG_09072024.pptx
SimonedeGijt
 
COMPSAC 2024 D&I Panel: Charting a Course for Equity: Strategies for Overcomi...
COMPSAC 2024 D&I Panel: Charting a Course for Equity: Strategies for Overcomi...COMPSAC 2024 D&I Panel: Charting a Course for Equity: Strategies for Overcomi...
COMPSAC 2024 D&I Panel: Charting a Course for Equity: Strategies for Overcomi...
Hironori Washizaki
 
一比一原版英国牛津大学毕业证(oxon毕业证书)如何办理
一比一原版英国牛津大学毕业证(oxon毕业证书)如何办理一比一原版英国牛津大学毕业证(oxon毕业证书)如何办理
一比一原版英国牛津大学毕业证(oxon毕业证书)如何办理
avufu
 
Safe Work Permit Management Software for Hot Work Permits
Safe Work Permit Management Software for Hot Work PermitsSafe Work Permit Management Software for Hot Work Permits
Safe Work Permit Management Software for Hot Work Permits
sheqnetworkmarketing
 
Seamless PostgreSQL to Snowflake Data Transfer in 8 Simple Steps
Seamless PostgreSQL to Snowflake Data Transfer in 8 Simple StepsSeamless PostgreSQL to Snowflake Data Transfer in 8 Simple Steps
Seamless PostgreSQL to Snowflake Data Transfer in 8 Simple Steps
Estuary Flow
 
dachnug51 - HCL Sametime 12 as a Software Appliance.pdf
dachnug51 - HCL Sametime 12 as a Software Appliance.pdfdachnug51 - HCL Sametime 12 as a Software Appliance.pdf
dachnug51 - HCL Sametime 12 as a Software Appliance.pdf
DNUG e.V.
 
BITCOIN HEIST RANSOMEWARE ATTACK PREDICTION
BITCOIN HEIST RANSOMEWARE ATTACK PREDICTIONBITCOIN HEIST RANSOMEWARE ATTACK PREDICTION
BITCOIN HEIST RANSOMEWARE ATTACK PREDICTION
ssuser2b426d1
 
Addressing the Top 9 User Pain Points with Visual Design Elements.pptx
Addressing the Top 9 User Pain Points with Visual Design Elements.pptxAddressing the Top 9 User Pain Points with Visual Design Elements.pptx
Addressing the Top 9 User Pain Points with Visual Design Elements.pptx
Sparity1
 
ANSYS Mechanical APDL Introductory Tutorials.pdf
ANSYS Mechanical APDL Introductory Tutorials.pdfANSYS Mechanical APDL Introductory Tutorials.pdf
ANSYS Mechanical APDL Introductory Tutorials.pdf
sachin chaurasia
 
ThaiPy meetup - Indexes and Django
ThaiPy meetup - Indexes and DjangoThaiPy meetup - Indexes and Django
ThaiPy meetup - Indexes and Django
akshesh doshi
 
Migrate your Infrastructure to the AWS Cloud
Migrate your Infrastructure to the AWS CloudMigrate your Infrastructure to the AWS Cloud
Migrate your Infrastructure to the AWS Cloud
Ortus Solutions, Corp
 
Overview of ERP - Mechlin Technologies.pptx
Overview of ERP - Mechlin Technologies.pptxOverview of ERP - Mechlin Technologies.pptx
Overview of ERP - Mechlin Technologies.pptx
Mitchell Marsh
 
Discover the Power of ONEMONITAR: The Ultimate Mobile Spy App for Android Dev...
Discover the Power of ONEMONITAR: The Ultimate Mobile Spy App for Android Dev...Discover the Power of ONEMONITAR: The Ultimate Mobile Spy App for Android Dev...
Discover the Power of ONEMONITAR: The Ultimate Mobile Spy App for Android Dev...
onemonitarsoftware
 
introduction of Ansys software and basic and advance knowledge of modelling s...
introduction of Ansys software and basic and advance knowledge of modelling s...introduction of Ansys software and basic and advance knowledge of modelling s...
introduction of Ansys software and basic and advance knowledge of modelling s...
sachin chaurasia
 
AWS Cloud Practitioner Essentials (Second Edition) (Arabic) AWS Security .pdf
AWS Cloud Practitioner Essentials (Second Edition) (Arabic) AWS Security .pdfAWS Cloud Practitioner Essentials (Second Edition) (Arabic) AWS Security .pdf
AWS Cloud Practitioner Essentials (Second Edition) (Arabic) AWS Security .pdf
karim wahed
 
React Native vs Flutter - SSTech System
React Native vs Flutter  - SSTech SystemReact Native vs Flutter  - SSTech System
React Native vs Flutter - SSTech System
SSTech System
 
What is OCR Technology and How to Extract Text from Any Image for Free
What is OCR Technology and How to Extract Text from Any Image for FreeWhat is OCR Technology and How to Extract Text from Any Image for Free
What is OCR Technology and How to Extract Text from Any Image for Free
TwisterTools
 
NBFC Software: Optimize Your Non-Banking Financial Company
NBFC Software: Optimize Your Non-Banking Financial CompanyNBFC Software: Optimize Your Non-Banking Financial Company
NBFC Software: Optimize Your Non-Banking Financial Company
NBFC Softwares
 
Development of Chatbot Using AI\ML Technologies
Development of Chatbot Using AI\ML TechnologiesDevelopment of Chatbot Using AI\ML Technologies
Development of Chatbot Using AI\ML Technologies
MaisnamLuwangPibarel
 

Recently uploaded (20)

Intro to Amazon Web Services (AWS) and Gen AI
Intro to Amazon Web Services (AWS) and Gen AIIntro to Amazon Web Services (AWS) and Gen AI
Intro to Amazon Web Services (AWS) and Gen AI
 
Wired_2.0_Create_AmsterdamJUG_09072024.pptx
Wired_2.0_Create_AmsterdamJUG_09072024.pptxWired_2.0_Create_AmsterdamJUG_09072024.pptx
Wired_2.0_Create_AmsterdamJUG_09072024.pptx
 
COMPSAC 2024 D&I Panel: Charting a Course for Equity: Strategies for Overcomi...
COMPSAC 2024 D&I Panel: Charting a Course for Equity: Strategies for Overcomi...COMPSAC 2024 D&I Panel: Charting a Course for Equity: Strategies for Overcomi...
COMPSAC 2024 D&I Panel: Charting a Course for Equity: Strategies for Overcomi...
 
一比一原版英国牛津大学毕业证(oxon毕业证书)如何办理
一比一原版英国牛津大学毕业证(oxon毕业证书)如何办理一比一原版英国牛津大学毕业证(oxon毕业证书)如何办理
一比一原版英国牛津大学毕业证(oxon毕业证书)如何办理
 
Safe Work Permit Management Software for Hot Work Permits
Safe Work Permit Management Software for Hot Work PermitsSafe Work Permit Management Software for Hot Work Permits
Safe Work Permit Management Software for Hot Work Permits
 
Seamless PostgreSQL to Snowflake Data Transfer in 8 Simple Steps
Seamless PostgreSQL to Snowflake Data Transfer in 8 Simple StepsSeamless PostgreSQL to Snowflake Data Transfer in 8 Simple Steps
Seamless PostgreSQL to Snowflake Data Transfer in 8 Simple Steps
 
dachnug51 - HCL Sametime 12 as a Software Appliance.pdf
dachnug51 - HCL Sametime 12 as a Software Appliance.pdfdachnug51 - HCL Sametime 12 as a Software Appliance.pdf
dachnug51 - HCL Sametime 12 as a Software Appliance.pdf
 
BITCOIN HEIST RANSOMEWARE ATTACK PREDICTION
BITCOIN HEIST RANSOMEWARE ATTACK PREDICTIONBITCOIN HEIST RANSOMEWARE ATTACK PREDICTION
BITCOIN HEIST RANSOMEWARE ATTACK PREDICTION
 
Addressing the Top 9 User Pain Points with Visual Design Elements.pptx
Addressing the Top 9 User Pain Points with Visual Design Elements.pptxAddressing the Top 9 User Pain Points with Visual Design Elements.pptx
Addressing the Top 9 User Pain Points with Visual Design Elements.pptx
 
ANSYS Mechanical APDL Introductory Tutorials.pdf
ANSYS Mechanical APDL Introductory Tutorials.pdfANSYS Mechanical APDL Introductory Tutorials.pdf
ANSYS Mechanical APDL Introductory Tutorials.pdf
 
ThaiPy meetup - Indexes and Django
ThaiPy meetup - Indexes and DjangoThaiPy meetup - Indexes and Django
ThaiPy meetup - Indexes and Django
 
Migrate your Infrastructure to the AWS Cloud
Migrate your Infrastructure to the AWS CloudMigrate your Infrastructure to the AWS Cloud
Migrate your Infrastructure to the AWS Cloud
 
Overview of ERP - Mechlin Technologies.pptx
Overview of ERP - Mechlin Technologies.pptxOverview of ERP - Mechlin Technologies.pptx
Overview of ERP - Mechlin Technologies.pptx
 
Discover the Power of ONEMONITAR: The Ultimate Mobile Spy App for Android Dev...
Discover the Power of ONEMONITAR: The Ultimate Mobile Spy App for Android Dev...Discover the Power of ONEMONITAR: The Ultimate Mobile Spy App for Android Dev...
Discover the Power of ONEMONITAR: The Ultimate Mobile Spy App for Android Dev...
 
introduction of Ansys software and basic and advance knowledge of modelling s...
introduction of Ansys software and basic and advance knowledge of modelling s...introduction of Ansys software and basic and advance knowledge of modelling s...
introduction of Ansys software and basic and advance knowledge of modelling s...
 
AWS Cloud Practitioner Essentials (Second Edition) (Arabic) AWS Security .pdf
AWS Cloud Practitioner Essentials (Second Edition) (Arabic) AWS Security .pdfAWS Cloud Practitioner Essentials (Second Edition) (Arabic) AWS Security .pdf
AWS Cloud Practitioner Essentials (Second Edition) (Arabic) AWS Security .pdf
 
React Native vs Flutter - SSTech System
React Native vs Flutter  - SSTech SystemReact Native vs Flutter  - SSTech System
React Native vs Flutter - SSTech System
 
What is OCR Technology and How to Extract Text from Any Image for Free
What is OCR Technology and How to Extract Text from Any Image for FreeWhat is OCR Technology and How to Extract Text from Any Image for Free
What is OCR Technology and How to Extract Text from Any Image for Free
 
NBFC Software: Optimize Your Non-Banking Financial Company
NBFC Software: Optimize Your Non-Banking Financial CompanyNBFC Software: Optimize Your Non-Banking Financial Company
NBFC Software: Optimize Your Non-Banking Financial Company
 
Development of Chatbot Using AI\ML Technologies
Development of Chatbot Using AI\ML TechnologiesDevelopment of Chatbot Using AI\ML Technologies
Development of Chatbot Using AI\ML Technologies
 

Preparing for java 9 modules upload

  • 1. Preparing for Java 9 Modules Ryan Cuprak
  • 2. About Twitter: @ctjava Email: rcuprak@gmail.com / r5k@3ds.com Blog: cuprak.info Linkedin: www.linkedin.com/in/rcuprak
  • 3. Project Jigsaw Goals • Make the Java platform scalable for small computing devices. • Improve platform security and maintainability • Enable improved application performance • Simplify library creation and application development Reliable configuration Strong Encapsulation
  • 4. Why Modules? • Java currently suffers from JAR ”hell” • Maven tracks dependencies but no runtime enforcement • No guarantee an application can start: NoClassDefFoundError • Possible to mix library versions on classpath: • commons-io-2.5 and commons-io-1.6 – what happens? • Existing module frameworks (OSGi) can’t be used to modularize the Java platform.
  • 5. Project Jigsaw Pieces • JEPs • 200: Modular JDK • 201: Modular Source Code • 220: Modular Run-time Images • 260: Encapsulate Most Internal APIs • 261: Module System • 282: jlink: Java Linker • JSR 376 Java Platform Module System
  • 6. Project Jigsaw • Target Release Date: July 27th now September 21st 2017 You now have time!
  • 7. Comparing Jigsaw / OSGi / Java EE Feature Jigsaw OSGi Java EE Allows cycles between packages in different modules ❌ ✅ ✅ Isolated package namespaces ❌ ✅ ✅ Allows lazy loading ❌ ✅ ✅ Allows dynamic package addition ❌ ✅ ✅ Unrestricted naming ❌ ❌ ✅ Allows multiple versions of an artifact* ❌ ✅ ✅ Allows split packages ❌ ✅ ✅ Allows textual descriptor ❌ ✅ ✅ Source: https://goo.gl/7RKqQx
  • 8. Class Loading & Module System Bootstrap Loader Platform Loader Application Loader Java Platform Module System Java Virtual Machine java.base java.logging java.sql java.corba jdk.compiler log4j
  • 9. Common Questions • Do I have to modularize my application to run on Java 9? • Will my Java 6/7/8 application compile on Java 9? • Will my Java 6/7/8 application run un-modified on Java 9? • How do I identify problems today? - NO - - Depends – using private APIs? - - Depends – using private APIs? - - jdeps -
  • 10. Common Questions… • Can I partially leverage modules? • Is tooling ready? (Maven/Gradle/IntelliJ/NetBeans/etc.) • Do application containers work on 9 today? • Can I try out Java 9 today? - YES - - Absolutely NOT - - Maybe - - YES -
  • 11. JEP 200: Modular JDK JDK is fully modularized!
  • 12. jdeps • Command line tool included with Java 8 • Static class dependency checker • Key parameters • -jdkinternals – flags internal API usage that will break in Java 9 • -dotoutput <dir> - dot output files • -cp – classpath to analyze • -verbose:class/package – package/class level dependencies • Use jdeps on all generated output and dependencies
  • 13. jdeps – Example jdeps -jdkinternals jide-common.jar jide-common.jar -> /Library/Java/JavaVirtualMachines/jdk1.8.0_121.jdk/Contents/Home/jre/lib/rt.jar com.jidesoft.plaf.aqua.AquaJidePopupMenuUI (jide-common.jar) -> com.apple.laf.AquaPopupMenuUI JDK internal API (rt.jar) com.jidesoft.plaf.aqua.AquaRangeSliderUI (jide-common.jar) -> apple.laf.JRSUIConstants JDK internal API (rt.jar) -> apple.laf.JRSUIConstants$Orientation JDK internal API (rt.jar) -> apple.laf.JRSUIConstants$State JDK internal API (rt.jar) -> com.apple.laf.AquaSliderUI JDK internal API (rt.jar) com.jidesoft.plaf.basic.BasicFolderChooserUI (jide-common.jar) -> sun.awt.shell.ShellFolder JDK internal API (rt.jar) com.jidesoft.plaf.basic.BasicPainter (jide-common.jar) -> sun.swing.plaf.synth.SynthIcon JDK internal API (rt.jar) com.jidesoft.plaf.metal.MetalUtils$GradientPainter (jide-common.jar) -> sun.swing.CachedPainter JDK internal API (rt.jar) com.jidesoft.plaf.windows.AnimationController (jide-common.jar) -> sun.awt.AppContext JDK internal API (rt.jar) -> sun.security.action.GetBooleanAction JDK internal API (rt.jar) … JIDE: Widely used Swing component library (jidesoft.com)
  • 15. jdeps: Build Integration Maven JDeps Plugin: https://goo.gl/thr88W Goals: • jdeps:jdkinternals • jdeps:test-jdkinternals
  • 17. Java Visibility Today How do you hide the implementation class?
  • 18. Java Accessibility JDK 1-8 JDK 9+ public public protected public to specific modules <package> public only within a module private protected <package> private
  • 19. Module Definition • module-info.java defines a module • Contents define the following: • Unique name of the module • Dependencies of the module • Packages to be exported for use by other modules • Placed at root of the namespace Module Name exports requires
  • 20. Module Definition <open> module <module-name> { [export <java package> [to <module name>] [requires [transitive] <module-name>] [opens <module name> [to <module name]] [provides <interface> with <implementation>] [uses <interface>] }
  • 21. Module Basics • Module names must be unique • Names should follow reverse domain name pattern • Modules are eagerly loaded • Dependency graph is built and checked on startup • Application won’t start if modules are missing • No support for versioning • Only one version of a module may be loaded • Layers maybe used to load different versions of a module
  • 22. About Versioning… • Two modules with the same package names in them are considered to be different versions of the same module. • Two modules with the same name are considered to be two versions of the same module. • Concealed package conflicts: • When two modules have the same package name in them, but the package is private in both modules, the module system cannot load both modules into the same layer
  • 23. Introducing the Module Path • Module path augments / extends the classpath • All command line tools now include both --module-path --upgrade-module-path --add-modules --describe-module --dry-run --validate-modules • Use java –list-modules to see all available modules Parameters on java command
  • 24. JDK Modules • jdk.base is included by default. • java.se and java.se.ee are aggregator modules • java.se.ee contains the following modules: • java.corba • java.transaction • java.xml.ws.annotation • javax.xml.ws • java.xml.bind • java.activation • java runs with java.se modules – not java.se.ee
  • 27. Simple Module Example javac -d out src/org/ctjava/services/MeetingService.java src/org/ctjava/services/impl/MeetingServiceImpl.java src/module-info.java Cannot use reflection to find MeetingServiceImpl
  • 28. Simple Module Example… Compiler Output: Module Definition
  • 30. Compiling javac -d out --module-source-path src $(find . -name "*.java") Module Module Directory containing module uses module name. Names must match or compiler error.
  • 31. Packaging jar --create --file=org.ctjava.model@1.0.jar --module-version=1.0 -C out/org.ctjava.model . jar --create --file=org.ctjava.service@1.0.jar --module-version=1.0 -C out/org.ctjava.service . Note: Module version isn’t used for module resolution. It is recorded in module-info.class.
  • 35. Qualified Exports… Exception in thread "main" java.lang.reflect.InvocationTargetException at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:564) at java.base/sun.launcher.LauncherHelper$FXHelper.main(LauncherHelper.java:946) Caused by: java.lang.RuntimeException: Unable to construct Application instance: class org.ctjava.admin.AdminConsole at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:963) at javafx.graphics/com.sun.javafx.application.LauncherImpl.lambda$launchApplication$2(LauncherImpl.java:198) at java.base/java.lang.Thread.run(Thread.java:844) Caused by: java.lang.IllegalAccessException: class com.sun.javafx.application.LauncherImpl (in module javafx.graphics) cannot access class org.ctjava.admin.AdminConsole (in module org.ctjava.admin) because module org.ctjava.admin does not export org.ctjava.admin to module javafx.graphics • JavaFX LauncherImpl cannot access AdminConsole • Class in javafx.graphics tried to instantiate AdminConsole in org.ctjava.admin
  • 37. jlink • Generates a runtime-image including the JVM. • Only required modules are included • Basic invocation: jlink --module-path <modulepath> --add-modules <modules> --limit-modules <modules> --output <path> Demo used JavaFX: 95 mb Full JDK: 454 mb
  • 40. Deprecated Modules… java -jar WebEndpointTest.jar Worked on Java 8 – what happened? Fix: java --add-modules java.xml.ws -jar WebEndpointTest.jar
  • 41. Module Types Automatic Modules • Mechanism for using JARs which do not include a module-info.java configuration • Export all of the JAR packages • Reads all other modules • Module name is dynamically generated Unamed Module • Alls JARs and classes on the classpath will be contained un the Unamed Module. • Similar to Automatic Modules • Does not possess a name Platform Modules • JDK modules
  • 42. JARs & Module System --module-path -classpath Modular JAR Application Module Unnamed Module Non-modular JAR Automatic Module Unnamed Module Unnamed module name: ALL-UNNAMED
  • 43. Readability Module Type Origin Export Packages Read Modules Named Platform Provided by platform Explicitly Named Application All JARS containing module-info on the module path Explicitly • Platform • Application • Automatic Automatic All JARs without module- info but on module path All • Platform • Application • Automatic • Unnamed Unnamed Classpath All • Platform • Automatic • Application
  • 45. Automatic Modules… Code in MyInvocationLibrary: Code in org.ctjava.admin – module:
  • 46. Automatic Modules… java.lang.IllegalAccessException: class org.ctjava.util.InstantiateUtility (in module MyInvocationLibrary) cannot access class org.ctjava.admin.AdminCallback (in module org.ctjava.admin) because module org.ctjava.admin does not export org.ctjava.admin to module MyInvocationLibrary
  • 47. Escape & Encapsulation Kill Switch Important javac command line options: --add-opens – opens a package --permit-illegal-access - All code in the unnamed module can access other types regardless of any limitations. Will result in a WARNING: to be removed in Java 10.
  • 49. Services • API first added in Java 6 • Rarely used outside of JDK • Enhanced/altered for Jigsaw
  • 54. JAVA 9 TOOLING June 2017 Status
  • 55. Tooling Support • Early access JDK 9 builds: http://jdk.java.net/9/ • Use jenv to swich between Java 8 & 9 http://www.jenv.io/ Examples: jenv local 9-ea (locally switch to Java 9) jevn global 1.8 (globally use Java 8) Note: rt.jar and tools.jar were removed.
  • 56. Tooling Support Tool Status NetBeans 9 🔶 Developer Preview IntelliJ 2017.1 ✅ Eclipse 🔶 Maven ❌ Gradle ❌ • Maven & Gradle do not generate module-info.java. • Gradle 3.4 doesn’t work on Java 9 • Maven 3.5 doesn’t completely work (not all plugins compatible) • Eclipse Neon won’t start with Java 9 edit ini file.
  • 58. Maven • Maven Shade Plugin and Jigsaw don’t mix (uber jar) • Example project with Maven and Java 9/Jigsaw: • https://goo.gl/rmzKBa
  • 59. NetBeans & Java 9 • NetBeans Developer Preview required for Java 9. • New project template for modular projects. • Creates Ant build files
  • 60. NetBeans & Java 9 • Module structure not compatible with javac: • <module>/classes/<source code> • Detects imports where the module is not imported. • Does not auto-import yet.
  • 61. IntelliJ • Support added in 2017.1 (release March 2017) • For multi-module project: 1. Start with Empty Project 2. Add new module for each Jigsaw module • IntelliJ detects when an import requires a module definition
  • 62. Demo
  • 64. Java 9 Preparation • Analyze dependencies using jdeps • Immediately fix code using internal APIs • Check transitive dependencies for internal JDK APIs • Integrate jdeps into continuous integration • Use Maven JDeps Plugin • Analyze reflection code: setAccessible(true) • Refactor code to remove duplicate packages across JARs • common.jar: com.foo.utilities • Server.jar com.foo.utilitie
  • 65. Legacy Code • If using internal JDK API, fix or use flag: --add-exports, --add-opens, --permit-illegal-access • If using removed JDK module: (ex. Activation): --add-modules <module>
  • 66. Analyze Project Structure IntelliJ DSM Analyzer https://goo.gl/FLzCL7 Remove cycles!
  • 67. Java EE & Spring • Support for Jigsaw unknown • Major effort required for containers to support Jigsaw • Concerns raised in JCP voting over Jigsaw and EE • Regardless: Dependencies on JDK internal APIs must be immediately resolved.
  • 68. Desktop App Impact • Impacts of JDK internal dependencies maybe felt more on Java desktop applications • Many hacks were required to work around limitations/bugs in Swing • Older applications may need to be ported to JavaFX Technical Debt Bill is NOW DUE.
  • 69. Best Practice • Don’t depend upon java.se • Avoid using qualified exports • Don’t remove exports from a module in future releases • Keep modules-info clean: • requires javafx.controls • requires javafx.base; -- controls already includes base
  • 70. Resources • Books • The Java 9 Module System (https://goo.gl/QM1LS1) • Java 9 Modularity (https://goo.gl/zJeYsd) • Links • Issues: https://goo.gl/xK4ymJ • Oracle Talks: http://openjdk.java.net/projects/jigsaw/talks/ • Tutorial: https://goo.gl/ET9Hn1 • Tutorial: https://goo.gl/GzPXTw • Jigsaw vote explanation: https://goo.gl/sWUZvX Focus on newer Jigsaw material (2016 or later)
  • 71. Q&A Twitter: @ctjava Email: rcuprak@gmail.com / r5k@3ds.com Blog: cuprak.info Linkedin: www.linkedin.com/in/rcuprak Slides: www.slideshare.net/rcuprak/presentations