How can i have persistent objects in the server side?

G

gnufied

I am making a connection to a application server and getting some data
at a interval of 10 sec and all this is done in Ajax. Now the problem,
once i get the first cycle of data...my connection object dies...so for
the second connection request, which is invoked just 10 seconds after
first one...a new connection object is created and i don't really like
this.

The sad part...is i have defined already a wrapper around connection
class to make sure singleton patterns and all.but still the same thing.

Is there anyway...i can have persistent objects in the Apache Server
side.

I am uisng Ruby-1.8.4 and Rails-1.1.2.
 
L

loidee

there are a few solutions to this problem but without knowing the whole
story one solution to this would be to temporarily store the
information on the first request in the database in a simalar fashion
to storing session data when using multiple servers. if you wanted, you
could even store the information snippet as a simple flat text file.
hope this helps - if not give me some feedback and i will try to assist
further
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top