From: Bill Atkins Date: 2005-01-13T12:58:40+09:00 Subject: Re: [ANN] Nitro + Og 0.8.0 This looks interesting, but is there any documentation on running the examples? I tried running the blog example (even though I couldn't set up the database), and got this error (on Win32): ---- ../../lib/og.rb:189:in `initialize': (eval):1:in `initialize': uninitialized con stant Og::Database::MysqlBackend (NameError) from ./config.rb:55:in `eval' from ../../lib/og.rb:189:in `initialize' from ./config.rb:55:in `new' from ./config.rb:55 from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in `re quire__' from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in `re quire' from app.rb:19 ----- I tried this with the database set to PostgreSQL and I got the error there as well, except with PostgresqlBackend instead of MysqlBackend (I don't have PostgreSQL installed). So how do I get the example to connect to the database and what kind of setup do I need to do to get the database ready for the example? Bill On Wed, 12 Jan 2005 22:06:17 +0900, George Moschovitis wrote: > Hello everyone, > > new versions of Nitro and Og were just released. > > Homepage: http://www.navel.gr/nitro > Download: http://www.rubyforge.com/projects/nitro > > A snapshot of the latest code. Cool new features, > many fixes and improvements in older features. Many thanks > to Michael Neumann for giving intelligent suggestions > and finding small bugs. > > Most notable additions: > > * New automatic validation system: > > class User > prop_accessor :name, :password, String > validate_confirmation :password > validate_length :name, :range => 2..12 > end > > u = User.new(...) > unless u.valid? > p u.errors.on(:name) > p u.errors[:password] > end > > * Programmatic xhtml rendering. This is an alternative > method of rendering that is usefull in building > components and helpers. This is a preview implementation. > > options = ['Male', 'Female'] > o.select(:name => 'sex') { > o.options(options, selected = 1) > } > > options = { 'Male' => 'm', 'Female' => 'f' } > o.select(:name => 'sex') { > o.options(options, selected = 1) > } > > o.html { > o.p(:class => 'header') { o.b('Hello') } > } > > * No global variables in Og. > > * Recoded Og to allow for future support of multiple databases > (even on different RDBMS systems) on a single application. > > * Improved Blog example demonstrates latest advancements. > (You have to drop the database of earlier versions!) > * More unit tests. > > * Supports Ruby 1.8.2 > > * Integrated extensions/dev-utils by Gavin Sinclair. > > * Integrated blankslate by Jim Weirich. > > * And many IMPORTANT bug fixes. > > Nitro is an efficient, yet simple engine for developing professional > Web Applications using the Ruby language. Nitro aims to provide a > robust infrastructure for scalable web applications that can be > distributed over a server cluster. However, Nitro can also power simple > web applications for deployment on intranets or even personal > computers. Nitro integrates the powerful Og Object-Relational mapping > library. > > Nitro is a multiparadigm application framework and will integrate ideas > from Rails, Wee, PHP, JSP and .NET > > Nitro integrates the Og (ObjectGraph) object-relational mapping > library. Og provides transparent serialization of object graphs to a > RDBMS backend. Unlike other similar libraries Og maps standard Ruby > objects to SQL tables and not vice versa. Og provides a meta language > to describe the relations between objects, a flexible and intuitive api > for querieng the database, raw access to the SQL language if needed > (for example to fine tune the automatically generated SQL tables, or > for custom queries), suports deserialization to Ruby objects or tuples, > automatically generates join tables for many_to_many relations > and provides a collection of usefull Mixins to synthesize common > Entities. > > Og is a combination of the best features of Active Record and the > former O-R mapping library included in Nitro (NDB). Adapters for > PostgreSQL and MySQL are included. > > I would really appreciate your suggestions, ideas and bug reports. I > hope this software will be useful for you. > > have fun, > George Moschovitis > > -- $stdout.sync = true "Just another Ruby hacker.".each_byte do |b| ('a'..'z').step do|c|print c+"\b";sleep 0.007 end;print b.chr end; print "\n"