An all Perl APM for Mojolicious, Plack, and Dancer2
- Login to SlapbirdAPM
- Sign-in with an OAuth2 provider
- Create an application, and copy your API key
- Install
SlapbirdAPM::Agent::Mojo
via CPAN - Add the following line to your application
plugin('SlapbirdAPM', key => "$YOUR_API_KEY")
- Optionally, use
plugin('SlapbirdAPM')
and theSLAPBIRDAPM_API_KEY
env var, instead
- Perl >=
5.36
podman
- cpanminus ie
cpan -I App::cpanminus
cp .env.example .env
vim .env # fill out the GITHUB_* fields with OAuth app information: https://github.com/settings/developers
bin/podman_dev_db
bin/podman_dev_memcached # optional
bin/run_migrations up # you may have to wait for the database to begin accepting connections
bin/install_deps
morbo app.pl
note: morbo
will hot-reload the app on changes.
bin/podman_dev_db
bin/podman_dev_memcached # optional
bin/run_migrations up # you may have to wait for the database to begin accepting connections
morbo app.pl
note: morbo
will hot-reload the app on changes.
prove -rlv -Ilib t/
Perl code is to be formatted with the .perltidyrc
in the root of the project, Perl::Critic
with PBP
is to be followed as well. If you need to break a Perl::Critic
rule, leave a comment ie:
## Disabled because ...
## no critic [foo]
All PR's should be submitted as a single commit.
All agents are available in the agent/
directory.
cd agent/mojo
perl Makefile.PL
make
make test
cd agent/mojo
perl Makefile.PL
make
make test
make install
Then when you run a local application using the agent, to hit your local SlapbirdAPM instance add the following environment variables:
SLAPBIRD_APM_DEV=1
SLAPBIRD_APM_URI=http://localhost:3000
If you don't set these, your agent will hit production instead. (You'll see 401's if you made your API key locally and forgot to set these)
SlapbirdAPM © Mollusc Labs Inc. 2024
SlapbirdAPM web application is provided under the GNU Affero General Public License version 3.0.
SlapbirdAPM agents are provided under the MIT license.