Forum: Ruby on Rails Dynamic Config Plugin for Rails - recommendations??? (e.g. storing in database)

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
D5df9fcd7ef4c3c937435d7d6adeab2a?d=identicon&s=25 Greg Hauptmann (Guest)
on 2009-03-05 08:03
(Received via mailing list)
Wondering if there is an existing plugin/approach for config data that
you
want your application to be able to change?  In other words a value/pair
type configuration plugin that persists to the database.
Just a normal Model would be OK, however any neat tricks how to handle
the
fact that each parameter may be a different type?  e.g. have a column in
the
model to hold the type & store value as a string?  have a different
column
for each type but then any given parameter (or row in database terms)
would
populate only one of the columns?


--
Greg
http://blog.gregnet.org/
80e4cb97cae5c8d745f72337d93fd8f2?d=identicon&s=25 MaD (Guest)
on 2009-03-05 09:16
(Received via mailing list)
i don't know of any plugins, but i did the same thing once for a
project of mine. i used your first alternative. my configuration model
had only two attributes: "name" and "value". i only saved strings. for
config this was sufficient.
6883e5ef03484d4fcef507d7b4f1d243?d=identicon&s=25 Matt Jones (Guest)
on 2009-03-05 17:28
(Received via mailing list)
I've used the rails-settings plugin before - very easy to use, and
stores
settings as YAML, so they hold whatever datatype you put in.

http://github.com/Squeegy/rails-settings/tree/master

--Matt Jones


On Mar 5, 2:02 am, Greg Hauptmann <greg.hauptmann.r...@gmail.com>
This topic is locked and can not be replied to.