jruby on rails, 2007

358 1.3K 0
jruby on rails, 2007

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

Thông tin tài liệu

this print for content only—size & color not accurate spine = 0.839" 360 page count EMPOWERING PRODUCTIVITY FOR THE JAVA ™ DEVELOPER Practical JRuby on Rails Web 2.0 Projects: Bringing Ruby on Rails to the Java ™ Platform Dear Reader, The book you’re holding in your hand right now introduces JRuby on Rails in a practical and easy style. The Ruby language and the Rails framework have been making waves in the developer world for a while now. JRuby is the next step in the evolution of Ruby. This book introduces Ruby, Rails, and JRuby; describes how you can use them to create exciting solutions that cross the chasm between the Java™ and Ruby languages; and also shows how you can revolutionize your web development in Java by making use of JRuby on Rails. In my opinion, JRuby is the one technology that is building bridges between the powerful Java platform and a more dynamic programmer experience. This is epitomized by JRuby on Rails, which gives you all kinds of new and important possibilities. Many current Java web frameworks are actively being inspired by the Rails developer experience, but none of them are even close yet. That’s why I wrote this book. I wanted to tell the world that there is a better alternative. I wanted to show in a clear and obvious way how you can make good use of these exciting technologies. I wanted to document JRuby but also provide practical examples that could be immediately applied. That’s why this book employs a project-driven approach. Most of the code introduced is part of one of the four systems that you build during the course of the book. After reading this book, you should be able to start a new project based on JRuby on Rails and take it all the way from inception to production. If you don’t know Ruby, you’ll be able to pick it up from this book. You’ll learn how to use the Rails framework to build web applications—and you’ll also learn how to apply these in a JRuby environment. Ola Bini JRuby Core Developer US $42.99 Shelve in Java Programming/ Development User level: Intermediate–Advanced Bini JRuby on Rails Web 2.0 Projects THE EXPERT’s VOICE ® IN JAVA ™ TECHNOLOGY Practical JRuby on Rails Web 2.0 Projects Bringing Ruby on Rails to the Java ™ Platform CYAN MAGENTA YELLOW BLACK PANTONE 123 C Ola Bini JRuby Project Lead/Core Developer Forewords by Pat Eyler and Martin Fowler, Chief Scientist, ThoughtWorks Companion eBook Available THE APRESS ROADMAP Beginning Rails Beginning POJOs The Definitive Guide to Grails Practical JRuby on Rails Web 2.0 Projects www.apress.com java.apress.com SOURCE CODE ONLINE Companion eBook See last page for details on $10 eBook version ISBN-13: 978-1-59059-881-8 ISBN-10: 1-59059-881-4 9 781590 598818 5 4 2 9 9 Learn and apply the new agile open source JRuby to bring your Ruby on Rails Web 2.0 code and projects into your enterprise Java ™ application stack and more. Practical [...]... days, it’s common to see JRuby developers hanging out on the rubinius IRC channel (#rubinius on freenode), the YARV developers are making appearances on both the rubinius and JRuby IRC channels, and so on The discussions between these different development groups have been great to sit in on I think you could even build a case that JRuby has helped spur Microsoft’s IronRuby With JRuby running on the JVM,... process) JRuby doesn’t support continuations Continuations are one of those features that are incredibly hard to implement on a system running on a virtual machine, such as Java Another reason for this decision is that it would be impossible to mix Java integration features with continuations If this debate interests you, there are many posts in the archives of both the Jruby- dev and Ruby-core mailing... get into some enterprise environments Even at my day job, where I’ve been pushing Ruby from day one, JRuby is making Ruby solutions possible in places it wouldn’t have gone on its own Pretty soon, JRuby will be our common gateway between the infrastructure world of quick Ruby scripting and the application world of large-scale Java apps It’s a future I’m looking forward to JRuby has been driving changes... Programming Ruby, Second Edition 317 The Ruby Way, Second Edition 317 Agile Web Development with Rails, Second Edition 317 xv 881-4 FM.qxd xvi 8/31/07 1:43 PM Page xvi ■CONTENTS JRuby 318 The JRuby Home Page 318 The JRuby Dev Mailing List... differentiates JRuby from Ruby In fact, we won’t look at much Java code in this book The presence of Java should be felt, but it won’t be obvious The importance of Java is as a platform, enabling other technologies running on top of it I assume that you know enough about Java already I’ll quickly introduce Ruby, Rails, and JRuby, though, mostly from a historical perspective The descriptions won’t contain any... as a framework doesn’t really contain anything new; what makes it special is that it combines several usage patterns and implementations of libraries in a productive way guided by some core philosophies One of these is “Don't Repeat Yourself” (DRY)—meaning that information should be located in a single, obvious place Even more important is “Convention over Configuration,” which means that you need... to convince my employer to start using Ruby As much as I’d like to attribute that to the growth of my persuasion capabilities, the real reason was much more about the rise of Rails At the time we decided to do a Rails spike, we faced a situation with resource and time limitations and needed to create a fairly simple database-backed web application We finally convinced everyone to do this using Rails,. .. with how file system operations work, but in most cases these parts don’t work well on Windows systems with MRI either There are currently plans to support an execution model that mimics the next big version of Ruby, called YARV (Yet Another Ruby VM) There is also talk of supporting rubinius execution 881-4 CH01.qxd 8/19/07 3:04 PM Page 5 CHAPTER 1 ■ INTRODUCTION Why JRuby on Rails? Now you know why... than Ruby 1.8.6 The raison d’être for 1.0 was compatibility However, while working on the interpreter and compiler, the core team laid down the foundations to build on and improve performance So, there seems to be no reason why JRuby can’t be much faster than it currently is, and also much faster than the C implementation The second problem with the current Ruby implementation is that the support for... no one has done what you’ve tried to do yet That never happens with Java anymore With Java, you usually have a good amount of libraries to use, and usually also commercial offerings So, when developing a new application it can be highly useful to do it with JRuby on Rails, but it’s also helpful to be able to fall back and use Java libraries from inside the application for certain functionality JRuby . Ruby from day one, JRuby is making Ruby solutions possible in places it wouldn’t have gone on its own. Pretty soon, JRuby will be our common gateway between. Practical JRuby on Rails Web 2.0 Projects www.apress.com java.apress.com SOURCE CODE ONLINE Companion eBook See last page for details on $10 eBook version ISBN-13:

Ngày đăng: 20/03/2014, 15:40

Mục lục

    Contents at a Glance

    Foreword by Pat Eyler

    Foreword by Martin Fowler

    About the Technical Reviewer

    A Brief History of Ruby

    A Brief History of Rails

    A Brief History of JRuby

    Why JRuby on Rails?

    Overview of the Book

    Project 1: The Store (Shoplet)

Tài liệu cùng người dùng

Tài liệu liên quan