ruote tmp/log_2013-01-18.html

2013-01-18 00:25:26 utc ypz I could not get to work for me, but pastebin works:
2013-01-18 00:25:53 utc ypz it is basically the gist sample code you gave me yesterday
2013-01-18 00:26:00 utc jmettraux ok
2013-01-18 00:26:54 utc jmettraux could you please try with adding :after_connect=>proc{|c| c.reconnect = true} to your Sequel.connect(...) ?
2013-01-18 00:27:24 utc ypz sure, one sec
2013-01-18 00:27:42 utc jmettraux weird, I thought one had to say adapter "mysql2" for mysql2 to kick in, ...
2013-01-18 00:28:19 utc jmettraux I tend to use the connection uris, like in :after_connect=>proc{|c| c.reconnect = true} so I'm not really sure
2013-01-18 00:29:50 utc ypz OH, I just switched to mysql from msyql2
2013-01-18 00:30:19 utc jmettraux but your error message was stating Mysql2, so I guess it's kind of automatic...
2013-01-18 00:30:59 utc ypz mysql2 doesn't like reconnect:
2013-01-18 00:31:01 utc ypz NoMethodError: private method `reconnect=' called for #<Mysql2::Client:0x007feceb0d9e10> (Sequel::DatabaseConnectionError)
2013-01-18 00:31:19 utc jmettraux ok, let's google for that
2013-01-18 00:31:48 utc ypz with mysql adapter, it works about half of the time
2013-01-18 00:31:53 utc jmettraux can't find much
2013-01-18 00:32:06 utc ypz without reconnect, mysql almost always give the error
2013-01-18 00:32:21 utc jmettraux what happens the other half of the time?
2013-01-18 00:32:48 utc ypz same error, lost connection duty query
2013-01-18 00:32:52 utc ypz during
2013-01-18 00:32:55 utc jmettraux could you please retry with :after_connect=>proc{|c| c.send(:reconnect=, true) }
2013-01-18 00:33:13 utc jmettraux (also I lost track: are you testing with or without fork?)
2013-01-18 00:34:16 utc ypz with fork
2013-01-18 00:34:24 utc jmettraux ok
2013-01-18 00:34:35 utc jmettraux what does the send/reconnect solution yield?
2013-01-18 00:37:22 utc ypz with send/reconnect, mysql adapter seems to be good, mysql2 still give the same error, though less frequent then without it
2013-01-18 00:37:47 utc ypz repeated about 10 times for mysql, not a single error
2013-01-18 00:38:14 utc jmettraux thanks
2013-01-18 00:38:31 utc ypz with mysql2 adapter, got error 2 out of 6 times
2013-01-18 00:38:35 utc jmettraux maybe the reconnect switch is completely different for mysql2
2013-01-18 00:38:46 utc jmettraux we would have to dig its documentation and code
2013-01-18 00:38:58 utc jmettraux btw, how do you fork?
2013-01-18 00:39:09 utc ypz yea, I'll stay with mysql adapter, not sure what's the difference between the two
2013-01-18 00:39:16 utc jmettraux ah sorry, seen
2013-01-18 00:39:36 utc jmettraux if you take some time to investigate mysql2, you might find a solution
2013-01-18 00:39:44 utc jmettraux and pass it here
2013-01-18 00:40:01 utc ypz sure, I'll spend some time on that
2013-01-18 00:40:40 utc jmettraux or simply connect after the fork
2013-01-18 00:40:58 utc jmettraux or avoid forking and start two workers
2013-01-18 00:41:05 utc jmettraux (two ruby processes)
2013-01-18 00:42:49 utc jmettraux but the reconnect feels good to have
2013-01-18 00:48:49 utc ypz you mean start workers from separate scripts?
2013-01-18 00:49:01 utc jmettraux or running the same script twice
2013-01-18 00:49:47 utc ypz OK, I'll try that
2013-01-18 00:50:32 utc jmettraux added a mention to the reconnect = true trick to the ruote-sequel readme:
2013-01-18 01:09:29 utc jmettraux ok, I have to switch office, no irc there, feel free to use the mailing list or the issue tracker, best regards, thanks for the feedback!
2013-01-18 01:10:11 utc ypz thanks