Hosted by Tikal.    w w w . t i k a l k . c o m    Cost-Benefit Open Source Israel  JB oss  U ser  G roup Session  11 / 25...
Agenda <ul><li>Language Matters </li></ul><ul><li>Past, Present, Future </li></ul><ul><li>Key Players </li></ul><ul><li>Ma...
Origin of Java <ul><li>C++ Replacement </li></ul><ul><li>Clearer Syntax </li></ul><ul><li>Omitted ambiguities & pitfalls  ...
Java Today <ul><li>Backward compatibility => Feature freeze  Closures? Generics? Metaprogramming? DSLs?  too late... </li>...
Complexity Matters <ul><li>The overall complexity of a new language feature  correlates with the interactions the new feat...
The Java 7 Closure Act <ul><li>with  (FileInputStream input : new FileInputStream(fileName)) { </li></ul><ul><li>// use in...
The Java 7 Closure Act <ul><li>public static <T,throws E extends Exception> </li></ul><ul><li>T withLock(Lock lock, {=>T t...
The Java 7 Closure Act <ul><li>{ int => int } sum = { int n => n == 1 ? 1 : n + sum.invoke(n - 1) }; </li></ul><ul><li>Int...
The Java 7 Closure Act   Hosted by Tikal      www.tikalk.com Israel JBUG Java Closures Production Language Research Langua...
The Java 7 Closure Act <ul><li>As backwards compatibility increases, elegance decreases </li></ul><ul><li>As languages evo...
The Java 7 Closure Act <ul><li>3 implementation proposals, none passed... </li></ul>  Hosted by Tikal      www.tikalk.com ...
What Have We Learned? <ul><li>Multi-billion dollar industry  cannot afford risky changes </li></ul><ul><li>Mission critica...
Multi Language JVM <ul><li>The JVM, On The Other Hand... </li></ul><ul><ul><li>Well known, proven libraries </li></ul></ul...
Multi Language JVM <ul><li>Downsides: Language-VM Mismatch Translation Artifacts Semantic Mismatch Performance Conservatis...
Market Considerations <ul><li>Blogosphere != Real World </li></ul><ul><li>Language developers:  High rollers involved: For...
Java Language Centric Approach <ul><li>On the other hand, some claim the opposite: Take Java and throw away the runtime </...
Language Characteristics <ul><li>Polyglot Programming?   But how to pick the right tool for the right job? </li></ul>JVM P...
Scala <ul><li>Scala is both OO and functional, while keeping a static type system (as c, c++, java, haskell, pascal...)‏ <...
Groovy <ul><li>“ An agile and dynamic language for the JVM” </li></ul><ul><li>Java code is valid Groovy... </li></ul><ul><...
Ruby <ul><li>Extremely dynamic language </li></ul><ul><li>Strongly typed </li></ul><ul><li>Excellent DSL capabilities (Rai...
Python <ul><li>Modern, advanced OO language </li></ul><ul><li>Power tool language used for science, military... </li></ul>...
Clojure <ul><li>Dynamic programming language that targets the JVM </li></ul><ul><li>Multithreading capabilities (multi-cor...
Trends And Adoption Based on Tiobe index, May 2009   Hosted by Tikal      www.tikalk.com Israel JBUG
<ul><li>Thank You! </li></ul><ul><li>[email_address] </li></ul>  Hosted by Tikal      www.tikalk.com Israel JBUG
Upcoming SlideShare
Loading in...5
×

JBUG 11 - Outside The Java Box

772

Published on

Recent events in the Java community and specification process over the past year or so have led some to pessimistic views regarding the survivability chances of Java as a language. The initial catalyst may have been, ironically enough, Java 7's specification discussions, which stirred up some raw sediments and may have legitimized other languages. This trend has furtherU escalateddue to the welcoming bedding of JVM multilinguality, Java 7's JVM invoke-dynamic feature and growing programming languages trends which did not find their way to Java, such as DSL, meta-programming and typeless variables.
In this short introduction session we will discuss these factors as well as their role in the language shift we're about to explore in future sessions.
&nbsp;
Presentation & Video included&nbsp;

Published in: Technology, Education
0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
772
On Slideshare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
0
Comments
0
Likes
1
Embeds 0
No embeds

No notes for slide

Transcript of "JBUG 11 - Outside The Java Box"

  1. 1. Hosted by Tikal. w w w . t i k a l k . c o m Cost-Benefit Open Source Israel JB oss U ser G roup Session 11 / 25.05.2009 Outside The Java Box By : Zvika Markfeld, Java Architect, Tikal Knowledge
  2. 2. Agenda <ul><li>Language Matters </li></ul><ul><li>Past, Present, Future </li></ul><ul><li>Key Players </li></ul><ul><li>Market Considerations </li></ul><ul><li>Alternatives </li></ul><ul><li>Forecasts </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  3. 3. Origin of Java <ul><li>C++ Replacement </li></ul><ul><li>Clearer Syntax </li></ul><ul><li>Omitted ambiguities & pitfalls (multiple inheritance, operator overloading, ...)‏ </li></ul><ul><li>Conscious verbosity </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  4. 4. Java Today <ul><li>Backward compatibility => Feature freeze Closures? Generics? Metaprogramming? DSLs? too late... </li></ul><ul><li>TOO verbose: millions of lines of code in real apps (IDEs don't solve that!)‏ </li></ul><ul><li>Not enough traction, no hype </li></ul><ul><li>Static type system - too rigid? </li></ul><ul><li>Semi-conclusion: 13 years is a long time! (long enough for a bat to become a rat)‏ </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  5. 5. Complexity Matters <ul><li>The overall complexity of a new language feature correlates with the interactions the new feature has with existing features... </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  6. 6. The Java 7 Closure Act <ul><li>with (FileInputStream input : new FileInputStream(fileName)) { </li></ul><ul><li>// use input </li></ul><ul><li>} </li></ul><ul><li>public static void with(FileInputStream t, {FileInputStream==>void} block) { </li></ul><ul><li>try { </li></ul><ul><li>block.invoke(t); </li></ul><ul><li>} finally { </li></ul><ul><li>try { </li></ul><ul><li>t.close(); </li></ul><ul><li>} catch (IOException ex) { </li></ul><ul><li>logger.log(Level.SEVERE, ex.getMessage(), ex); </li></ul><ul><li>} </li></ul><ul><li>} </li></ul><ul><li>} </li></ul>Runnable r = { => System.out.println(i); } Hosted by Tikal www.tikalk.com Israel JBUG
  7. 7. The Java 7 Closure Act <ul><li>public static <T,throws E extends Exception> </li></ul><ul><li>T withLock(Lock lock, {=>T throws E} block) throws E { </li></ul><ul><li>lock.lock(); </li></ul><ul><li>try { </li></ul><ul><li>return block.invoke(); </li></ul><ul><li>} finally { </li></ul><ul><li>lock.unlock(); </li></ul><ul><li>} </li></ul><ul><li>} </li></ul><ul><li>withLock (lock, {=> </li></ul><ul><li>System.out.println(&quot;hello&quot;); </li></ul><ul><li>}); </li></ul>final double highestGpa = students . filter ({ Student s => s.graduationYear == THIS_YEAR }) . map ( {Student s => s.getGpa() })‏ . max (); (); Hosted by Tikal www.tikalk.com Israel JBUG
  8. 8. The Java 7 Closure Act <ul><li>{ int => int } sum = { int n => n == 1 ? 1 : n + sum.invoke(n - 1) }; </li></ul><ul><li>Integer i = { => throw new NullPointerException(); }.invoke(); </li></ul>{ String => Set<String> } singleton = Collections#<String>singleton(String); Set<String> set = singleton.invoke(&quot;single&quot;); { String => { int => String } } concat = { String s => { int n => String r = &quot;&quot;; for ( ; n > 0; n--) r += s; r } }; { String => Number } p = { Object o => Integer.valueOf(o.hashCode()) }; System.out.println(p.invoke(&quot;haf&quot;)); Hosted by Tikal www.tikalk.com Israel JBUG
  9. 9. The Java 7 Closure Act Hosted by Tikal www.tikalk.com Israel JBUG Java Closures Production Language Research Language Object Oriented Functional Simplicity Power, Conciseness Static Dynamic
  10. 10. The Java 7 Closure Act <ul><li>As backwards compatibility increases, elegance decreases </li></ul><ul><li>As languages evolve, each new addition becomes more complicated, because it has to interact with more conflicting constructs </li></ul><ul><li>At some point, the additions are no longer worth their price </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  11. 11. The Java 7 Closure Act <ul><li>3 implementation proposals, none passed... </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  12. 12. What Have We Learned? <ul><li>Multi-billion dollar industry cannot afford risky changes </li></ul><ul><li>Mission critical assignments cannot afford risky changes </li></ul><ul><li>Blue-collar developer base cannot afford risky changes </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  13. 13. Multi Language JVM <ul><li>The JVM, On The Other Hand... </li></ul><ul><ul><li>Well known, proven libraries </li></ul></ul><ul><ul><li>Standardized </li></ul></ul><ul><ul><li>Secure, robust, scalable </li></ul></ul><ul><ul><li>Serves the “Different languages for different purposes” idiom (CLR? What’s that?)‏ </li></ul></ul><ul><ul><li>As opposed to some of the alternatives, which go by: &quot;My son-in-law wrote a great interpreter, it just needs a few more features&quot;... </li></ul></ul><ul><ul><li>Break the development cycle: “write-compile-package-deploy-test” no longer applies </li></ul></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  14. 14. Multi Language JVM <ul><li>Downsides: Language-VM Mismatch Translation Artifacts Semantic Mismatch Performance Conservatism </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  15. 15. Market Considerations <ul><li>Blogosphere != Real World </li></ul><ul><li>Language developers: High rollers involved: Former-Sun, Oracle, IBM, ... </li></ul><ul><li>Heavyweight users: Telco’s, Insurance, Billing, Banking, Financial... </li></ul><ul><li>Various Technologies: APIs, libraries, open source projects - these will not convert overnight </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  16. 16. Java Language Centric Approach <ul><li>On the other hand, some claim the opposite: Take Java and throw away the runtime </li></ul><ul><li>GWT : runs Java on Javascript engine </li></ul><ul><li>Android : runs Java on Dalvik </li></ul><ul><li>Alternative VMs : IBM, Oracle, OpenJDK, ... </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  17. 17. Language Characteristics <ul><li>Polyglot Programming? But how to pick the right tool for the right job? </li></ul>JVM Ports? Homegrown ? Dynamic? Static? Old? New? Renewed? Functional? OO? Execution Environment? Frameworks? Hosted by Tikal www.tikalk.com Israel JBUG
  18. 18. Scala <ul><li>Scala is both OO and functional, while keeping a static type system (as c, c++, java, haskell, pascal...)‏ </li></ul><ul><li>It blends a number of modern language features, while maintaining close compatibility with Java. </li></ul><ul><li>Born on the JVM - Attractive to Java developers Tool support, Libraries </li></ul><ul><li>Strongly, statically typed </li></ul><ul><li>Used by ... </li></ul><ul><li>Initial Release: 2003 </li></ul><ul><li>Books: 6 </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  19. 19. Groovy <ul><li>“ An agile and dynamic language for the JVM” </li></ul><ul><li>Java code is valid Groovy... </li></ul><ul><li>JVM-friendly </li></ul><ul><li>Inspired by languages like Python, Ruby and Smalltalk </li></ul><ul><li>Part of the SpringSource portfolio </li></ul><ul><li>Grails web app framework: killer-app? </li></ul><ul><li>Initial Release: 2004 </li></ul><ul><li>Books: 8 </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  20. 20. Ruby <ul><li>Extremely dynamic language </li></ul><ul><li>Strongly typed </li></ul><ul><li>Excellent DSL capabilities (Rails, Rake, Builders, ...)‏ </li></ul><ul><li>Initial Release: 1995! </li></ul><ul><li>Books: > 30 </li></ul><ul><li>Still, some performance issues (green threads on 1.8 interpreter)‏ </li></ul><ul><li>Still, mainly used for small web-apps... </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  21. 21. Python <ul><li>Modern, advanced OO language </li></ul><ul><li>Power tool language used for science, military... </li></ul><ul><li>Used massively by Google - both internally and on the GAE </li></ul><ul><li>Many software stacks, both web and full applicative </li></ul><ul><li>Concurrency capabilities </li></ul><ul><li>Initial Release: 1991 </li></ul><ul><li>Books: 12 </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  22. 22. Clojure <ul><li>Dynamic programming language that targets the JVM </li></ul><ul><li>Multithreading capabilities (multi-cores etc.)‏ </li></ul><ul><li>Lisp Dialect/Extension </li></ul><ul><li>Easy DSL creation </li></ul><ul><li>Initial Release: 2007 </li></ul><ul><li>Books: 1 </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG
  23. 23. Trends And Adoption Based on Tiobe index, May 2009 Hosted by Tikal www.tikalk.com Israel JBUG
  24. 24. <ul><li>Thank You! </li></ul><ul><li>[email_address] </li></ul> Hosted by Tikal www.tikalk.com Israel JBUG

×