Hello Jon and all :)
I am hopelessly lost when trying setup my Poet application for deployment
(production env). Looking for some advices from someone who **really** using
Poet app under heavy load (e.g. not “plackup”, but starman or such)...
If I understand right, the the “bin/run.pl” is only for “playing” (development)
mode, it uses Poet::Server for
- preload modules from the poet’s config
- run plackup with the port defined in the
conf/layer/{development,deployment}.cfg
Q1: How to setup poet app to do the above but with starman? Need I write my own
“run.pl” or is here something in config what allows me run poet app under
starman and will do the “preload modules” too?
Next: In the poet.conf i could setup some log:* things. These are only for
custom logging for Poet application and has nothing with the “plackup/startman”
logging format. Right? or I again missed something? e.g. plackup defaultly
enables “Plack::Middleware::AcessLog with the “default” (format => '%h %l %u %t
"%r" %>s %b "%{Referer}i" "%{User-agent}i”';)
So Q2: Is possible do define access-log logging format in the poet’s conf what
would be passed to the underlaying http-server? (plackup or starman)?
When I trying to run poet app in production mode (by setting layer: production
in local.cfg), the Poet::Server try starting plackup as following:
Running plackup, -E, production, --port, 5000, --access_log,
/path/to/myapp/logs/access.log, /path/to/myapp/bin/app.psgi
AFAIK the "—access_log” is WRONG and should be “—access-log” - e.g. with dash
and not with underscore. According to the plackup documentation
(http://search.cpan.org/~miyagawa/Plack-1.0033/script/plackup
<http://search.cpan.org/~miyagawa/Plack-1.0033/script/plackup>) this is
definitely a bug, and In the current form the plackup didn’t logging anything
to the /path/to/myapp/logs/access.log. (Strange than nobody figured out this
before, therefore I the beginning of this question I asking about someone who
**REALLY** using Poet app in production environment.) :)
easy to reproduce:
$ poet new myapp
edit the myapp/conf/local.cfg - set “layer: production”
$ myapp/bin/run.pl
will start “plackup” with args as above and will log nothing...
So finally - could someone give some good advices running Poet app in
production environment, using the GREAT poet’s confing file features and like
but with “starman” and/or with “Server::Starter”...
Thanx in advance…
jm.
Ps: wondering why poet using for the layer definitions the word “production”
instead of the default plackup’s “deployment” keyword.
------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk
_______________________________________________
Mason-users mailing list
Mason-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mason-users