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

IRC log for #mojo, 2016-12-26

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

All times shown according to UTC.

Time Nick Message
00:06 stryx` joined #mojo
00:11 howitdo joined #mojo
01:16 aborazmeh joined #mojo
01:34 bpmedley_ joined #mojo
01:41 EFknockr joined #mojo
01:41 EFknockr left #mojo
01:42 Adura Why didn't somebody tell me this earlier?!
01:43 genio Well, we _were_ going to make it a surprise for you for new year's..
01:43 genio it's ruined!
01:43 preaction i truly wonder what they'd do if they actually had someone ... notice them...
01:44 preaction i mean, i know people who have access to terabytes of throughput. i really wonder how big of a fraction of that it'd take to make that site go away...
01:46 Lee joined #mojo
01:55 SUPERNETS joined #mojo
01:55 SUPERNETS 4,3 THIS NETWORK IS BLOWJOBS! GET ON SUPERNETS FOR COLD HARD CHATS NOW
01:55 SUPERNETS 8,3 ITS DECEMBER 25th! MERRY FLOODMAS FROM SUPERNETS! SEE YA NEXT YEAR
01:55 SUPERNETS 0,3 IRC.SUPERNETS.ORG | PORT 6667/6697 (SSL) | #SUPERBOWL | IPV6 READY
01:55 SUPERNETS left #mojo
01:59 Adura AWS? hah.
02:40 kaare joined #mojo
02:47 Lee joined #mojo
03:05 inokenty-w joined #mojo
03:24 karjala Just curious: Is there an ORM library for Pg available that works non-blocking?
03:26 preaction not that i'm aware of. you can use DBIx::Class to generate SQL, and then use Mojo::Pg to retrieve hashes, but you can't then inflated into DBIx::Class::Row objects
03:26 preaction but if you don't care so much about the Row objects...
03:29 karjala DBIC could be patched to receive an extra "cb" parameter couldn't it?
03:30 karjala Doesn't seem too hard
03:34 karjala like $row->save(cb => sub {...})
03:35 preaction since DBI isn't itself async, at all, how would that work for all databases?
03:36 karjala it wouldn't work for all, just for some.
03:36 Grinnz the topic of async in DBIx::Class has been hotly discussed
03:36 karjala Is that a problem with the ORM policy?
03:36 karjala oh
03:36 Grinnz i know not of the results, but probably nothing so far
03:36 preaction that's a problem with DBI and DBIx::Class. there is no generic DBI async API at all, so even individual DBD that expose an async API do such in whatever way they feel like
03:37 Grinnz the DBD::Pg and DBD::mysql async apis are both kind of ugly
03:37 preaction i know that some group has linked DBIx::Class to Mojo::Pg async using undocumented/private DBIC APIs. i also know that you can do what i said to get most of the way there
03:38 Grinnz https://metacpan.org/pod/Mad::Mapper may also be a possibility in place of DBIx::Class, i believe it supports using the async api of Mojo::Pg etc
03:39 Grinnz obviously without the enormous featureset and reliability of DBIx::Class
03:40 karjala thanks
03:48 Lee joined #mojo
03:52 noganex joined #mojo
03:56 hernan604 joined #mojo
03:56 hernan604 sub startup { .... $self->helper( log => sub { Mojo::Log->new( path => 'mojo.log', level => 'debug' ) } ); }
03:56 hernan604 is this correct ?
03:57 hernan604 because seems it wont create the file when i $self->log->warn('anything') .... only creates the file if i $self->log->append('something')
03:59 preaction hernan604: no. $self->log( Mojo::Log->new( ... ) ); but also just $self->log->path( ... );
04:10 hernan604 it wont create the file
04:10 hernan604 only with ->append
04:11 preaction probably not until it needs to, which happens when you write a log
04:11 preaction why are you making a new log helper?
04:11 hernan604 no need to make a helper.. i just want to use ->log->warn('something');
04:11 hernan604 tested your method... but it doesnt create the file
04:12 preaction it absolutely does
04:12 hernan604 sub startup { $self->log->path( 'mojo.log' ); } .... then in controller: $self->app->log->warn('bla')
04:12 hernan604 cat mojo.log .. no such file
04:13 hernan604 however
04:13 hernan604 sub startup { $self->log->path( 'mojo.log' ); } .... then in controller: $self->app->log->append('bla')
04:13 preaction did that method even get called?
04:13 hernan604 cat mojo.log displays bla
04:13 preaction then i don't know what to tell you, because it works for me
04:14 preaction i literally just tested it even
04:14 preaction are you sure your log level is set to "warn" or lower?
04:15 hernan604 yes, but  must be missing something.. let me make a gist
04:21 hernan604 preaction: https://gist.github.com/anonymous/b2793006b202700ef83cee870d766237
04:21 hernan604 cat mojo.log
04:21 hernan604 perl test.pl ; cat mojo.log
04:22 hernan604 Mojolicious version 9999 required--this is only version 7.12.
04:22 hernan604 what am i missing? :p
04:24 preaction check what $self->home is set to, and then go find that file, i suspect
04:25 hernan604 nope
04:25 hernan604 not there
04:25 hernan604 bah
04:25 hernan604 no idea what is wrong
04:26 dantti_laptop|2 joined #mojo
04:27 dr_bibble joined #mojo
04:29 dr_bibble Hi all,
04:30 dr_bibble Anyone know of a link to the start configuration parameters for Mojo
04:32 dr_bibble Also, does $c->inactivity_timeout(newvalue) apply only to the current connection
04:32 dr_bibble i.e. would I need to save/restore that value for long running processes
04:35 dr_bibble Also does inactivity_timeout (when changed) also change the heartbeat_interval so the thread does not die
04:37 dr_bibble seems everyones  heartbeat_interval has expired; maybe its that time of year.
04:41 inokenty-w joined #mojo
04:49 Lee joined #mojo
05:04 dboehmer joined #mojo
05:34 howitdo joined #mojo
05:51 Lee joined #mojo
06:45 Vandal joined #mojo
06:52 Lee joined #mojo
07:27 hernan604 preaction: i was missing ENV{MOJO_LOG_LEVEL} = 'debug';
07:28 hernan604 seems Mojo::Tests define it as warn
07:39 hernan604 guys, is there some way to simulate a domain.tld in Test::Mojo ?
07:39 hernan604 ie my $t = Test::Mojo->new('MyApp', 'somesite.com');
07:40 preaction what do you mean by simulate a domain?
07:41 hernan604 i want to use same instance in 2 domains
07:41 hernan604 so i will resolve site.com to $domain_id
07:41 hernan604 or something
07:41 hernan604 and want to test it
07:42 preaction Test::Mojo uses the Mojolicious app directly. not a domain
07:42 preaction the Mojo::UserAgent object has a server() property to use when there is no other server
07:42 hernan604 right
07:42 hernan604 ok
07:42 preaction Mojolicious itself doesn't route using domains, so you'd have to set that up yourself somehow
07:43 preaction and either you'd use under, which is a terrible idea, or you'd use a reverse proxy, which is a better idea. if you use a reverse proxy, then Mojolicious is still not routing by domain
07:44 preaction if you're using under() and the Host header, then you can send in the Host header when making the request via the Test::Mojo object
07:44 hernan604 hmm that could work
07:44 hernan604 =D
07:45 preaction i did mention it was a terrible idea, right?
07:46 hernan604 :p
07:46 preaction how are these two domains so closely-linked that they need to be in the same running Mojolicious app, but cannot have their routes reachable by the other domain?
07:46 hernan604 maybe site1.domain.com site2.domain.com
07:47 preaction that's not really an answer to my question
07:47 hernan604 they are not closely linked
07:47 hernan604 they are "independent" and completely dirent
07:47 preaction funny thing about dns is that the situation you described implies absolutely no relationship between those two things
07:48 preaction so, i would make those two separate mojolicious instances then
07:53 Lee joined #mojo
08:06 dod joined #mojo
08:11 dod joined #mojo
08:54 Lee joined #mojo
09:56 Lee joined #mojo
10:10 howitdo joined #mojo
10:18 polettix joined #mojo
10:53 polettix joined #mojo
10:57 Lee joined #mojo
11:06 sri https://twitter.com/kraih/status/813340164806344704
11:06 sri :)
11:07 Zen_ :D
12:15 dod joined #mojo
12:36 Lee joined #mojo
13:39 pink_mist happy birthday mojo! =)
13:56 aborazmeh joined #mojo
14:39 Dandre joined #mojo
14:40 gryphon joined #mojo
14:42 kaare joined #mojo
14:52 stryx` joined #mojo
14:55 khfeng joined #mojo
15:19 ilainftw joined #mojo
15:41 asarch joined #mojo
16:42 dikim joined #mojo
16:51 kes joined #mojo
16:56 kes Can not find doc for proper way to change validation object. May you advice something?
17:11 howitdo joined #mojo
17:16 howitdo joined #mojo
17:31 sugar joined #mojo
17:33 polettix joined #mojo
18:06 sh14 joined #mojo
18:10 PryMar56 joined #mojo
20:44 sugar joined #mojo
21:10 howitdo joined #mojo
21:14 jnbek joined #mojo
22:30 sugar joined #mojo
22:41 skaji joined #mojo
22:46 Lee joined #mojo
23:16 howitdo joined #mojo
23:22 batman joined #mojo

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