The web in a box - a next generation web framework for the Perl programming language

IRC log for #mojo, 2016-03-03

| Channels | #mojo index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:00 kaare joined #mojo
00:10 oalders i don't think there's any doubt that ratings can be manipulated
00:11 oalders if ask is willing to put some work into it, that won't help to motivate him
00:11 oalders i know when the ++ ratings got spammed a few years ago it annoyed and demotivated me
00:17 oalders installation instructions for dev CPAN Ratings site: https://github.com/perlorg/perlweb
00:30 sri oalders: that's not the same thing though, here you have personal attacks and a broken moderation system that makes them keep reappearing
00:30 sri oalders: i made one of the scripts used for the ++ spam back then, sorry about that, never intended to hurt you
00:33 sri it was after the manipulation was already very obvious though, think we upvoted some ACME module for laughs
00:49 * jberger ponders a comment to http://blogs.perl.org/users/kd/2016/03/not-so-new-shiny-things-lwpprotocolpsgi.html mentioning Test::Mojo and Test::Mojo::Role::PSGI
00:50 sri hehe
00:51 mattp sri: a simple moderator queue and one time passover of the review db is all thats needed to 'fix' ratings id say
00:51 Grinnz and who's going to do that?
00:52 jberger mattp: that still doesn't address some kind of TTL either
00:52 jberger There are rating on Mojo from pre 1.0
00:52 jberger Do any of those ratings truly apply anymore?
00:52 mattp fair point
00:53 sri clearly you have to put the version in the dist name, and nuke all history every now and then ;p
00:53 sri Mojolicious2
00:53 Grinnz heheh
00:53 pink_mist fork and rename entirely :P
00:53 pink_mist Srijolicious
00:54 Grinnz Motolicious
00:54 Grinnz (hopefully won't get sued by motorola)
00:54 jberger Who remembers the original spelling of "app->start"
00:54 jberger ?
00:54 jberger that's my vote for a new name
00:55 sri http://www.funnymeme.com/wp-content/uploads/2014/10/Dog-Memes-Lawyer-Dog.jpg
00:57 jberger http://alpha.zimage.com/~ant/antfarm/read/MontyPythonsFlyingCircus15SpanishInquisition.jpg
00:57 jberger Call the next Def End Ant!
00:58 sri you just can't stop with the monty python memes
00:58 jberger I love Monty python, I don't apologize
00:58 sri expand your horizon!
00:59 jberger http://www.funnyjunk.com/funny_pictures/1077423/Haters
00:59 sri lol
01:00 jberger Grr that one won't hotlink
01:00 sri http://new1.fjcdn.com/pictures/Haters_e55eac_1076979.jpg
01:00 Grinnz This is why I skip every funnyjunk result in google images, along with giphy
01:01 Grinnz Giphy doesnt do stupid hotlinking stuff, it's just a stupid site
01:03 jberger Monty Python is on my mind though, the wife was just in a pit orchestra for Spamalot
01:04 Grinnz nice
01:08 jnbek joined #mojo
01:09 pink_mist Spamalot was great in swedish :P
01:09 pink_mist want to go see it in the UK as well, but doubt I'll get to it
01:18 jnbek joined #mojo
01:19 jnbek joined #mojo
01:31 sri talking about memes :O http://www.jtolds.com/writing/2016/03/go-channels-are-bad-and-you-should-feel-bad/
02:23 firnsy joined #mojo
02:26 mspo I agree with him
02:50 oalders sri: when i've got limited time to work on something and my attention is taken up with some kind of scripted exploit, it makes me less likely to spend my time on the project
02:50 oalders a patch would have been more helpful ;)
03:28 jb360 joined #mojo
03:51 noganex joined #mojo
03:56 mcsnolte joined #mojo
04:15 asarch joined #mojo
04:16 asarch How can you query the model using JavaScript?
04:20 Grinnz via your application
04:44 asarch How?
04:44 asarch I mean, using XMLHttpRequest?
04:44 asarch But even so, what about security?
04:54 preaction what about it?
04:54 preaction XMLHttpRequests are made with the same cookies (and thus mojolicious session) as all the rest of the requests
05:01 asarch And how do you "interact" with the model?
05:01 asarch Using a GET message?: /students/search?name=foo
05:01 asarch ?
05:02 preaction this is where a REST API might come in handy
05:02 asarch I was thinking using REST: /students.json and then just make a simple filtering with JavaScript
05:03 preaction a REST API is allowed to have query params. so it'd be: /students?name=foo
05:05 asarch Thank you!
05:05 asarch Thank you very much preaction :-)
05:25 inokenty-w joined #mojo
05:46 dabudabu Somehow I have a feeling that the guy just now won't exactly end up implementing the most secure system ever
06:54 dod joined #mojo
06:59 dod joined #mojo
07:24 jontaylor joined #mojo
07:29 good_news_everyon joined #mojo
07:29 good_news_everyon [mojo] kraih pushed 1 new commit to master: https://git.io/v2SX6
07:29 good_news_everyon mojo/master cd41372 Sebastian Riedel: a few small performance optimizations
07:29 good_news_everyon left #mojo
07:41 Vandal joined #mojo
08:21 trone joined #mojo
08:23 AndrewIsh joined #mojo
08:28 trone joined #mojo
08:30 klapperl joined #mojo
08:34 denny joined #mojo
08:40 coolo good morning - what's the easiest way to get the PID of the worker in the mojo::log output? i.e. how can I monkey patch that?
08:41 coolo (or rails has a unique id for each request - that would even be better)
08:42 coolo (X-Request-Id or :uuid in rails)
08:50 trone joined #mojo
09:15 acamari joined #mojo
09:59 bc547_ joined #mojo
10:01 jb360 joined #mojo
11:01 jontaylor joined #mojo
11:26 sue joined #mojo
12:40 sue joined #mojo
13:21 asarch joined #mojo
13:47 perlpilot joined #mojo
13:57 ramortegui joined #mojo
14:01 neilhwatson joined #mojo
14:15 orev joined #mojo
14:25 Grinnz coolo, $$
14:26 coolo Grinnz: you misunderstood the question. I want mojo::log to care about that
14:26 Grinnz https://metacpan.org/pod/Mojo::Log#format
14:27 coolo Grinnz: that's the answer I was hoping for. No idea why I didn't think about it before
14:28 Grinnz there are lots of options :)
14:34 coolo but there is no uuid, right?
14:36 Grinnz uuid of what?
14:37 gtodd joined #mojo
14:37 Grinnz the worker and jobs each have a unique id, sure...
14:37 coolo of the request. https://wearestac.com/blog/log-tagging-in-rails
14:37 Grinnz wait, you're not talking about minion
14:38 Grinnz dunno why i thought that :P
14:38 Grinnz I don't know of any id unique to each request, no
14:38 Grinnz you could generate one in a hook I suppose
14:38 coolo but the pid is good enough - the request id just makes it very easy to grep all logs for a specific request. with the pid it's a combination of grep and cutting. good enough
14:40 * gtodd vaguely recalls a super simple 5 line magic recipe for making a Mojo app display output from pretty much any old perl script
14:40 gtodd but I may have been dreaming ...
14:40 dvinciguerra joined #mojo
14:45 gtodd it felt like a "Mojolicious is -OFun - but don't try this in production!!"  hack  to replace STDOUT with STDMOJO :-)
14:49 mcsnolte joined #mojo
14:59 meshl joined #mojo
15:56 good_news_everyon joined #mojo
15:56 good_news_everyon [mojo] kraih pushed 1 new commit to master: https://git.io/v2Hna
15:56 good_news_everyon mojo/master 02d7ebf Sebastian Riedel: fix default value bug in val method of Mojo::DOM (closes #926)
15:56 good_news_everyon left #mojo
15:56 sri batman: it's the precedence thing we were wondering about when you committed it
15:57 sri (and then just ignored)
15:57 batman sri: sorry about that :(
15:59 sri we all missed that :)
15:59 Lee but it now has tests :)
15:59 sri also, yay for the latest 20+ core load tests https://github.com/kraih/mojo/issues/925#issuecomment-191667399
16:01 sri so, don't be afraid to set -c/clients to a low value to match the number of concurrent connections you're currently dealing with
16:02 sri actually a reasonable argument for using two hypnotoads with different configurations for http and websockets
16:03 sri if you're min/maxing
16:04 lluad joined #mojo
16:06 sri also glad the 6.52 changes are visible
16:08 sri jberger: i'm so curious what kind of performance gain we'll see on the framework benchmark with the correct configuration
16:09 sri {workers => `nproc`, clients => (256 / `nproc`) + 1, accepts => 0, requests => 10000}
16:21 dod joined #mojo
16:22 good_news_everyon joined #mojo
16:22 good_news_everyon [mojo] kraih pushed 1 new commit to master: https://git.io/v2HBS
16:22 good_news_everyon mojo/master f00cf2c Sebastian Riedel: do/while looks a little better
16:22 good_news_everyon left #mojo
16:28 PryMar56 joined #mojo
16:35 good_news_everyon joined #mojo
16:35 good_news_everyon [mojo] kraih pushed 1 new commit to master: https://git.io/v2HuB
16:35 good_news_everyon mojo/master 8806096 Sebastian Riedel: not just Mojo::IOLoop got a little faster
16:35 good_news_everyon left #mojo
16:44 bradjm joined #mojo
16:45 pink_mist friend of mine just bought a tshirt with this motif: http://imgur.com/2CzwdTs :P
16:52 * jberger remembers purl's 'why not zoidberg' factoid and weeps anew
16:59 Adura The image kind lessens the jew joke charm.
17:07 zivester joined #mojo
17:11 jberger I was just followed by someone on twitter and their top-image caught my eye
17:11 jberger https://twitter.com/Harrisonova
17:12 Grinnz_ hah
17:13 jberger a good case for the Mojo-as-a-toolkit argument too
17:15 meshl joined #mojo
17:29 sri wonder if there are ways for us to improve the curve https://github.com/kraih/mojo/issues/925#issuecomment-191873578
17:30 sri the main problem seems to be load distribution
17:36 sri makes sense that it degrades at 12 workers, since that's the number of cores
17:36 sri 24 is only the number of hyperthreads
17:53 disputin joined #mojo
18:06 sri the last part really bugs me https://github.com/CPAN-API/metacpan-web/issues/1653#issuecomment-191806296
18:06 sri if someone started giving all new odules bad ratings it would be devastating for CPAN
18:06 sri +m
18:07 sri it's just bad by design
18:11 genio Well, it seems like you've gotten a good discussion going (looking on the bright side).
18:16 jberger sri: maybe a rare blog post?
18:26 asarch joined #mojo
18:32 dvinciguerra joined #mojo
18:39 sri damn, that curve couldn't be cleaner https://github.com/kraih/mojo/issues/925#issuecomment-191905975
18:41 sri bottom line, hyperthreads are meh
18:42 trone joined #mojo
18:42 jberger oO
18:44 preaction afaik hyperthreading is just supposed to make it less costly to switch thread contexts in the cpu
18:51 mspo did yo utry to taskset?
18:51 mspo there's a lot of stuff about that in tuning memcached
18:59 sri interesting, epoll might increase performance further, because there's a load balancing components to it
19:00 sri not that i understand it completely yet
19:02 sri that's LIBEV_FLAGS=4
19:04 lluad Hyperthreading allows the CPU to make better use of available execution units. It can be quite helpful for some workloads, but it's mostly meh-to-negative.
19:05 sri 5000 extra rps is 5000 extra rps :)
19:07 sri or about 5-6% performance i think
19:14 jberger LIBEV_FLAGS=7 does the same when epoll is available though right?
19:14 * jberger digs through documentation
19:24 mspo are you using select() now?
19:26 jberger mspo: IO::Poll
19:26 jberger that's the default backend at least
19:28 Grinnz_ the default on linux is epoll
19:29 Grinnz_ $ perl -MEV -E'say EV::backend' => 4 (epoll)
19:31 mspo is that documented on IO::Poll?
19:32 Grinnz_ that has nothing to do with IO::Poll
19:33 Grinnz_ and also IO::Poll doesn't document much of anything anyway
19:35 sri we literally have to use IO::Poll internals to make it fast :)
19:35 sri https://github.com/kraih/mojo/blob/master/lib/Mojo/Reactor/Poll.pm#L52
19:36 Grinnz_ it's basically just using the XS wrapper of poll directly, without all of the garbage in IO::Poll :P
19:55 jberger wow, not only did Han shoot first, Han shot ONLY! https://twitter.com/TheWookieeRoars/status/705043238382604288
20:17 sri wow, i might have just learned a load balancing trick from libuv :)
20:18 sri they do usleep(1) in between accepts
20:38 pink_mist 0_o is that actually useful? 0_o
20:56 mitya joined #mojo
21:00 good_news_everyon joined #mojo
21:00 good_news_everyon [mojo] kraih pushed 1 new commit to master: https://git.io/v2Q2r
21:00 good_news_everyon mojo/master 85504fa Sebastian Riedel: the multi_accept methods do not serve a purpose anymore
21:00 good_news_everyon left #mojo
21:00 sri went with single_accept, and not as a command line option, but a listen location flag
21:00 sri myapp.pl daemon -l http://*:8080?single_accept=1
21:02 jberger I suspect that using single_accept would be a rare case?
21:03 sri yes
21:03 jberger then yeah, +1
21:03 sri i'm actually tempted just not to have that option at all ;p
21:03 sri but it helps with testing
21:08 good_news_everyon joined #mojo
21:08 good_news_everyon [mojo] kraih pushed 1 new commit to master: https://git.io/v2QVw
21:08 good_news_everyon mojo/master 89e7787 Sebastian Riedel: avoid warnings
21:08 good_news_everyon left #mojo
21:12 good_news_everyon joined #mojo
21:12 good_news_everyon [mojo] kraih pushed 1 new commit to master: https://git.io/v2Qww
21:12 good_news_everyon mojo/master 1757f4d Sebastian Riedel: the multi-accept test is a little too unreliable
21:12 good_news_everyon left #mojo
21:13 sri timing issue
21:41 good_news_everyon joined #mojo
21:41 good_news_everyon [mojo] kraih pushed 1 new commit to master: https://git.io/v2QXU
21:41 good_news_everyon mojo/master 660bd60 Sebastian Riedel: just use the loop
21:41 good_news_everyon left #mojo
21:56 sri hahahaha https://github.com/hanami/hanami/issues/512#issuecomment-187147041
21:56 sri welcome to the club ruby!
21:56 sri rhel now also removes core modules from ruby
22:00 preaction in rhel's defense, one should really explicitly declare even core dependencies. the dependency should just be automatically satisfied, which i suspect doesn't happen in ruby
22:00 preaction but then again, mangling software isn't something the os vendor should do...
22:01 jberger but in rhel's offense: DAMMIT RHEL LEAVE THE SHIT ALONE
22:01 jberger one of the many reasons that I think people who consider the os packager the final word to be totally crazy
22:05 jberger I really kinda want to comment
22:05 jberger someone stop e
22:05 jberger m
22:08 Grinnz_ for ruby, even more than perl, it would mean just leaving ruby out of any minimal image altogether
22:08 jberger but that's not his point
22:09 jberger they really do believe that slicing and dicing of a stdlib is their right as packagers
22:17 jberger oh gods it gets worse: https://github.com/hanami/hanami/issues/512#issuecomment-191991012
22:19 preaction it depends on what license is involved. Perl's license doesn't allow something packaged differently to be called "Perl", but of course that hasn't stopped anyone
22:22 Grinnz_ jberger: nice, so not specifying the dep means someone can specify an older version?
22:24 Grinnz_ sounds like ruby's gem system is more of a mess :s
22:27 mspo wasn't someone complaining about duplicate entries the other day? https://news.ycombinator.com/item?id=11217477
22:30 Grinnz_ o_0 thats bad if nginx is really doing that
22:31 jnbek joined #mojo
22:32 jberger mspo: that was Apache
22:32 jberger but ugh
22:32 Grinnz_ i kind of feel like I've seen apache do that too :/
22:33 good_news_everyon joined #mojo
22:33 good_news_everyon [mojo] kraih pushed 1 new commit to master: https://git.io/v2QFq
22:33 good_news_everyon mojo/master ccc5931 Sebastian Riedel: 100 keep-alive requests are more common
22:33 good_news_everyon left #mojo
22:35 Grinnz_ https://gist.github.com/thresheek/2fa6479ffb7aca710493 someone from nginx linked this "workaround" in the comments
22:43 meshl joined #mojo
22:43 cpan_mojo Mojolicious-Plugin-Util-RandomString-0.06 by AKRON https://metacpan.org/release/AKRON/Mojolicious-Plugin-Util-RandomString-0.06
22:53 jnbek joined #mojo
23:35 jberger this is often attempted but rarely so well executed: https://metacpan.org/pod/Sys::Syslog#THE-RULES-OF-SYS::SYSLOG
23:36 Grinnz_ heh

| Channels | #mojo index | Today | | Search | Google Search | Plain-Text | summary