17 April 2014

The Ruby Reflector

Topic

Adapter

  Source Favicon
By Lucas Welch of Chef Blog 1 year ago.
Email

- Adapt to changes in cloud resource availability on the fly, all with only two system engineers

Of course, with Hosted Chef automating all the server configurations, HAWKEN launched without a hitch on 12.12.12. In fact, a single engineer delivered the entire production and staging infrastructure for the launch in only six hours . It would have taken five additional engineers to accomplish this feat without Chef.

Sarah Novotny, CIO at Meteor, had this to say:

" …

opscode.com Read
  Source Favicon
By Bryan McLellan of Chef Blog almost 2 years ago.
Email

[ OHAI-362 ] - TUN Adapter breaks Ohai Network

[ OHAI-369 ] - platform for 'mint' should be 'linuxmint'

[ OHAI-371 ] - Ohai fails to detect NetBSD operating system type

[ OHAI-378 ] - Ubuntu incorrectly identified as Debian

Improvement

[ OHAI-347 ] - Make primary IPv6 address easier to access

[ OHAI-354 ] - Add recognition of Omni-Os in platform …

opscode.com Read
  Source Favicon
By Peter Cooper of Ruby Inside over 2 years ago.
Email

Gregory Brown looks at seven structural design patterns laid out by the Gang of Four, the Adapter, Bridge, Composite, Proxy, Decorator, Facade and Flyweight.

'bundle exec rails' Executes Bundler.setup 3 Times

Rails core team member Santiago Pastorino notes that running 'bundle exec rails' is an inefficient mistake and explains why. ( TLDR: Just use 'rails', it'll work out the particulars.)

1 and 2 Letter Ruby Gems

rubyinside.com Read
  Source Favicon
By Gregory Brown of Practicing Ruby over 2 years ago.
Email

…code can avoid worrying about their individual differences. This is exactly the sort of thing the Adapter pattern is useful for.

Increasingly, Rubyists are finding this pattern to be useful in other settings as well. In particular, things like Intridea's multi_json gem allow libraries and applications to be built against an abstract interface rather than requiring some particular JSON library that might conflict with other dependencies. Inspired by the ideas behind multi_json, …

blog.rubybestpractices.com Read
  Source Favicon
By Gregory Brown of Practicing Ruby over 2 years ago.
Email

…code can avoid worrying about their individual differences. This is exactly the sort of thing the Adapter pattern is useful for.

Increasingly, Rubyists are finding this pattern to be useful in other settings as well. In particular, things like Intridea's multi_json gem allow libraries and applications to be built against an abstract interface rather than requiring some particular JSON library that might conflict with other dependencies. Inspired by the ideas behind multi_json, …

blog.rubybestpractices.com Read
  Source Favicon
Email

SQL Server on Windows: the latest ActiveRecord SQL Server Adapter, TinyTDS and FreeTDS are now included! TinyTDS is a project from Ken Collins that allows you to use FreeTDS to connect to Microsoft SQL Server databases. That is, everything you need to create Rails applications for your existing SQL Server database is included within RailsInstaller 2 for Windows!

Alternately you can continue using SQLite3 which continues to be packaged with …

engineyard.com Read
  Source Favicon
By Ken Collins of Engine Yard Developer Blog almost 3 years ago.
Email

Wayne E Seguin both TinyTDS and the SQL Server Adapter are included in the excellent RailsInstaller project, the easiest way to get up and running with Ruby on Rails for Windows. You can download the RailsInstaller for Windows 2.0.0 preview release now.

Share Your Experiences It is easy to see that as your application runs, a consistent pattern of SQL statements will emerge and their reuse from the plan cache will have a positive impact on the overall …

engineyard.com Read
  Source Favicon
By Assaf of Labnotes over 3 years ago.
Email

Vanity 1.4 introduces a lot of new features specifically around metrics and data storage.

Connection Adapters

First, connection adapters. Not just for Redis. Well, right now there are only two of them, one for Redis and one for MongoDB, but adding another database adapter is no longer a painful exercise.

In fact, here's your chance to help. Adopt An Adapter . Either write one from scratch, or take ownership of existing adapter and make it better/faster and help maintain it in future releases.

blog.labnotes.org Read
  Source Favicon
By kencollins of MetaSkills.net over 3 years ago.
Email

…in general. The next section is dedicated to RVM with the SQL Server Adapter stack. First, the :setup task, this is called before every other task. It simply sets up the load path so that the RVM API file can be required. That api file is located in your rvm repo path, typically in your ~/.rvm directory. Now every other task can use the RVM module which implements method missing for many commands.

Past this my rvm namespace is broken up into three main install tasks. The primary …

metaskills.net Read
  Source Favicon
By Stefano of DevInterface Blog almost 4 years ago.
Email

Below we'll follow the line traced by the GoF and we'll build an Adapter class that provides the play method needed by the PalConsole's interface:

1

2

3

4

5

6

7

8

9

10

11

#adapters.rb

class NtscToPalAdatper

attr_accessor :game

def initialize ( game )

@ game = game

end

def play

@ game . run

end

end

As you can see, the adapter exposes a simple play method that calls the run method of the NTSC Game.

The following code:

blog.devinterface.com Read