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

IRC log for #mojo, 2016-03-19

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

All times shown according to UTC.

Time Nick Message
00:06 Rubes joined #mojo
00:33 Rubes joined #mojo
01:04 genio slacker!
01:10 genio I hope my favorite character shows up soon (the hot nurse).
01:38 bpmedley joined #mojo
01:40 PryMar56 joined #mojo
01:47 Rubes joined #mojo
01:47 PryMar56 joined #mojo
01:47 melo joined #mojo
01:47 salva joined #mojo
01:47 anparker joined #mojo
01:47 simcop2387 joined #mojo
01:47 mdom joined #mojo
01:47 Grinnz joined #mojo
01:47 esh_ joined #mojo
01:47 cosimo joined #mojo
01:47 jnbek joined #mojo
01:47 matt_ joined #mojo
01:47 ncham joined #mojo
01:47 bjoernfan joined #mojo
01:47 skinch joined #mojo
01:47 haarg joined #mojo
01:55 Rubes joined #mojo
02:08 kaare joined #mojo
02:08 Grinnz IT'S SHANE
02:08 zivester joined #mojo
02:16 Rubes joined #mojo
02:20 sri i hated that actor
02:20 sri but he's good as punisher
02:31 ncham hey guys... I found this: http://mojolicious.org/perldoc/Mojo/IOLoop/Server but where can I find the documentation on whatever types $server and $handle are? (in the synopsis' call back I mean)
02:32 good_news_everyon joined #mojo
02:32 good_news_everyon [mojo] kraih pushed 1 new commit to master: https://git.io/vaPGJ
02:32 good_news_everyon mojo/master ced5972 Sebastian Riedel: better description for why app->start has to be the last expression
02:32 good_news_everyon left #mojo
02:33 bpmedley ncham : I think $handle is an IO::Socket::IP object
02:34 nchambers ok... is that what I would use to interact with the client connecting, in terms of sending and recieving data?
02:35 good_news_everyon joined #mojo
02:35 good_news_everyon [mojo] kraih pushed 1 new commit to master: https://git.io/vaPGs
02:35 good_news_everyon mojo/master 8710142 Sebastian Riedel: mention handle types
02:35 good_news_everyon left #mojo
02:36 mcsnolte joined #mojo
02:37 sri btw. it looks like bountysource is back in business, lets hope their troubles were only temporary
02:38 bpmedley nchambers : https://gist.github.com/brianmed/969ac29ebf0fe7d59843 <-- Try running this and telnet to port 3000
02:39 nchambers ok. thanks!
02:39 Grinnz sri, indeed (@ shane)
02:48 good_news_everyon joined #mojo
02:48 good_news_everyon [mojo] kraih pushed 1 new commit to master: https://git.io/vaPGb
02:48 good_news_everyon mojo/master 3864361 Sebastian Riedel: link to commands
02:48 good_news_everyon left #mojo
02:49 nchambers bpmedley, ok, so I've got this: but now how do I send the data I get from the client to all of the other clients? I assume I use server, I'm just not quite sure how
02:49 nchambers https://bpaste.net/show/961999e63021
02:51 bpmedley nchambers : If I understand you correctly perhaps you need something like https://github.com/preaction/Mercury
02:51 nchambers probably. I'm wanting to write a simple chat server in perl
02:52 sri nchambers: maybe use http://mojolicious.org/perldoc/Mojo/IOLoop#SYNOPSIS
02:55 sri if you're not dead set on creating your own protocol, maybe this works too? https://github.com/kraih/mojo/blob/master/examples/chat.pl
02:59 sri chat apps are very common https://github.com/kraih/mojo-pg/blob/master/examples/chat.pl
02:59 nchambers sri, thanks!
03:00 nchambers I kind of want to create my own protocol, otherwise I don't have much point in writing a server
03:37 noganex_ joined #mojo
03:40 Rubes joined #mojo
03:40 sri not liking this version of elektra though
03:48 genio finally finished the first episode
04:25 melo1 joined #mojo
04:31 melo joined #mojo
04:33 melo1 joined #mojo
04:38 melo joined #mojo
05:24 ichi joined #mojo
06:36 irqq joined #mojo
06:50 dod joined #mojo
06:55 dod joined #mojo
08:15 Vandal joined #mojo
08:58 ichi joined #mojo
09:41 mitya joined #mojo
09:58 Rubes joined #mojo
10:14 sugar joined #mojo
11:46 melo1 joined #mojo
11:59 melo joined #mojo
12:16 kes joined #mojo
12:38 melo joined #mojo
13:17 punter joined #mojo
13:18 punter I think I found a bug in Mojo::JSON::MaybeXS
13:19 punter It's here: http://paste.scsys.co.uk/508110
13:19 punter Grinnz: ^^
13:19 punter \!!0 encodes to null, not false
13:19 punter isn't that a bug?
13:19 punter Mojo::JSON is different
13:20 punter Maybe it's Cpanel::JSON::XS bug
13:20 punter I'll check
13:21 punter Cpanel says it can't encode anything other than \0 and \1
13:44 kaare joined #mojo
13:51 sugar joined #mojo
14:19 zivester joined #mojo
14:33 lluad joined #mojo
14:59 sri oracle must feel really threatened by postgres :) http://www.postgresql.org/message-id/CANNMO++6tPiwBv2OKcy-HhiYmByhL+XSSUH3NDvOs3G1VVg++g@mail.gmail.com
15:08 Rubes joined #mojo
15:22 irqq joined #mojo
15:22 s1037989 I'm using the example blog from Mojo-Pg.  Do you have to do anything to keep the websocket open (such as sending ping packets) or is that not necessary and I'm doing something wrong?
15:25 s1037989 Sorry I meant I'm using the example chat.pl from Mojo-Pg!  :D
15:26 pink_mist how are you using it? just running it under hypnotoad that you connect directly to?
15:27 sri yes, it's just a minimal example, you have to add stuff for keeping the connection open
15:27 s1037989 perl chat.pl daemon
15:27 pink_mist ah
15:27 sri and reconnect
15:28 s1037989 sri: Thanks!  Just what I need to know!  What does this do then?  $c->inactivity_timeout(3600);
15:28 s1037989 I thought maybe that'd keep the websocket open for an hour?
15:28 sri makes sure the connection does not get closed from the server side
15:29 s1037989 Ah ha!  So when the connection dies, it's the client's fault?
15:29 pink_mist if it takes less than an hour
15:30 s1037989 Ok!  So is the standard / preferred / best practice to keep the socket alive to send "ping" packets, or is there another way?
15:30 sri ping/pong is also important for detection connection losses
15:31 sri s/on/ng/
15:31 sri like cellphone reception being spotty
15:31 s1037989 Great!  Then I will do that.  Any suggestions for an existing javascript library to handle this?
15:32 sri with ping/pong you can detect it and reconnect quickly
15:33 sri this one seems popular https://github.com/joewalnes/reconnecting-websocket
15:33 s1037989 Awesome!  Thank you!!
15:34 sri the ping/pong itself is part of the protocol you're designing
15:42 pink_mist humm, is mojolicio.us down?
15:44 s1037989 pink_mist: Working for me!
15:44 pink_mist oh, it was because I tried using https
15:50 s1037989 So is this weird?  My websockets were working great, and then I reorg'd my routes and moved $r->websocket('/watch')->to('events#watch'); to the end.  Then my websockets broke.  Any reason why this needs to first, or not last?  All my other routes are get/post('/incoming')
15:54 s1037989 sri++ joewalnes ReconnectingWebSocket working like a champ!
16:19 jberger so I finally got $employer to agree to using postgres and ... well ... there is no sane HA deployment strategy that we can find
16:19 jberger which of course was their original fear
16:19 jberger I don't know if we are going to keep trying to go back to MySQL again
16:23 sri what did #postgresql say?
16:29 sri stuff like this doesn't seem too hard https://github.com/compose/governor
16:43 sri or if you want something with guarantees and support contracts there's always enterprisedb and citusdb
16:44 sri which are both pretty cool copanies from what i can see, contributing a lot back upstream to postgres
16:44 sri +m
16:44 jberger I don't think we came across that one
16:44 jberger but then again, I've looked at dozens, maybe I forgot that one
16:45 sri compose has a pretty good reputation, they were formerly known as mongohq :)
16:46 jberger I know our sysadmin is comfortable with haproxy
16:46 sri yea, good devops teams should love haproxy and etcd
16:48 Rubes joined #mojo
16:49 jberger we don't use etcd in our stack currently but I'm not opposed to it
16:49 jberger any time I read zookeeper though I get scared
16:49 sri hahaha
16:50 sri think marcusr has a lot of experience with etcd
16:51 sri at least i remember him saying how cool it is a few times
16:54 jberger you know what's funny is our devops guy is a total doppleganger for marcusr
17:14 sri clones?
17:14 sri maybe devops are like the norwegian version of storm troopers
17:16 bpmedley storm troopers with wild hair and swords
17:49 punter joined #mojo
18:01 ichi joined #mojo
18:09 go|dfish joined #mojo
18:11 dod joined #mojo
18:25 good_news_everyon joined #mojo
18:25 good_news_everyon [mojo] kraih pushed 1 new commit to master: https://git.io/vaXtx
18:25 good_news_everyon mojo/master 90e46d1 Sebastian Riedel: a few small documentation tweaks
18:25 good_news_everyon left #mojo
18:59 Rubes joined #mojo
19:36 dod joined #mojo
19:41 Grinnz joined #mojo
20:16 mfontani joined #mojo
20:32 Rubes joined #mojo
21:09 dvinciguerra joined #mojo
21:21 Grinnz_ joined #mojo
21:22 Rubes joined #mojo
22:02 Rubes joined #mojo
22:13 irqq joined #mojo
22:32 PanzerBjorn joined #mojo
22:34 PanzerBjorn Hey guys, quick question. I performed a server migration, installed the latest Mojo, made sure all my CPAN modules were in place, but when I launch morbo nothing happens. No log entries in my log directory either. "perl -cwT *.pm" reports all my module files with no errors... How can I dig deeper into why it's not starting?
22:34 PanzerBjorn I'm using the same /etc/init script for the new server as the old server, same paths for everything.
22:34 bpmedley PanzerBjorn : Are the shebang lines in Morbo the same?
22:34 PanzerBjorn What are shebang lines? ;D
22:35 bpmedley #!perl or #!/usr/bin/env perl
22:35 bpmedley The first line in the file
22:37 PanzerBjorn I tested morbo with a simple example script and it runs fine, it's not morbo.
22:37 PanzerBjorn Where does mojo dump pre-server errors and status?
22:37 bpmedley PanzerBjorn : What command are you using  for morbo?  Where is the app located you're trying to run?
22:39 PanzerBjorn In my mojo.conf file in /etc/init/ I'm lauhcing with: exec hypnotoad /var/www/mysite/mojo/script/start
22:39 bpmedley PanzerBjorn : You've mentioned morbo, mojo.conf, and hypnotoad.  I'm confused.
22:40 PanzerBjorn I tested my Mojo install using morbo. Works fine. I have a startup script in /etc/init/ called mojo.conf. I use hypnotoad as the production server.
22:41 bpmedley I'm still confused.  Earlier you said that when you launch via morbo nothing happens.
22:41 PanzerBjorn My bad. When I launch via hypnotoad.
22:42 bpmedley Is anything listening on that port already?
22:42 PanzerBjorn Alright, I tried running the line from the init file by hand and I see now that there's an error. Can't locate method "bridge" via Mojolicious::Routes
22:43 bpmedley https://github.com/kraih/mojo/wiki/Upgrading
22:44 bpmedley I'm not sure if you can just change "bridge" to "under".
22:44 PanzerBjorn Is under a 1:! replacement for bridge? No syntactic difference?
22:44 PanzerBjorn Yeah, that's my question.
22:46 PanzerBjorn Well, it's running now at least. Now to test it...
22:55 PryMar56 joined #mojo
23:11 bpmedley http://blog.wlindley.com/2016/03/03/using-mojolicious-templates-with-json/ <-- This is cool, anyone mentioned the blog post yet?
23:36 Rubes joined #mojo
23:38 sri bpmedley: that example actually has a bug
23:38 sri should be using Mojo::JSON::to_json
23:38 sri or you get double encoding problems with unicode chars
23:38 bpmedley Doh
23:39 elik joined #mojo

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