$30 off During Our Annual Pro Sale. View Details »

26 Java Years

26 Java Years

#31 ~オープンソースプロジェクトを支える言語たち~
2021-08/25

Shin Tanimoto

August 25, 2021
Tweet

More Decks by Shin Tanimoto

Other Decks in Technology

Transcript

  1. Shin Tanimoto 26 Java Years - ͜Ε͕ࠓͷJavaͩʂ <OSS X Users

    Meeting> #31 ʙΦʔϓϯιʔεϓϩδΣΫτΛࢧ͑Δݴޠͨͪʙ
  2. ୩ຊ ৺ (Shin Tanimoto) ೔ຊJavaϢʔβʔάϧʔϓ Ϧʔμʔʢ୅දʣ Java Champion / Oracle

    Groundbreaker Ambassador Everforth / Acroquest Technologyͷ2ࣾͰಇ͘ΤϯδχΞ ෭ۀʹͯ֎෦ސ໰΍ʮϨϯλϧ͢΂ΔਓʯͳͲ ੜ͖͕͍͸BABYMETALͷϥΠϒࢀઓ ࣗݾ঺հ 2 Twitter : @cero_t ஶॻ : Javaຊ֨ೖ໳
  3. จࣈྻஔ׵ϝιου Java͸ݹ͍ʁ 10 String str = “12345-12345-12345";
 
 str.replace('1', 'x');

    → "x2345-x2345-x2345"ɹ1จࣈ͚ͩࢦఆͯ͠શஔ׵
 
 str.replaceFirst("\\d+", "xyz"); → "xyz-12345-12345"ɹਖ਼نදݱͰࢦఆͯ͠1ճஔ׵
 
 str.replaceAll("\\d+", "xyz"); → "xyz-xyz-xyz"ɹਖ਼نදݱͰࢦఆͯ͠શஔ׵
 
 str.replace("123", "xyz"); → “xyz45-xyz45-xyz45"ɹจࣈྻͰࢦఆͯ͠શஔ׵
  4. จࣈྻஔ׵ϝιου str.replace(‘1’, ‘x’); → ࠷ॳ͔Β͋Δʢ1996೥ʣ str.replaceFirst(“\\d+”, “xyz”); → Java 1.4Ͱ௥Ճʢ2002೥ʣ

    str.replaceAll(“\\d+”, “xyz”); →Java 1.4Ͱ௥Ճʢ2002೥ʣ str.replace(“123”, “xyz”); → Java 1.5Ͱ௥Ճʢ2004೥ʣ ޙํޓ׵ੑΛอͭͨΊɺݹ͍APIΛ࡟আ͠ͳ͍ Java͸ݹ͍ʁ 11
  5. 1995೥ : Sun MicrosystemsࣾʹΑΓॳ͓൸࿐໨ 1996೥ : JDK 1.0ϦϦʔεʢJDK = Java

    Development Kitʣ 2006೥ : OSSԽ 2010೥ : Oracle͕ࣾSun MicrosystemsࣾΛങऩ 2014೥ : Java 8ͷϦϦʔεɻؔ਺ܕ෩ͷهड़͕Ͱ͖ΔΑ͏ʹͳΓɺվΊͯ஫໨͕ू·ΔΑ͏ʹͳͬͨ 2017೥ : Java 9ͷϦϦʔεɻҎ߱൒೥͝ͱʹ࣍όʔδϣϯΛϦϦʔε͢ΔΑ͏มߋ Javaͷ؆୯ͳྺ࢙ 17
  6. JavaVM : Java Virtual MachineɻJavaΛಈ࡞ͤ͞ΔԾ૝ϚγϯɻJVMͱ΋දه͢Δ Java͸࣮ߦՄೳͳόΠφϦΛ࡞ΔͷͰ͸ͳ͘ɺίϯύΠϧͨ͠ϑΝΠϧΛJavaVM্Ͱಈ࡞ͤ͞Δํࣜ Java SE : ͍ΘΏΔJavaຊମ

    JDK : Java Development KitɻίϯύΠϥͳͲͷ։ൃπʔϧ JRE : Java Runtime EnvironmentɻJavaVM΍ඪ४ϥΠϒϥϦͳͲͷ࣮ߦ؀ڥ ݱࡏ͸JRE୯ମͰͷఏڙ͸͞Εͳ͘ͳͬͨ جૅ༻ޠ 18
  7. Java EEʢݱJakarta EEʣ : αʔόΞϓϦέʔγϣϯ޲͚ͷAPαʔό΍ϥΠϒϥϦ܈Λఏڙ Java ME : ૊ΈࠐΈ୺຤޲͚ͷJava JVMݴޠ

    : JavaVMͷ্Ͱಈ࡞͢ΔJavaͰ࣮૷͞Εͨݴޠ ScalaɺKotlinɺGroovyɺJRubyɺJythonͳͲ TCK : Technology Compatibility KitɻJavaͷޓ׵ੑΛ਍அ͢ΔπʔϧΩοτ ֤ࣾͷJava࣮૷͸TCKΛ௨ͬͯ͸͡ΊͯJavaͱೝఆ͞ΕΔ Oracleʢݩʑ͸Sun Microsystemsʣ͕ఏڙ͍ͯ͠Δ جૅ༻ޠ 19
  8. 2006೥ɺJavaͷOSS࣮૷ͱͯ͠ʮApache Harmonyʯ͕ఏڙ͞Εͨ Apache License 2.0Ͱఏڙʢվมͨ͠ࡍͷιʔείʔυͷެ։ٛ຿͕ͳ͍ʣ˞Ҏ߱AL-2.0ͱදه͢Δ ͔͠͠౰࣌ɺSun Microsystems͸Apache Harmony΁ͷTCKͷఏڙΛڋ൱ TCKΛ௨͍ͯ͠ͳ͍࣮૷͸JavaͱೝΊΒΕͳ͍ Apache

    Harmony͸૊ΈࠐΈ୺຤Ͱ΋ಈ࡞͕ͨ͠ɺ౰࣌ͷTCK͸૊ΈࠐΈ୺຤ʹద༻Ͱ͖ΔJavaΛର৅֎ͱ͍ͯͨ͠ ಉ͘͡2006೥ɺSun Microsystems͕Java SEΛOSSԽʢݱࡏͷOpenJDKʣ GPLv2Ϋϥεύεྫ֎͖ͭʢվมͨ͠ࡍʹιʔείʔυͷެ։ٛ຿͕͋Δʣ˞Ҏ߱GPLv2ͱදه͢Δ Apache harmonyࣄ݅ 35
  9. ૌুͷ݁຤ ಛڐݖ৵֐ → ͍ͯ͠ͳ͍Ͱ֬ఆ JavaϥΠϒϥϦͷ࣮૷ίʔυΛແஅෳ੡ → ͍ͯ͠Δ͕͔ᷮ͘͝ͳͷͰഛঈۚ0ԁ Java APIͷஶ࡞ݖ৵֐ →

    ͍ͯ͠Δ͕ϑΣΞϢʔεͩͱ֬ఆ ܞଳి࿩͕εϚʔτϑΥϯʹஔ͖׵ΘΓɺJava ME͕࢖ΘΕͳ͘ͳͬͨ͜ͱͰ 
 Sun Microsystems΍Oracle͸ϞόΠϧ෼໺ʹ͓͚ΔJavaͷϏδωεΛࣦ͏͜ͱͱͳͬͨ Googleૌুࣄ݅ 40
  10. ͍·ͷओྲྀ͸ϓϥοτϑΥʔϜͰαϙʔτ͞Ε͍ͯΔOpenJDKΛར༻͢Δ͜ͱ Red Hat Enterprise LinuxΛ࢖͏ͳΒRed Hat OpenJDK AWSͰ࢖͏ͳΒAmazon Corretto AzureͰ࢖͏ͳΒMicrosoft

    Build of OpenJDK ֶश΍ௐࠪ༻ͳΒαϙʔτظؒͷ୹͍Oracle OpenJDKͰ΋ߏΘͳ͍ ֤͕ࣾఏڙ͢ΔOpenJDKʹ͓͍ͯগͣͭ͠ఏڙ͢Δπʔϧ͕ҧͬͨΓɺద༻͞ΕΔύον͕ҟͳΔ͜ͱ͸ 
 ͋ΓಘΔ͕ɺݩͱͳΔOpenJDK͸ಉҰͰ͋ΔͨΊͲΕΛ࢖ͬͯ΋99%ಉ͡ɻίΞػೳ͸100%ಉ͡ ༷ʑͳOpenJDK 48