“Without understanding functional programming, you can't
invent MapReduce, the algorithm that makes Google so
massively scalable.”
“The Perils of JavaSchools” - Joel Spolsky - 29/12/2005
http://www.joelonsoftware.com/articles/ThePerilsofJavaSchools.html
“The terms Map and Reduce come from Lisp and
functional programming...”
“The Perils of JavaSchools” - Joel Spolsky - 29/12/2005
http://www.joelonsoftware.com/articles/ThePerilsofJavaSchools.html
“The very fact that Google invented MapReduce, and
Microsoft didn't, says something about why Microsoft is
still playing catch up.”
“The Perils of JavaSchools” - Joel Spolsky - 29/12/2005
http://www.joelonsoftware.com/articles/ThePerilsofJavaSchools.html
Codificadores
x
Desenvolvedores
“SOFT”WARE
AGILIDADE
Estamos “descobrindo” maneiras melhores
de desenvolver software na prática e
ajudando outros a desenvolver.
Big Design Up
Front
Big Design Up
Front
Escopo Fechado
Escopo Fechado
Faseamento em
Cascata
Faseamento em
Cascata
“Change Request”
“Change Request”
Ceticismo
Winston W. Royce - 1970
“I believe in this concept,
but the implementation
described above is risky
and invites failure.”
Winston W. Royce - 1970
“I believe in this concept,
but the implementation
described above is risky
and invites failure.”
Winston W. Royce - 1970
“I believe in this concept,
but the implementation
described above is risky
and invites failure.”
Winston W. Royce - 1970
RSpec
describe Product do
include ProductSpecHelper
before(:each) do
@product = Product.new
end
it \"should not be valid when empty\" do
@product.should_not be_valid
end
it \"should be valid when having correct information\" do
@product.attributes = valid_product_attributes
@product.should be_valid
end
end
RSpec
describe Product do
include ProductSpecHelper
before(:each) do
@product = Product.new
end
it \"should not be valid when empty\" do
rake spec
@product.should_not be_valid
end
it \"should be valid when having correct information\" do
@product.attributes = valid_product_attributes
@product.should be_valid
end
end
Rotas RESTFul
ActionController::Routing::Routes.draw do |map|
map.connect ':controller/service.wsdl', :action => 'wsdl'
map.resources :products,
:member => {:change_image => :post}
map.resources :addresses
map.resources :orders,
:has_many => [:line_items]
map.namespace :admin do |admin|
admin.resources :users
admin.resources :products
end
end
Rotas RESTFul
ActionController::Routing::Routes.draw do |map|
GET /products/new
map.connect ':controller/service.wsdl', :action => 'wsdl'
GET /products
map.resources :products,
POST /products
:member => {:change_image => :post}
map.resources :addresses
GET /products/1
map.resources :orders,
GET /products/1/edit
:has_many => [:line_items]
map.namespace PUT /products/1
:admin do |admin|
DESTROY /products/1
admin.resources :users
admin.resources :products
end
end
Migrations
class RenameAppConfiguration < ActiveRecord::Migration
def self.up
rename_table :app_configurations, :configurations
change_table :configurations do |t|
t.string :type
end
end
def self.down
change_table :configurations do |t|
t.remove :type
end
rename_table :configurations, :app_configurations
end
end
Migrations
class RenameAppConfiguration < ActiveRecord::Migration
def self.up
rename_table :app_configurations, :configurations
change_table :configurations do |t|
t.string :type
end
rake db:migrate
end
def self.down
change_table :configurations do |t|
t.remove :type
end
rename_table :configurations, :app_configurations
end
end
11 mil classes!
46 só de
Collections!
http://weblog.jamisbuck.org/2008/11/9/legos-play-doh-and-programming
http://weblog.jamisbuck.org/2008/11/29/recovering-from-enterprise-video-available
• Classes:
• Modules: • Array
• Enumerable • Hash
• Comparable • Set
• Sorted Set
1.400Classes:
•
classes
• Modules: • Array
• Enumerable • Hash
• Comparable 6 deSet
só •
Collections! Set
• Sorted
• Convention over Configuration
• Don’t Repeat Yourself
• You Ain’t Gonna Need It
• Automação
• Boas Práticas
• Código Bonito
• Ferramentas Simples
To put things into
perspective, though,
Friendster was written in Java
to start, and switched to
PHP. Myspace was written in
ColdFusion and transitioned
to ASP.NET.
When people run into
problems scaling sites they
often think that the language
is the problem, but I think it’s
Blaine Cook
rarely the case.
http://www.akitaonrails.com/2008/6/17/chatting-with-blaine-cook-twitter
http://www.akitaonrails.com/2008/6/17/chatting-with-blaine-cook-twitter
“The New York Times used Ruby on Rails to pull
together, analyze and display election results in
near real time on one of its busiest Web
traffic days ever. ”
http://www.computerworld.com.au/article/268003/ruby_rails_rolls_into_enterprise?fp=16&fpid=1
http://www.computerworld.com/action/article.do?
command=viewArticleBasic&articleId=9120778
“They serve up 23 million visitors a month. The conversion resulted in 20,000 lines
of Ruby code instead of 125,000 lines of Java code, and most importantly eased
the difficulty they had in maintaining it. Once complete, and optimized their site
is now faster than before. They also completed the rewrite in three months with
four developers.”
http://www.railsonwave.com/railsonwave/2008/6/4/yellowpages-com-migrates-to-rails
http://www.akitaonrails.com/2008/11/21/rails-podcast-brasil-qcon-special-john-straw-
yellowpages-com-and-matt-aimonetti-merb
http://www.rubyonrailsexamples.com/sites-on-rails/yellowpagescom-goes-ror/
Adaptação da minha palestra na InfoQ e na Campus more
Adaptação da minha palestra na InfoQ e na Campus Party para o grupo .Net Architects que se encontra na Unip. http://www.dotnetarchitects.net/ Foi muito legal. less
0 comments
Post a comment