SlideShare ist ein Scribd-Unternehmen logo
1 von 53
How JSR 385 could have Saved the Mars
Climate Orbiter
Werner Keil & Thodoris Bais
@wernerkeil
https://hobbylark.com/party-games/1999-Fun-Facts-Trivia-and-News
@UnitAPI
https://youtu.be/v1Zst19VWvo
Life on Mars 1999
https://youtu.be/2CZl7ysDKOI https://youtu.be/EdLdL-Su_fo
@thodorisbais@wernerkeil
Mars Climate
Orbiter
• Launched on 11
December 1998
• 338 kilograms
• $125 millions
• To study Martian
climate, atmosphere
and surface changes
@wernerkeil @thodorisbais
Result of the Mission
@thodorisbais@wernerkeil
@thodorisbais@wernerkeil
What went wrong
@thodorisbais@wernerkeil
lbf·s N·s4.45
Mars Climate Orbiter
“The problem here was not the error; it was the
failure of NASA’s systems engineering, and the
checks and balances in our process, to detect the
error. That’s why we lost the spacecraft.”
Edward Weiler
NASA associate administrator of space science,
IEEE Spectrum: Why the Mars Probe went off course
@thodorisbais@wernerkeil
Lessons Learned
@thodorisbais@wernerkeil
• Read the software specifications
• Use JSR-385 instead of primitives
• Fail-fast
More unit mishaps
@thodorisbais@wernerkeil
Problem Statement
@thodorisbais@wernerkeil
What is the Fundamental Problem?
Primitive (Java) types are primitive types
• static final double C = 1079252849;
• static final double SPEED_OF_LIGHT = 1079252849;
• static final double SPEED_OF_LIGHT_IN_KM_PER_H = 1079252849;
@thodorisbais@wernerkeil
static final Quantity<SPEED> SPEED_OF_LIGHT =
Quantities.getQuantity(1079252849, Units.KILOMETRE_PER_HOUR);
Rolling your Own Library
• Development
• Maintenance
• Upgrades & extensions
@thodorisbais@wernerkeil
Werner Keil Thodoris Bais
Maintenance Lead JSR-385
Expert Group Member JSR-385
Let’s meet
@thodorisbais@wernerkeil
@thodorisbais@wernerkeil
ABN Amro Bank
Financial sector
Amsterdam
Agile organization
20,000
3000+
400+
Total number of employeesEnterprise bank
Headquarters Development Teams
DevOps / Hybrid cloud Applications
What is JSR-385?
@thodorisbais@wernerkeil
@thodorisbais@wernerkeil
JSR-385: Units of
Measurement API 2.0
JSR-275 Modularity
Support Java SE >=8
JSR-363
JSR-385 Basic Concepts
• Dimensions
• Units
• Quantities
• Prefixes
• Converters
• Formats
• Systems of units
@thodorisbais@wernerkeil
Setting up a project
<dependencies>
<dependency>
<groupId>tech.units</groupId>
<artifactId>indriya</artifactId>
<version>2.0.2</version>
</dependency>
</dependencies>
@thodorisbais@wernerkeil
@thodorisbais@wernerkeil
Quantities
–Wikipedia
“A physical quantity is a physical property of a phenomenon, body, or
substance, that can be quantified by measurement.”
Definition of a Physical Quantity
@thodorisbais@wernerkeil
Speed of Light
c = 299,792,458 m/s
Value Unit
@thodorisbais@wernerkeil
Speed of Light
c = 299,792,458 m/s
= 1,079,252,849 km/h
@thodorisbais@wernerkeil
@thodorisbais@wernerkeil
Units
Base Units
@wernerkeil @UnitAPI
Derived Units
@wernerkeil @UnitAPI
Multiples
• km
• ms
• Mm?
• ks?
@thodorisbais@wernerkeil
@thodorisbais@wernerkeil
Dimensions
Dimensions
• L: length
• T: time
• M: mass
• I: electric current
• Θ: thermodynamic temperature
• N: amount of substance
• J: luminous intensity
• (1)
Force: L · M · T-2
@thodorisbais@wernerkeil
Summary Table
@thodorisbais@wernerkeil
One more quote
@thodorisbais@wernerkeil
–Ibidem
“The same physical quantity can be represented equivalently in many unit systems.”
Systems of UnitSystems of Units
• Metric System
• Imperial System
• US customary units
• Roman units of measurement
• Norwegian Units of Measurement
@thodorisbais@wernerkeil
Doing the Math
@thodorisbais@wernerkeil
Equality and Equivalence
• kΩ ≠ mHz
• kΩ ≠ mΩ
• kΩ ≡ kΩ
• N ≅ kg·m·s-2
• kg·m-2 ≅ mg·mm-2
• 1 kΩ ≠ 1 mHz
• 1 kΩ ≠ 1 mΩ
• 1 kΩ ≡ 1 kΩ
• 1 N ≅ 1 kg·m·s-2
• 1 kg·m-2 ≅ 1 mg·mm-2
• 1 kΩ ≅ 1,000 Ω
Units Quantities
@thodorisbais@wernerkeil
Quantity Addition
• 1 Ω + 1 Ω = 2 Ω
• 1 Ω + 1 mΩ = 1.001 Ω
• 1 mΩ + 1 Ω = 1,001 mΩ
• 1 Ω + 1 m “does not compile”
@thodorisbais@wernerkeil
Java Global Summit Math Exam
How much is 0 °C + 0 °C?
• 0 °C
• 0 °C
• 273.15 °C
Two absolute temperatures
0 °C + 0 °C = 273.15K + 273.15K
= 546.30K
= 273.15 °C
@thodorisbais@wernerkeil
How much is 0 °C + 0 °C?
• 0 °C
• 0 °C
• 273.15 °C
An absolute temperature and a temperature change
0 °C + 0 °C = 273.15K + 0K
= 273.15K
= 0 °C
@thodorisbais@wernerkeil
Java Global Summit Math Exam
How much is 0 °C + 0 °C?
• 0 °C
• 0 °C
• 273.15 °C
Two temperature changes
0 °C + 0 °C = 0K + 0K
= 0K
= 0 °C
@thodorisbais@wernerkeil
Java Global Summit Math Exam
How much is 0 °C + 0 °C?
Answer
@thodorisbais@wernerkeil
Java Global Summit Math Exam
Temperature Scales
@wernerkeil
Lord Kelvin
(1824 - 1907)
Anders Celsius
(1701 - 1744)
Daniel G. Fahrenheit
(1686 - 1736)
@thodorisbais
Royal Swedish Academy of
Sciences
@wernerkeil @thodorisbais
Demo Time
@thodorisbais@wernerkeil
Write a program to calculate the BMI of a person
Exercise description
@thodorisbais@wernerkeil
1. Define two quantities
a. A mass
b. A length
2. Print them out
Useful classes:
•tech.units.indriya.quantity.Quantities
•getQuantity(java.lang.Number value, javax.measure.Unit unit)
•tech.units.indriya.unit.Units
•javax.measure.Quantity
•javax.measure.quantity.Mass
Exercise 1
@thodorisbais@wernerkeil
• Divide the mass by the square of the height
• Print out the result
Exercise 2
@thodorisbais@wernerkeil
a. Parse mass and height from a String
b. Read mass and height from the command line
Exercise 3
@thodorisbais@wernerkeil
a. Define a BMI quantity
b. Define a BMI unit
c. Convert the quantity to the BMI unit before printing it out
Exercise 4
@thodorisbais@wernerkeil
• Autodetect which argument has mass dimension and which one
has length
Exercise 5
@thodorisbais@wernerkeil
What was the Fundamental
Problem Again?
Primitive (Java) types are primitive types
@thodorisbais@wernerkeil
JSR-385 Links
• JCP page
• https://jcp.org/en/jsr/detail?id=385
• GitHub pages
• https://unitsofmeasurement.github.io/
• https://github.com/unitsofmeasurement
• http://uom.si
• http://www.uom.systems
• Twitter
• @UnitAPI
@thodorisbais@wernerkeil
Java Community Process
@thodorisbais@wernerkeil
Becoming a JCP Member
@thodorisbais@wernerkeil
@thodorisbais@wernerkeil

Weitere ähnliche Inhalte

Ähnlich wie How JSR 385 could have Saved the Mars Climate Orbiter Java Global Summit 2020

How JSR 385 Could have Saved the Mars Climate Orbiter JCON September 2019
How JSR 385 Could have Saved the Mars Climate Orbiter JCON September 2019How JSR 385 Could have Saved the Mars Climate Orbiter JCON September 2019
How JSR 385 Could have Saved the Mars Climate Orbiter JCON September 2019Thodoris Bais
 
Copy of Science Subject for Elementary - 4th Grade_ Changes in Matter and Ene...
Copy of Science Subject for Elementary - 4th Grade_ Changes in Matter and Ene...Copy of Science Subject for Elementary - 4th Grade_ Changes in Matter and Ene...
Copy of Science Subject for Elementary - 4th Grade_ Changes in Matter and Ene...2020117466
 
Thermal energy agenda and bellwork
Thermal energy   agenda and bellworkThermal energy   agenda and bellwork
Thermal energy agenda and bellworksbarkanic
 
Kecsm2012uren
Kecsm2012urenKecsm2012uren
Kecsm2012urenurvics
 
Energy and Chemical Energy
Energy and Chemical EnergyEnergy and Chemical Energy
Energy and Chemical EnergyRamadina Goethe
 
physics_lecture_note_energy_flow_human.ppt
physics_lecture_note_energy_flow_human.pptphysics_lecture_note_energy_flow_human.ppt
physics_lecture_note_energy_flow_human.pptSunCharoenrat
 
New chm 151 unit 1 powerpoints sp13 s
New chm 151 unit 1 powerpoints sp13 sNew chm 151 unit 1 powerpoints sp13 s
New chm 151 unit 1 powerpoints sp13 scaneman1
 
2 3 What Is Temperature
2 3 What Is Temperature2 3 What Is Temperature
2 3 What Is Temperaturemrheffner
 
Heat & Thermodynamics
Heat & ThermodynamicsHeat & Thermodynamics
Heat & ThermodynamicsCarla Faner
 
International system-units (Science 6)
International system-units (Science 6)International system-units (Science 6)
International system-units (Science 6)Nesly Van Lorenzo
 
Energy transfer and storage
Energy transfer and storageEnergy transfer and storage
Energy transfer and storagemithilan
 
Heat & Waves: Notes on HEAT ENERGY and WAVES including the difference between...
Heat & Waves: Notes on HEAT ENERGY and WAVES including the difference between...Heat & Waves: Notes on HEAT ENERGY and WAVES including the difference between...
Heat & Waves: Notes on HEAT ENERGY and WAVES including the difference between...Robin Seamon
 

Ähnlich wie How JSR 385 could have Saved the Mars Climate Orbiter Java Global Summit 2020 (20)

How JSR 385 Could have Saved the Mars Climate Orbiter JCON September 2019
How JSR 385 Could have Saved the Mars Climate Orbiter JCON September 2019How JSR 385 Could have Saved the Mars Climate Orbiter JCON September 2019
How JSR 385 Could have Saved the Mars Climate Orbiter JCON September 2019
 
Copy of Science Subject for Elementary - 4th Grade_ Changes in Matter and Ene...
Copy of Science Subject for Elementary - 4th Grade_ Changes in Matter and Ene...Copy of Science Subject for Elementary - 4th Grade_ Changes in Matter and Ene...
Copy of Science Subject for Elementary - 4th Grade_ Changes in Matter and Ene...
 
Grade 7 Chemistry
Grade 7 ChemistryGrade 7 Chemistry
Grade 7 Chemistry
 
Thermal energy agenda and bellwork
Thermal energy   agenda and bellworkThermal energy   agenda and bellwork
Thermal energy agenda and bellwork
 
Kecsm2012uren
Kecsm2012urenKecsm2012uren
Kecsm2012uren
 
Energy and Chemical Energy
Energy and Chemical EnergyEnergy and Chemical Energy
Energy and Chemical Energy
 
physics_lecture_note_energy_flow_human.ppt
physics_lecture_note_energy_flow_human.pptphysics_lecture_note_energy_flow_human.ppt
physics_lecture_note_energy_flow_human.ppt
 
05 measurement
05 measurement05 measurement
05 measurement
 
New chm 151 unit 1 powerpoints sp13 s
New chm 151 unit 1 powerpoints sp13 sNew chm 151 unit 1 powerpoints sp13 s
New chm 151 unit 1 powerpoints sp13 s
 
2 3 What Is Temperature
2 3 What Is Temperature2 3 What Is Temperature
2 3 What Is Temperature
 
Heat & Thermodynamics
Heat & ThermodynamicsHeat & Thermodynamics
Heat & Thermodynamics
 
Lect1(unit).ppt
Lect1(unit).pptLect1(unit).ppt
Lect1(unit).ppt
 
International system-units (Science 6)
International system-units (Science 6)International system-units (Science 6)
International system-units (Science 6)
 
Kinetic theory
Kinetic theoryKinetic theory
Kinetic theory
 
Heat and temperature
Heat and temperatureHeat and temperature
Heat and temperature
 
Energy transfer and storage
Energy transfer and storageEnergy transfer and storage
Energy transfer and storage
 
Heat & Waves: Notes on HEAT ENERGY and WAVES including the difference between...
Heat & Waves: Notes on HEAT ENERGY and WAVES including the difference between...Heat & Waves: Notes on HEAT ENERGY and WAVES including the difference between...
Heat & Waves: Notes on HEAT ENERGY and WAVES including the difference between...
 
2_Scientific Viewpoint/Method/SRI
2_Scientific Viewpoint/Method/SRI2_Scientific Viewpoint/Method/SRI
2_Scientific Viewpoint/Method/SRI
 
Sec 4 Chapter 3
Sec 4 Chapter 3Sec 4 Chapter 3
Sec 4 Chapter 3
 
Calorimeter
CalorimeterCalorimeter
Calorimeter
 

Mehr von Thodoris Bais

EclipseCon 2021 NoSQL Endgame
EclipseCon 2021 NoSQL EndgameEclipseCon 2021 NoSQL Endgame
EclipseCon 2021 NoSQL EndgameThodoris Bais
 
You Graduated Now What ECE UoWM 2021
You Graduated Now What ECE UoWM 2021You Graduated Now What ECE UoWM 2021
You Graduated Now What ECE UoWM 2021Thodoris Bais
 
NoSQL Endgame LWJUG 2021
NoSQL Endgame LWJUG 2021NoSQL Endgame LWJUG 2021
NoSQL Endgame LWJUG 2021Thodoris Bais
 
Be the Leader of Your Own Career Global Summit for Java Devs 21
Be the Leader of Your Own Career Global Summit for Java Devs 21Be the Leader of Your Own Career Global Summit for Java Devs 21
Be the Leader of Your Own Career Global Summit for Java Devs 21Thodoris Bais
 
How to grow an amazing community - JavaLand 2021
How to grow an amazing community - JavaLand 2021How to grow an amazing community - JavaLand 2021
How to grow an amazing community - JavaLand 2021Thodoris Bais
 
Securing eHealth, eGovernment and eBanking with Java - IT-Tage 2020 Conference
Securing eHealth, eGovernment and eBanking with Java - IT-Tage 2020 ConferenceSecuring eHealth, eGovernment and eBanking with Java - IT-Tage 2020 Conference
Securing eHealth, eGovernment and eBanking with Java - IT-Tage 2020 ConferenceThodoris Bais
 
NoSQL Endgame DevoxxUA Conference 2020
NoSQL Endgame DevoxxUA Conference 2020NoSQL Endgame DevoxxUA Conference 2020
NoSQL Endgame DevoxxUA Conference 2020Thodoris Bais
 
Securing eHealth, eGovernment and eBanking with Java - JCON Conference
 Securing eHealth, eGovernment and eBanking with Java - JCON Conference Securing eHealth, eGovernment and eBanking with Java - JCON Conference
Securing eHealth, eGovernment and eBanking with Java - JCON ConferenceThodoris Bais
 
Be the Leader of Your Own Career JCON Conference 2020
Be the Leader of Your Own Career JCON Conference 2020Be the Leader of Your Own Career JCON Conference 2020
Be the Leader of Your Own Career JCON Conference 2020Thodoris Bais
 
NoSQL Endgame JCON Conference 2020
NoSQL Endgame JCON Conference 2020NoSQL Endgame JCON Conference 2020
NoSQL Endgame JCON Conference 2020Thodoris Bais
 
NoSQL Endgame Percona Live Online 2020
NoSQL Endgame Percona Live Online 2020NoSQL Endgame Percona Live Online 2020
NoSQL Endgame Percona Live Online 2020Thodoris Bais
 
Utrecht JUG meetup September 2020
Utrecht JUG meetup September 2020Utrecht JUG meetup September 2020
Utrecht JUG meetup September 2020Thodoris Bais
 
Developer Career: Own it - SouJava April 2020
Developer Career: Own it - SouJava April 2020Developer Career: Own it - SouJava April 2020
Developer Career: Own it - SouJava April 2020Thodoris Bais
 
Securing eHealth and eGovernment with Java - AllTheTalksOnline 2020
Securing eHealth and eGovernment with Java - AllTheTalksOnline 2020Securing eHealth and eGovernment with Java - AllTheTalksOnline 2020
Securing eHealth and eGovernment with Java - AllTheTalksOnline 2020Thodoris Bais
 
How to pitch an innovative idea in a corporate environment
How to pitch an innovative idea in a corporate environmentHow to pitch an innovative idea in a corporate environment
How to pitch an innovative idea in a corporate environmentThodoris Bais
 
Utrecht JUG meetup February 2020
Utrecht JUG meetup February 2020Utrecht JUG meetup February 2020
Utrecht JUG meetup February 2020Thodoris Bais
 
Developer Career: Own it - Adorsys 2020
Developer Career: Own it - Adorsys 2020Developer Career: Own it - Adorsys 2020
Developer Career: Own it - Adorsys 2020Thodoris Bais
 
Utrecht JUG Meetup January 2020
Utrecht JUG Meetup January 2020Utrecht JUG Meetup January 2020
Utrecht JUG Meetup January 2020Thodoris Bais
 
Developer Career: Own it - Java2Days 2019
Developer Career: Own it - Java2Days 2019Developer Career: Own it - Java2Days 2019
Developer Career: Own it - Java2Days 2019Thodoris Bais
 
Securing eHealth and eGovernment with Java - Java2Days 2019
Securing eHealth and eGovernment with Java - Java2Days 2019Securing eHealth and eGovernment with Java - Java2Days 2019
Securing eHealth and eGovernment with Java - Java2Days 2019Thodoris Bais
 

Mehr von Thodoris Bais (20)

EclipseCon 2021 NoSQL Endgame
EclipseCon 2021 NoSQL EndgameEclipseCon 2021 NoSQL Endgame
EclipseCon 2021 NoSQL Endgame
 
You Graduated Now What ECE UoWM 2021
You Graduated Now What ECE UoWM 2021You Graduated Now What ECE UoWM 2021
You Graduated Now What ECE UoWM 2021
 
NoSQL Endgame LWJUG 2021
NoSQL Endgame LWJUG 2021NoSQL Endgame LWJUG 2021
NoSQL Endgame LWJUG 2021
 
Be the Leader of Your Own Career Global Summit for Java Devs 21
Be the Leader of Your Own Career Global Summit for Java Devs 21Be the Leader of Your Own Career Global Summit for Java Devs 21
Be the Leader of Your Own Career Global Summit for Java Devs 21
 
How to grow an amazing community - JavaLand 2021
How to grow an amazing community - JavaLand 2021How to grow an amazing community - JavaLand 2021
How to grow an amazing community - JavaLand 2021
 
Securing eHealth, eGovernment and eBanking with Java - IT-Tage 2020 Conference
Securing eHealth, eGovernment and eBanking with Java - IT-Tage 2020 ConferenceSecuring eHealth, eGovernment and eBanking with Java - IT-Tage 2020 Conference
Securing eHealth, eGovernment and eBanking with Java - IT-Tage 2020 Conference
 
NoSQL Endgame DevoxxUA Conference 2020
NoSQL Endgame DevoxxUA Conference 2020NoSQL Endgame DevoxxUA Conference 2020
NoSQL Endgame DevoxxUA Conference 2020
 
Securing eHealth, eGovernment and eBanking with Java - JCON Conference
 Securing eHealth, eGovernment and eBanking with Java - JCON Conference Securing eHealth, eGovernment and eBanking with Java - JCON Conference
Securing eHealth, eGovernment and eBanking with Java - JCON Conference
 
Be the Leader of Your Own Career JCON Conference 2020
Be the Leader of Your Own Career JCON Conference 2020Be the Leader of Your Own Career JCON Conference 2020
Be the Leader of Your Own Career JCON Conference 2020
 
NoSQL Endgame JCON Conference 2020
NoSQL Endgame JCON Conference 2020NoSQL Endgame JCON Conference 2020
NoSQL Endgame JCON Conference 2020
 
NoSQL Endgame Percona Live Online 2020
NoSQL Endgame Percona Live Online 2020NoSQL Endgame Percona Live Online 2020
NoSQL Endgame Percona Live Online 2020
 
Utrecht JUG meetup September 2020
Utrecht JUG meetup September 2020Utrecht JUG meetup September 2020
Utrecht JUG meetup September 2020
 
Developer Career: Own it - SouJava April 2020
Developer Career: Own it - SouJava April 2020Developer Career: Own it - SouJava April 2020
Developer Career: Own it - SouJava April 2020
 
Securing eHealth and eGovernment with Java - AllTheTalksOnline 2020
Securing eHealth and eGovernment with Java - AllTheTalksOnline 2020Securing eHealth and eGovernment with Java - AllTheTalksOnline 2020
Securing eHealth and eGovernment with Java - AllTheTalksOnline 2020
 
How to pitch an innovative idea in a corporate environment
How to pitch an innovative idea in a corporate environmentHow to pitch an innovative idea in a corporate environment
How to pitch an innovative idea in a corporate environment
 
Utrecht JUG meetup February 2020
Utrecht JUG meetup February 2020Utrecht JUG meetup February 2020
Utrecht JUG meetup February 2020
 
Developer Career: Own it - Adorsys 2020
Developer Career: Own it - Adorsys 2020Developer Career: Own it - Adorsys 2020
Developer Career: Own it - Adorsys 2020
 
Utrecht JUG Meetup January 2020
Utrecht JUG Meetup January 2020Utrecht JUG Meetup January 2020
Utrecht JUG Meetup January 2020
 
Developer Career: Own it - Java2Days 2019
Developer Career: Own it - Java2Days 2019Developer Career: Own it - Java2Days 2019
Developer Career: Own it - Java2Days 2019
 
Securing eHealth and eGovernment with Java - Java2Days 2019
Securing eHealth and eGovernment with Java - Java2Days 2019Securing eHealth and eGovernment with Java - Java2Days 2019
Securing eHealth and eGovernment with Java - Java2Days 2019
 

Kürzlich hochgeladen

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Jeffrey Haguewood
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...Zilliz
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Orbitshub
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Victor Rentea
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxRustici Software
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfOrbitshub
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MIND CTI
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...apidays
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Victor Rentea
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 

Kürzlich hochgeladen (20)

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering Developers
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 

How JSR 385 could have Saved the Mars Climate Orbiter Java Global Summit 2020

Hinweis der Redaktion

  1. Late 1999 - David Bowie – small-scale promotional concert tour known as the Hours Tour with the opening song of the setlist having the name “Life on Mars 1999”
  2. Primary science objectives of the mission: determine the distribution of water in Mars monitor the daily atmospheric conditions record changes of the Martian surface (due to wind) determine temperature profiles in the atmosphere look for evidence of past climate change
  3. This picture costed $125 millions dollars
  4. into a trajectory above 226km above the surface of Mars It probably got disintegrated in the atmosphere and disappeared. Minimum altitude to survive was 80km above the surface of Mars
  5. A piece of software provided by Lockheed Martin produced results for the total impulse by the thruster firing in pound force seconds, whereas the trajectory calculation software provided by NASA expected it to be in Newton seconds. The software specification said it should have been in Newton seconds so Luckheed Martin clearly made a mistake
  6. if Lockheed Martin had done a good job, it would have never happened Use JSR-385 instead of primitives Fail fast <== don’t rely on the checksum balancer to discover problems
  7. The 12 October 1492 “mishap” Colombus miscalculated the circumference of the earth cuz he used roman miles instead of nautical miles. ended up in Bahamas, but thought he was in Asia. Consequence? the native americans were called for Indians 500 years afterwards 2) Clarence the Tortoise, 2001 , Galapagos tortoise Los Angeles Zoo loaned to Moorpark College. “Build an enclosure for an animal that weighs in at about 250” Forgot to say “kilograms” . so Moorpark college built one for a 250 pound tortoise. Guess what happened the first night. Clarence wrecked the cage 3) units begging for mistakes —> Tea spoon . gram and grain “take 5 grains” is being understood as “take 5 grams” 4) SDI measurement problem (SDI was Reagan's Space Force) where the Space Shuttle turned upside down
  8. using a primitive to represent a quantity is fundamentally conflicting with OOP and DDD, cuz you’re using a type representing just a number to represent a quantity which has a unit —- built in into the property and it contains both the value and the unit —- No way to misinterpret the SPEED of light at the bottom as that number in km/h
  9. wanna do it properly? define ur own library how difficult can it be? it’s just a value and a unit lot of work —> many units meter, time units, electrical resistance , TEMPERATURES?, divide & multiply Are you a UoM domain expert? so even if you use the SI system every day do you really understand how it works? TBH I didn’t even answer that question to myself. I would be surprised if you know all the peculiarities around SI. There is a number of strange things, even though it is designed as the rational system as compared to some other systems.
  10. This JSR is a major evolution of the Unit API 1.0 (JSR 363) specification. Focussed on the SI System redefinition, modularity and support for Java SE 8/9 and above. JSR 363 This JSR specifies Java packages for modelling and working with measurement values, quantities and their corresponding units.
  11. Dimensions: length Unit: metre Quantity: 5 metres prefixes: kilo, milli, etc. converters: km/h —> m/s or mph formatting: print out the quantity and parse the quantity of the unit systems of units: metric, imperial and handle them in a good way
  12. It doesn’t do some kinds of optimisations that one could think it would be nice to have
  13. Let’s start by defining a number of quantities and try to print them out.
  14. Yesterday I travelled 1.6Mm??? 1hour = 3.6ks, but “come back in 1ks”???
  15. You need 1 for the angle for example so that you can handle the absence of dimension
  16. 5 meters = 500 cm
  17. Metre, kilogram, second, ampere… Foot, ounce, pound, gallon, Fahrenheit, horsepower Foot, ounce, pound, gallon, Fahrenheit, gallon, … Pes, uncia, libra, … Fot, favn, mål, tønne, snes, …
  18. Should you have functions to normalize expressions into what could be closer to the base unit That’s something you could consider, and also for quantities for example that 1 mg per mm-2 is automatically normalized to 1kg m-2 Special paint for small devices It’s not just about comparing the values and the units you have to convert to one unit and do the comparison in one reference unit
  19. We use the 1st unit if we can If it leads to an overflow, we can fall back to the second unit Otherwise, if it leads to an overflow in both units, we just throw an overflow error
  20. THAT’S EASY! RIGHT? There are thermodynamic parameters when you want to add temperatures
  21. All 3 answers are correct depending on the situation. absolute or relative quantity? We hadn’t modelled this. So, again, are you a domain expert in ur system? Do you really know the SI system so that you can write a library to handle this stuff? Why are we using degrees celsius. Undoubtedly, it’s easy (0-100 degrees), but degrees celsius is not such a good unit to measure temperature. JavaZone example with Time (i.e. day light, saving time, etc., formatting problem with US month – dd - yyyy, countries using F and celsius)
  22. kg/m^2 a thing that matters for the BMI index is to express the units as kilograms and meters and not cm for example. We’ll see as we go through th exercise that we can handle that in a good way
  23. So you see? this is not difficult to do, so instead of defining an Integer to hold 75 as the mass, that’s not much of simplification compared to this