#rubyonrails - Wed 18 Apr 2007 between 15:52 and 16:01

NY Lost Funds



ErikR_*giggle*
RubyPantherlostkid: until you realize it's a bug, I don't see you can possibly fix it
lono: that should be able to do it, and there is a simpler one that's just for per-action times, too
AnalogHoleRubyPanther: sometimes refactoring can eliminate unknown bugs.
lostkidRubyPanther :you're saying that an instance is as method, i don't understood what was the bug line!
RubyPantherI just use one that measures my db query time
lostkid: no that is not what I am saying
ErikR_hmm.. you know what... the 2.5 seconds is not only 2000 laps in a loop, it is also parsing the excel sheet..
lonoRubyPanther: Well, what I'm looking for is somehting that could mesaure and cumulate the response sizes for each request, per user
RubyPanther: not the times
RubyPantherAnalogHole: yeah that's why *bsd have less bugs in the same userland applications compared to other *nixes. they obsessively refactor things that just "look sloppy"
lonoI got the time covered
lostkidRubyPanther: first of all: are we talking about this variable: @selected_action???
RubyPantherlostkid: yes
lono: can you just parse that out of the apache logs?
chellHi, I've got a question concerning the Agile book: current_item = @items.find {|item| item.product == product} the @items array contains CartItem objects. So in this case item refers to those objects right? So, the .product part of item.product references the product property of a CartItem object?
lonoRubyPanther: hmm
ErikR_I understand it that you expect the @selected_action to to be "preserved" between actions, lostkid ?
lostkidi want a way to do that, and from what i was reading in the books that was the way that i thought it could be done
ErikR_if you ask kindly, perhaps RubyPanther would let you use the session[ :selected_action ] = selected_action variant, lostkid
RubyPantherlol
ErikR_;)
lonoSo one more quick question since I'm here.. anyone seen their mongrels just grow and grow in size during the day?
lostkidi asked kindly, RubyPanther send me a link to read about instance variables that i've already read
lonoI had to put in a cron job to restart each mongrel instance in the middle of the night or else it would just suck memory until none would be left
that just doesn't seem normal
lostkidi don't understand why are you messing with me about this
ErikR_okay.. I suggest you take a look at the session hash too lostkid
RubyPantherno it was my intention that you would learn about instances in general
njerolostkid: okay this is the answer: you can access @varname from multiple functions in a class, yes. But the problem (ahem *bug) is that you are not calling both functions in the same instance. The controller class gets instantiated for EACH request... so when the update function is called it is part of the users request to the update url for which a separate instance is created... to get...
...around this you should use the session or store the value in the DB (which is more or less what the session does)
RubyPantherand OOP in general
mrballi1ok a bit out of topic but how does linux know where to find /etc/fstab when /etc/fstab defines / and thus its own location?
lostkidand i know to do what you kindly anwser me " session[ :selected_action ] = selected_action variant"
AnalogHolechell: item refers to an element of @items.. whatever it is. Though I would avoid that kind of find because it would incurr a SQL query for each item.product reference. Use item.product_id
ErikR_okay.. then the problem is solved, lostkid ? :D
yay
njeroRubyPanther was trying to help refine you question... in the way many folks in here do... teach to fish, blah blah :)
actionnjero hides from RubyPanther :)
njerohides from RubyPanther :)
lostkidyes, is solved, thank you very much njero, RubyPanther and ErikR_

Page: 1 8 15 22 29 36 43 50 57 64 71 78 85 92 99 106 113 120 

IrcArchive

NY Lost Funds