JRuby: What's Different (RORO Melbourne October 2011)

1,046 views
949 views

Published on

Presentation delivered to the Melbourne RUG on JRuby.

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
1,046
On SlideShare
0
From Embeds
0
Number of Embeds
3
Actions
Shares
0
Downloads
7
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • JRuby: What's Different (RORO Melbourne October 2011)

    1. 1. Whats Different About JRuby? Charles Oliver Nutter @headius
    2. 2. Whats Different About JRuby? (and why should you care?)
    3. 3. JRubyRuby on the JVM
    4. 4. JRubyStarted in 2001
    5. 5. JRubyFast and compatible
    6. 6. JRubyContributors all over the world
    7. 7. JRubyAwesomesauce!
    8. 8. Install JRubyrvm install jruby ; rvm use jruby
    9. 9. Install JRubyDownload tar/zip from jruby.org Unpack archive Add to PATH
    10. 10. Install JRubyWindows installer at jruby.org
    11. 11. Get the Book
    12. 12. Whats Different?
    13. 13. The Bad
    14. 14. Memory Footprint
    15. 15. Memory Footprint Base memory size is larger(Footprint over time is smaller)
    16. 16. Memory Footprint Objects are larger
    17. 17. Memory Footprint Objects are larger(But instance var table is smaller)
    18. 18. Missing or Disabled Features
    19. 19. Missing or Disabled Features No Kernel#fork
    20. 20. Missing or Disabled Features No continuations (callcc)
    21. 21. Missing or Disabled Features No continuations (callcc) (except for specific forms)
    22. 22. Missing or Disabled Features ObjectSpace off by default (-X+O to enable)
    23. 23. Missing or Disabled Features set_trace_func off by default (--debug to enable)
    24. 24. C Extensions Shipped in JRuby 1.6,still considered experimental
    25. 25. The Good
    26. 26. Ruby Itself
    27. 27. Ruby ItselfRuby 1.8.7 and 1.9.2 in the box
    28. 28. 28
    29. 29. 29
    30. 30. Ruby Itself Multi-VM support(many apps in one process)
    31. 31. 31
    32. 32. Ruby ItselfSolid across platforms
    33. 33. Ruby Itself Solid across platforms(Best Ruby on Windows?)
    34. 34. Ruby Itself Solid across platforms(Best Ruby on OpenVMS?)
    35. 35. Ruby Itself Solid across platforms(Best Ruby on zLinux?)
    36. 36. Java Virtual Machine (JVM)
    37. 37. Java Virtual Machine (JVM) Java libraries like Swing (or Scala, Groovy, Clojure, etc)
    38. 38. 38
    39. 39. 39
    40. 40. 40
    41. 41. 41
    42. 42. Java Virtual Machine (JVM) Tools like VisualVM
    43. 43. 43
    44. 44. 44
    45. 45. 45
    46. 46. 46
    47. 47. 47
    48. 48. 48
    49. 49. 49
    50. 50. Java Virtual Machine (JVM) Best garbage collectors
    51. 51. Java Virtual Machine (JVM) Optimizing JIT compiler
    52. 52. Java Virtual Machine (JVM) Concurrent threading
    53. 53. 53
    54. 54. 54
    55. 55. 55
    56. 56. 56
    57. 57. 57
    58. 58. 58
    59. 59. Java Virtual Machine (JVM) New dynamic dispatch support (invokedynamic)
    60. 60. 60
    61. 61. 61
    62. 62. Ruby = Method Calls Lots and lots and lots and lots...
    63. 63. def foo barenddef bar baz foo bar bazenddef baz # ...end
    64. 64. def foo JRuby on Java 5/6 barenddef bar JRuby JRuby baz foo call bar call bazend logic logicdef baz # ...end Kills many JVM optimizations
    65. 65. def foo JRuby on Java 7 bar X Xenddef bar JRuby JRuby baz foo call bar call bazend logic logicdef baz # ...end Dynamic call logic built into JVM
    66. 66. def foo JRuby on Java 7 barenddef bar baz foo bar bazenddef baz # ...end Straight through dispatch path
    67. 67. def foo JRuby on Java 7 barenddef bar baz foo bar bazenddef baz # ...end Optimizations (like inlining) can happen!
    68. 68. Benchmarks!You know you love them.
    69. 69. A “Better” fib bench bench_fib_complex.rb 5 35
    70. 70. “Richards”bench_richards.rb 1000000
    71. 71. Red/Black Tree github.com/headius/redblack
    72. 72. Wait for it... Benchmarks are benchmarks.If you don’t like them, give us yours!
    73. 73. App Development
    74. 74. App DevelopmentTrinidad for command-line server gem install trinidad
    75. 75. App DevelopmentTorquebox for "Enterprise"
    76. 76. App DevelopmentWarbler for WAR/JAR files gem install warbler
    77. 77. App Development Engine Yard AppCloudengineyard.com/products/appcloud
    78. 78. App DevelopmentOther Java servers using Warbler
    79. 79. What It Means For You
    80. 80. What It Means For You Faster Ruby applications
    81. 81. What It Means For You Better tool ecosystem
    82. 82. What It Means For You Solid concurrent servers
    83. 83. What It Means For You A better Ruby experience!
    84. 84. Thank You!Charles Oliver Nutter @headius

    ×