loading libraries and passing objects between actions

hello all,

i'm starting on a rails app that will hopefully make machine maintenance
much easier at my work. i have a few general questions about what
approach to take in the design.

for each machine the app maintains, it loads a networking library,
connects to the machine and returns an object of that machine. commands
to that machine are run via instance methods of the object. different
machines use different versions of the networking library.

once i've created the machine object, how do i pass it back and forth
between actions? the rails documentation is very jumbled when it comes
to this.

-reid

save it as a global ?

i'd like to try to avoid having too many global variables. isn't there
a way to pass objects from action to action?

Roger Pack wrote:

i'd like to try to avoid having too many global variables. isn't
there
a way to pass objects from action to action?

global variables are a horrendously bad idea. If you want something to
persist across actions use the database, the session, memcached etc...
Fred

Frederick Cheung wrote:

It is possible, by storing it in one of those places I named. Maintaining large amounts of state across actions is not something web apps in general are good at.

Fred

Frederick Cheung wrote:

programming. is this not possible?

It is possible, by storing it in one of those places I named.
Maintaining large amounts of state across actions is not something web
apps in general are good at.

Fred

great. this is good info. thanks!