prelude to java se 9: the saga of embedded java … · § your target and its peripherals are...

45
© Copyright Azul Systems 2016 © Copyright Azul Systems 2016 @azulsystems azul.com Prelude to Java SE 9: The Saga of Embedded Java Matt Schuetze Azul Director of Product Management 2/3/16 1 Detroit Java User Group Ann Arbor, Michigan

Upload: others

Post on 21-Jul-2020

1 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

© Copyright Azul Systems 2016

@az uls ystems azul.com

Prelude to Java SE 9: The Saga of Embedded Java

Matt SchuetzeAzul Director of Product Management

2/3/161

Detroit Java User Group

Ann Arbor, Michigan

Page 2: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Agenda§ Saga and Premise

§ “Hosts” and “Targets”

§ Fragmentation

§ Java Convergence

§ Azul Near Horizon

§ Java 9 and Jigsaw Sneak Peak

§ Engage the Future

Page 3: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Saga and PremiseWelcome to all Detroit Java User Group members!

Page 4: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

James

Gosling:

A True

Super

Hero

Page 5: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Premise§ WORA crucial to James’ vision and design basis

to have a consistent programming model

§ First Java use case: TV set top boxes. Then desktops. Then servers.

§ Fragmentation is a global productivity drain.

§ Java and JVM in 2016 are returning to embedded with renewed enthusiasm.

§ Fragmentation vs. WORA cross swords again.

Page 6: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

“Hosts” and “Targets”Not to be confused with “Toast and Poptarts”

Page 7: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Common Definition§ [Product XYZ] is targeted toward analysis of embedded

systems such as phones or tablets. As such it is typical for the analysis to be done on a host system and remotely connect to a target system. So if one uses a windows laptop to analyse results from tests run on a windows phone, then one has a windows target and a windows host. Using the same windows laptop to analyse results from an android tablet would be a windows host and an android target

--source: Intel developer forum, 2015

Page 8: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Definitions for this Talk§ Host: machine on which your source sits and

your tooling runs.

§ Targets: machines on which your application runs, often remote CPUs, though can be same CPU.

§ Embedded Development: using a host to build, load, test, and deploy code to one or more targets.

Page 9: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Embedded Problem Domain§ The host (CPU, OS, location) and tools (IDEs,

simulators, connectivity) you select are partly up to you, but more often they are influenced by the target processor vendor.

§ Your target and its peripherals are dictated by the application requirements and operating environment. You conform your tools to adapt.

§ In-situ development (host is also target) is a luxury, not a certainty

Page 10: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Host and Targets Case:The Plasma Chemical Reactor

“Host” is 486 Dell desktop

“Target” is 2 Dells plus I/O peripherals

Page 11: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Page 12: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Host and Targets Case:The Flight Termination System

“Host” is PC desktop

“Target” is 8 PC104s running NT plus I/O peripherals

Page 13: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Page 14: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Host and Targets:The Airborne Radar System

“Host” is PC desktop,

“Targets” are 6 industrial PCs with MIO boards and ARINC

Page 15: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Page 16: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Host and Targets Case:The Mobile Rail Radar Platform

“Host” is PC desktop,

“Targets” are motion boards, DSPs, FPGAs, Parallax Stamp.

Page 17: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Page 18: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Thinking About Your Targets§ Coding for a target that is not also your host

raises some interesting challenges:

§ What if your target it not available to you?

§ What if your target is not portable?

§ What if your target changes?

§ What if you target is not even built yet?

§ And yet in spite of all this you are still expected to deliver working software on your ship date! How?

Page 19: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

FragmentationCan you defrag a whole industry?

Page 20: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Embedded is Fragmented§ Lion’s share of embedded development remains

fragmented.

§ Coded in C. Java is a distant third.

§ Split across industrial controls, commercial products, telco, auto, medical, and other verticals.

§ 32-bit most common from dozens of chip vendors, but 64, 16, and 8 bit still out there.

Page 21: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Embedded is a Team Sport§ Average team size is 14 people.

§ Average project duration is 12 months.

§ More resource cost spent on SW than on HW.

§ Always moving into newer chips in new projects

§ Always wanting to reuse code in new projects

§ Spending loads of project time in debugging.

§ Consider ability to hit release dates and burden of debugging the top two project concerns.

§ Prefer open source for access to full source tree

Page 22: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Standards Fight Fragmentation§ Java ecosystem tries very hard to not fragment itself.

§ WORA is great for team productivity.

§ WORA is only possible in a multivendor ecosystem when standards are upheld.

§ Java standards gave rise to the JCP, and JSRs, RIs, and TCKs, and multiple implementations

§ Java ME standards allow for Profiles, so still witness some fragmentation around API subsets.

§ Programming model remains consistent, so in general fights fragmentation. Special (anti)praise to Dalvik.

Page 23: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Java Convergence

Java SE meets Java ME

Page 24: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Java 8 Convergence

§ JCP merged Java ME and Java SE/EE committees into one, equal representation.

§ Java SE Compact Profiles standardized.

§ Java SE Embedded effectively replaces CDC.

§ Java ME CLDC, MIDP, MEEP focus on APIs where variances align by verticals.

§ SoCs (dual core, 1GB ram, etc.) now better than those 486s! And ~< $100 for a whole board!

Page 25: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Tooling Convergence§ Simulators abound, running on the host.

§ Debugging, especially remote, is a well worn path through the JVM.

§ Mock testing setups are wonderful and options are prevalent.

§ Dependency Injection is a mature coding pattern.

§ You really can get quite far coding up working software (big thanks to WORA!)

Page 26: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Processor Convergence§ The “tiny” chips aren’t so tiny anymore.

§ Dual core 500 MHz with 1GB RAM, whether ARM or Intel, gives plenty of room for OS, JVM, code, and data.

§ Market consolidated around Intel and ARM as frontrunners, with some Power and MIPS as two other prime contenders.

§ Targets can behave like little hosts.

Page 27: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

"JacaCoreAPI" by Frivard - Own work. Licensed under CC BY-SA 3.0 via Commons

java.io java.lang

java.securityjava.util

javax.microedition

Page 28: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

CLDC8 Spec

§ The Full CLDC 8 API packages are java.lang,

java.lang.annotation, java.lang.ref, java.security, java.io, java.net, java.util, java.nio, java.nio.file, java.nio.file.attribute, java.nio.channels,

java.util.logging and related behaviors and requirements are mandatory.

§ The CLDC 8 Compact API packages are java.lang,

java.lang.annotation, java.lang.ref, java.security, java.io, java.net, java.util

and related behaviors and requirements are mandatory.

§ The Compact CLDC 8 API may be implemented as an alternative to the Full CLDC 8 API.

2/3/1628

Page 29: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Mobile Convergence§ Coding for a mobile phone has the same Host |

Target developer experience as coding for other embedded devices.

§ Rapid expansion in mobile means embedded developers reap benefits.

§ Android has many millions of devout users and devs. Guess which DNA that Dalvik and Android apps all inherit?

Page 30: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Azul Near Horizon

Rise of the Zulu Nation

Page 31: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Azul Zulu Product Family§ Zulu is binary builds of OpenJDK

§ Zulu announced at JavaOne 2013. First target Microsoft Azure, Windows OS on Intel x64.

§ Expanded to free JDK downloads of Zulu on Windows, Linux, and Mac

§ Announced Zulu Embedded, January 2015. Offer JRE and Compact Profile kits.

§ Extended Zulu Embedded to 32-bit x86, Atom, Edison, and Quark, both Windows IoT and Linux

§ Running in the field on 2M units and growing

§ Offerings for professional support same as Azul Zing.

Page 32: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Zulu Community

§ Refocused on the four Fs:

§ Free (as no cost)

§ Freedom (as in no restrictions)

§ Fast (ie. already have OpenJDK 9 builds)

§ Fun (welcome anyone to Zulu.org seeking a fun development community.)

Page 33: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Page 34: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Azul Zulu Active Development

§ Java “ME” libraries to offer GPIO, SPI, I2T on top of Java SE Compact Profiles.

§ Demonstrated GPIO and I2T at JavaOne, 2015.

§ Demonstrated again at Eclipse IoT Workshop

§ Releasing first Java builds on Windows 10 IoT Core.

§ ARM 64 builds of Java 8 test builds in house.

§ ARM 32 builds of Java 8 started development effort in 2015 Q4. Release slated well before Java 9.

§ Leveraging Linaro ARM project with same goals.

Page 35: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Java 9 and Jigsaw

A massive refactoring, backward compatibility on the chopping block

Page 36: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

This is “after” fixing the mess

Page 37: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Jigsaw Purpose / Goals

§ Jigsaw adds a modularization mechanism

– applied to the JDK starting in 9

– available to users (library authors and app developers)

§ Adds reliable configuration

§ Encourages strong encapsulation

§ Removes JAR/classpath hell

§ Improves security, maintainability and performance.

§ Allows creating a Java runtime specific for users’ own needs.

2/3/1637

Page 38: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Engage the Future

You have a stake (and a say) in what things do.

Page 39: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

IoT: Industrial and Commercial

§ Industrial IoT is a big market. Billions big.

§ Commercial is the visible market, yet reflects only about 1/5 the uptake.

§ Hardware accounts for 80%, software about 20%

§ Fragmentation across native vendors, with Java itching to make serious inroads.

§ Lots of potential for Java developers to take on embedded projects including gateways and edge devices with Zulu.

§ IoT backend remains scaled up servers with application logic, often includes big data store, ie Zing’s wheelhouse.

Page 40: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Maker culture§ Learning emphasizes learning-through-doing

(constructivism) in a social environment.

§ Maker culture emphasizes informal, networked, peer-led, and shared learning motivated by fun and self-fulfillment

§ Boards, tools, and effort scales down to permit personal fabrication for "a market of one person”

§ Availability of cheap boards for prototyping and trying novel ideas open new area of fun for techies.

2/3/1640

Page 41: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Page 42: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Page 43: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Conclusion and Q&A

Parting thoughts.

Page 44: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Conclusion§ Java is poised to make a roaring comeback in embedded

applications.

§ Java offers a way to fight the fragmentation evident with so many native development vendors and choices.

§ Java SE and Java ME embedded today are mere reflections of each other, thanks both to the convergence of Java and proliferation of better tiny processors.

§ Azul is active in this space, complementing Zing on servers with Zulu for embedded applications.

§ The future is fun.

Page 45: Prelude to Java SE 9: The Saga of Embedded Java … · § Your target and its peripherals are dictated by the application requirements and operating ... § Extended Zulu Embedded

© Copyright Azul Systems 2016

Parting Messages§ Zulu: zulu.org

§ Azul: azul.com/zulu-embedded/

§ Windows IoT Core:https://dev.windows.com/en-us/iot

§ Trends in Embedded:http://bd.eduweb.hhs.nl/es/2014-embedded-market-study-then-now-whats-next.pdf

§ @schuetzematt