« Back to channel list

#RubyOnRails - 04 September 2018

« Back 1 day Forward 1 day »
[00:04:17] rhrf: has joined #RubyOnRails
[00:14:18] sevenseacat: has joined #RubyOnRails
[00:25:11] Cork: has joined #RubyOnRails
[00:28:36] howlcode: has joined #RubyOnRails
[00:39:53] iamdevnul: has joined #RubyOnRails
[00:41:20] Cork: has joined #RubyOnRails
[00:47:56] orpl: has joined #RubyOnRails
[00:49:50] orbyt_: has joined #RubyOnRails
[00:50:42] dviola: has joined #RubyOnRails
[00:50:59] danguita: has joined #RubyOnRails
[00:51:30] orpl: i've got a spec where i want to assert that calling some method calls another. Normally, `should_receive(:method_under_test).once` would be alright, but in the spec set up, :method_under_test is already being called once. what can I do to get around this? i was hoping for a change call count by 1 type of deal
[01:09:40] eckhardt: has joined #RubyOnRails
[01:14:36] unCork: has joined #RubyOnRails
[01:16:32] Guest58115: has joined #RubyOnRails
[01:31:19] jjman: has joined #RubyOnRails
[02:06:46] quazimodo: has joined #RubyOnRails
[02:07:35] eckhardt: has joined #RubyOnRails
[02:18:16] orpl: has joined #RubyOnRails
[02:29:24] fcser_: has joined #RubyOnRails
[02:30:58] kotepillar_: has joined #RubyOnRails
[02:47:54] mices: has joined #RubyOnRails
[02:48:59] mices: why would someone put `render :action => :show` inside the show action
[02:49:48] sevenseacat: to make it explicit.
[02:52:09] mices: sevenseacat ty
[02:58:20] Dimik: has joined #RubyOnRails
[03:03:09] kotepillar_: has joined #RubyOnRails
[03:11:59] braincrash: has joined #RubyOnRails
[03:16:33] kotepillar_: has joined #RubyOnRails
[03:17:11] Guest58115: has joined #RubyOnRails
[03:24:59] dionysus69: has joined #RubyOnRails
[03:29:57] kapil___: has joined #RubyOnRails
[03:35:20] mices: well i found what had broken mailboxer it wasn't my code it was the difference between rails 5.0.0 and 5.0.1
[03:35:50] mices: Radar Sevenseacat ^
[03:36:28] sevenseacat: good to know.
[03:47:49] duderonomy: has joined #RubyOnRails
[03:52:03] DTZUZO: has joined #RubyOnRails
[03:55:01] Johano: has joined #RubyOnRails
[03:55:10] Johano: has left #RubyOnRails: ("Leaving")
[04:15:35] Guest58115: has joined #RubyOnRails
[04:22:39] dionysus69: has joined #RubyOnRails
[04:26:49] Technodrome: has joined #RubyOnRails
[04:40:10] mices: emmezeta probably to comply with the validations in the models that control access to the database
[04:40:31] mices: or i dunno
[04:40:59] mices: the models can be full of statements to enforce data integrity
[05:03:35] hahuang65: has joined #RubyOnRails
[05:08:55] cschneid_: has joined #RubyOnRails
[05:20:41] danguita: has joined #RubyOnRails
[05:22:26] cschneid_: has joined #RubyOnRails
[05:46:50] dionysus69: has joined #RubyOnRails
[05:48:29] iamdevnul: has joined #RubyOnRails
[05:49:31] Mutsuhito: has joined #RubyOnRails
[05:50:10] mjacob: has joined #RubyOnRails
[05:50:48] Fire-Dragon-DoL: has joined #RubyOnRails
[05:50:51] lupine: has joined #RubyOnRails
[05:51:48] Avon: has joined #RubyOnRails
[05:51:54] umpc: has joined #RubyOnRails
[06:04:20] ariedler: has joined #RubyOnRails
[06:11:34] kapil___: has joined #RubyOnRails
[06:14:40] cschneid_: has joined #RubyOnRails
[06:32:58] voker57: has joined #RubyOnRails
[06:37:13] roshanavand: has joined #RubyOnRails
[06:37:18] lomex: has joined #RubyOnRails
[06:37:44] sandstrom: has joined #RubyOnRails
[06:42:59] ariedler: has joined #RubyOnRails
[06:43:49] reber: has joined #RubyOnRails
[06:44:57] cschneid_: has joined #RubyOnRails
[06:46:00] sandstrom: has joined #RubyOnRails
[06:50:02] kotepillar_: has joined #RubyOnRails
[06:50:36] srinidhi: has joined #RubyOnRails
[07:02:02] cschneid_: has joined #RubyOnRails
[07:08:43] roshanavand: has joined #RubyOnRails
[07:11:16] cschneid_: has joined #RubyOnRails
[07:18:31] kotepillar_: has joined #RubyOnRails
[07:24:23] cschneid_: has joined #RubyOnRails
[07:27:27] nemesit: has joined #RubyOnRails
[07:36:54] sameerynho: has joined #RubyOnRails
[07:41:36] cschneid_: has joined #RubyOnRails
[07:44:39] Applitect: Can anyone tell me how I can use find_by on a model to search for ids from an array? So the sql would be something like WHERE id IN (23, 45, 132). But I'd like to know the best way to pull this off in ruby / rails
[07:45:28] sevenseacat: where(id: [23, 45, 132)
[07:45:39] TvL2386: ^---- that
[07:46:35] Applitect: Ok cool. Thanks!
[07:47:41] Applitect: What if the array is an associative array?
[07:48:10] sevenseacat: no such thing in ruby
[07:49:08] Applitect: Trying to find the proper term.
[07:49:25] sevenseacat: you might be thinking of a hash
[07:49:38] Applitect: nested array
[07:49:52] Applitect: So said the ID is the first value of each item in the array
[07:50:06] sevenseacat: then get the IDs you want to query for out, and query for them
[07:50:31] Applitect: Would I use map to do that?
[07:51:03] sevenseacat: that depends on what your data looks like
[07:51:23] snickers: has joined #RubyOnRails
[07:51:55] sevenseacat: can you put together a gist of what you're trying to solve?
[07:56:11] LambdaSource: has joined #RubyOnRails
[07:56:12] Applitect: Actually I got it. Would look like my_array.map{|x| x[0]}
[07:56:59] sevenseacat: you could also write that as my_array.map(&:first) .
[07:57:16] Applitect: So in total it looks like MyModel.where(id: my_array.map{|x| x[0]})
[07:57:28] Applitect: I like your :first better though
[07:57:48] lexileo: has joined #RubyOnRails
[07:58:51] drale2k_: has joined #RubyOnRails
[07:58:57] mikecmpbll: has joined #RubyOnRails
[08:03:16] cschneid_: has joined #RubyOnRails
[08:05:29] sandstrom: has joined #RubyOnRails
[08:05:53] dionysus69: so I was reading this https://dockyard.com/blog/2016/08/09/phoenix-channels-vs-rails-action-cable
[08:06:00] dionysus69: and got worried about performance
[08:06:26] dionysus69: in my app I am sending making 5+ broadcasts per second hypothetically to all users
[08:06:37] dionysus69: the data I am sending is not large, small hash
[08:07:10] dionysus69: what should I expect, when will I see unacceptable performance and what can I do to improve it?
[08:07:39] sevenseacat: 5 per second? to every single user? yeeeeeah
[08:07:43] dionysus69: users need to be on a particular page though for the channel to open
[08:08:06] dionysus69: but still if let's say 500 users open it up, I should expect problems right?
[08:08:13] sevenseacat: keep in mind that is a two year old article.
[08:08:37] dionysus69: I did but still :) I am not worried about memory leak, but the latency
[08:09:53] dionysus69: I could artificially lower the frequency to like 5 broadcasts per 3/4/5 seconds but lower the better, still it's not a solution if I hypothetically get 10k users on that page
[08:11:03] sevenseacat: without knowing anything at all about your app, or your infrastructure, its impossible to give any guidance about what your performance might be like
[08:11:54] dionysus69: I use DO dropplets, 4 core cpu 8gb ram if that helps :D single app server atm but planning on expanding in near future when I have time
[08:12:42] dionysus69: I do use separate redis dropplet too :)
[08:14:55] dionysus69: sevenseacat: ok one last thing then, how do people test these stuff? I dont think opening 500 tabs would be the way
[08:15:19] sevenseacat: look up load testing.
[08:15:34] sevenseacat: I don't have any good resources off hand
[08:16:08] dionysus69: that's good enough :)
[08:20:45] cschneid_: has joined #RubyOnRails
[08:30:32] Guest58115: has joined #RubyOnRails
[08:31:49] lomex: has joined #RubyOnRails
[08:33:41] cschneid_: has joined #RubyOnRails
[08:46:52] cschneid_: has joined #RubyOnRails
[08:47:58] uks: has joined #RubyOnRails
[08:55:46] LambdaSource: has joined #RubyOnRails
[08:56:37] LambdaSource: has joined #RubyOnRails
[08:59:58] cschneid_: has joined #RubyOnRails
[09:02:19] hammer065: has joined #RubyOnRails
[09:12:56] cschneid_: has joined #RubyOnRails
[09:18:37] anikras: has joined #RubyOnRails
[09:23:35] drale2k_: has joined #RubyOnRails
[09:27:13] LambdaSource: has joined #RubyOnRails
[09:27:20] roshanavand: has joined #RubyOnRails
[10:02:59] drale2k_: has joined #RubyOnRails
[10:06:22] LambdaSource: has joined #RubyOnRails
[10:12:29] quazimodo: has joined #RubyOnRails
[10:23:07] bomb: has joined #RubyOnRails
[10:32:04] fcser_: has joined #RubyOnRails
[10:32:11] cschneid_: has joined #RubyOnRails
[10:40:17] GodFather: has joined #RubyOnRails
[10:44:01] ariedler: has joined #RubyOnRails
[10:44:58] cschneid_: has joined #RubyOnRails
[10:47:35] lankanmon: has joined #RubyOnRails
[10:51:29] LambdaSource: has joined #RubyOnRails
[10:55:07] ariedler: has joined #RubyOnRails
[10:58:02] cschneid_: has joined #RubyOnRails
[11:00:09] ams__: has joined #RubyOnRails
[11:02:09] ams__: has joined #RubyOnRails
[11:03:39] mostlybadfly: has joined #RubyOnRails
[11:11:14] cschneid_: has joined #RubyOnRails
[11:12:34] srinidhi: has joined #RubyOnRails
[11:18:40] Croata: has joined #RubyOnRails
[11:21:42] Ergo: has joined #RubyOnRails
[11:25:58] lexileo: has joined #RubyOnRails
[11:28:43] cschneid_: has joined #RubyOnRails
[11:38:57] roshanavand: has joined #RubyOnRails
[11:49:25] beholders_eye: has joined #RubyOnRails
[11:50:00] LambdaSource: has joined #RubyOnRails
[11:52:17] Kamuela: has joined #RubyOnRails
[11:54:49] cschneid_: has joined #RubyOnRails
[11:55:36] roshanavand: has joined #RubyOnRails
[11:59:17] beholders_eye: has joined #RubyOnRails
[12:07:47] cschneid_: has joined #RubyOnRails
[12:15:47] hfp_work: has joined #RubyOnRails
[12:20:51] cschneid_: has joined #RubyOnRails
[12:21:40] work_: has joined #RubyOnRails
[12:24:33] nemesit: has joined #RubyOnRails
[12:33:18] hfp_work: has joined #RubyOnRails
[12:39:44] quazimodo: has joined #RubyOnRails
[12:52:42] Lloyd: has joined #RubyOnRails
[12:55:42] dionysus69: has joined #RubyOnRails
[13:01:32] LambdaSource: has joined #RubyOnRails
[13:35:54] jane_booty_doe: has joined #RubyOnRails
[13:36:47] cschneid_: has joined #RubyOnRails
[13:39:25] dblessing: has joined #RubyOnRails
[13:40:17] spohnz: has joined #RubyOnRails
[13:54:11] Sylario: has joined #RubyOnRails
[13:57:48] LambdaSource: has joined #RubyOnRails
[14:19:07] cschneid_: has joined #RubyOnRails
[14:25:12] kotepillar_: has joined #RubyOnRails
[14:29:32] armyriad: has joined #RubyOnRails
[14:47:22] babykosh: has joined #RubyOnRails
[15:05:08] drale2k_: has joined #RubyOnRails
[15:12:11] tycoon177: has joined #RubyOnRails
[15:19:05] Technodrome: has joined #RubyOnRails
[15:23:12] dviola: has joined #RubyOnRails
[15:31:50] duderonomy: has joined #RubyOnRails
[15:40:26] quazimodo: has joined #RubyOnRails
[15:51:00] tycoon177: does memory usage scale 1:1 with the number of puma workers?
[15:51:44] dblessing: has joined #RubyOnRails
[16:07:26] [Butch]: has joined #RubyOnRails
[16:07:40] eckhardt: has joined #RubyOnRails
[16:13:44] aesthetikx: its supposed to be something like workers * threads / worker
[16:13:59] aesthetikx: workers * threads per worker , rather
[16:14:19] aesthetikx: that will tell you how many connections you need to db / redis actually, memory should be more like puma workers yeah
[16:19:30] srinidhi: has joined #RubyOnRails
[16:21:17] orbyt_: has joined #RubyOnRails
[16:30:19] LambdaSource: has joined #RubyOnRails
[16:38:16] Dbugger: has joined #RubyOnRails
[16:39:21] DTZUZO: has joined #RubyOnRails
[16:41:33] conta2: has joined #RubyOnRails
[16:45:14] LambdaSource: has joined #RubyOnRails
[16:53:15] rootsudo: has joined #RubyOnRails
[17:02:06] DTZUZO: has joined #RubyOnRails
[17:17:58] Kilo`byte: has joined #RubyOnRails
[17:26:52] DTZUZO: has joined #RubyOnRails
[17:27:45] GodFather: has joined #RubyOnRails
[17:28:18] Guest58115: has joined #RubyOnRails
[17:28:57] sandstrom: has joined #RubyOnRails
[17:30:27] duderonomy: has joined #RubyOnRails
[17:33:54] duderonomy: has joined #RubyOnRails
[17:34:16] defsdoor: has joined #RubyOnRails
[17:34:33] duderonomy: has joined #RubyOnRails
[17:36:08] duderonomy: has joined #RubyOnRails
[17:38:24] Guest58115: has joined #RubyOnRails
[17:47:01] samort7: has joined #RubyOnRails
[17:48:18] Guest58115: has joined #RubyOnRails
[17:58:30] Guest58115: has joined #RubyOnRails
[18:15:11] duderonomy: has joined #RubyOnRails
[18:28:26] Xiti: has joined #RubyOnRails
[18:38:32] ShekharReddy: has joined #RubyOnRails
[18:43:11] cschneid_: has joined #RubyOnRails
[18:43:14] Guest58115: has joined #RubyOnRails
[18:44:58] mikecmpbll: has joined #RubyOnRails
[18:53:13] Guest58115: has joined #RubyOnRails
[19:00:01] beholders_eye: has joined #RubyOnRails
[19:03:28] Guest58115: has joined #RubyOnRails
[19:13:15] Guest58115: has joined #RubyOnRails
[19:14:38] weaksauce: has joined #RubyOnRails
[19:23:14] Guest58115: has joined #RubyOnRails
[19:24:36] lomex: has joined #RubyOnRails
[19:31:10] cschneid_: has joined #RubyOnRails
[19:33:17] Guest58115: has joined #RubyOnRails
[19:42:34] phon: has joined #RubyOnRails
[19:43:19] Guest58115: has joined #RubyOnRails
[19:53:24] Guest58115: has joined #RubyOnRails
[19:59:28] lomex: has joined #RubyOnRails
[20:03:18] Guest58115: has joined #RubyOnRails
[20:04:24] sameerynho: has joined #RubyOnRails
[20:11:41] quazimodo: has joined #RubyOnRails
[20:12:41] desperek: has joined #RubyOnRails
[20:13:18] Guest58115: has joined #RubyOnRails
[20:15:00] aeffle: has joined #RubyOnRails
[20:15:56] nottwo_: has joined #RubyOnRails
[20:22:48] lomex: has joined #RubyOnRails
[20:28:53] orbyt_: has joined #RubyOnRails
[20:35:13] samort7: has joined #RubyOnRails
[20:35:32] phon: has joined #RubyOnRails
[20:37:05] ellcs: has joined #RubyOnRails
[20:49:10] phon: has joined #RubyOnRails
[20:49:36] WA9ACE: has joined #RubyOnRails
[20:54:40] nottwo: has joined #RubyOnRails
[21:07:45] jane_booty_doe: has joined #RubyOnRails
[21:18:57] beowuff: has joined #RubyOnRails
[21:28:49] dblessing: has joined #RubyOnRails
[21:40:22] MasterAsia: Will changing a string column to a text column wipe column data?
[21:40:37] MasterAsia: Or is rails smart enough to keep the information
[21:47:57] lomex: has joined #RubyOnRails
[21:56:02] blackjid: has joined #RubyOnRails
[22:01:31] eckhardt: has joined #RubyOnRails
[22:03:30] ellcs: has joined #RubyOnRails
[22:16:22] apeiros: has joined #RubyOnRails
[22:17:18] Guest58115: has joined #RubyOnRails
[22:21:47] nertzy: has joined #RubyOnRails
[22:22:04] mices: has joined #RubyOnRails
[22:25:09] SteenJobs: has joined #RubyOnRails
[22:37:43] dionysus69: has joined #RubyOnRails
[22:39:31] eckhardt: has joined #RubyOnRails
[22:40:38] orbyt_: has joined #RubyOnRails
[22:41:18] Technodrome: has joined #RubyOnRails
[22:45:43] DTZUZO: has joined #RubyOnRails
[22:59:37] lomex: has joined #RubyOnRails
[23:03:03] eckhardt: has joined #RubyOnRails
[23:04:16] duderonomy: has joined #RubyOnRails
[23:09:01] ivanskie: has joined #RubyOnRails
[23:11:00] stabe: has joined #RubyOnRails
[23:12:18] quazimodo: has joined #RubyOnRails
[23:24:17] daemonwrangler: has joined #RubyOnRails
[23:53:59] SteenJobs: has joined #RubyOnRails