DEV Community

John Napiorkowski
John Napiorkowski

Posted on

Perl PAGI Project Updates

Quick update to anyone interested in upcoming changes to the PAGI project (spiritual successor to Plack/PSGI).

1) Distribution split up: when we released PAGI, we initially released everything as one distribution. PAGI (https://metacpan.org/pod/PAGI) currently has a) the PAGI specification; b) the reference server and c) a bunch of ease of use tools, similar to the role that the Plack distribution played for PSGI. Putting everything into one place was just to make my life easier as in the early bunch of releases there was a lot of fixes and updates, most of which cut across all three parts of PAGI. Also I wanted to make it easy for people getting into PAGI to be able to explore the ecosystem. However now that code seems to be settling down having these in independent repos and releases makes more sense. Going forward the PAGI repo will only update if the spec itself changes; PAGI::Server and PAGI::Tools (where all the utilities and helpers now go) likewise. I think this will start to bring some stability to the ecosystem, especially now that PAGI::Server is functionally complete based on the goal chart I had for it initially. So I will only update it to fix bugs and security issues.

PAGI::Tools will probably continue to see evolution over the summer as I start to nail down more common use cases and identify patterns worth encapsulating.

2) Specification clarifications and updates: The PAGI specification itself will move to v0.3 in the next release and it contains mostly clarifications and fixes. Biggest change will be a more detailed mechanism for controlling streaming output, especially around handling back pressure as well as new callbacks to notice when the output buffer is getting full and when it clears. Hopefully these changes will make it easier and more reliable to do streaming in PAGI. PAGI::Server has been updated to match, and the response helper in PAGI::Tools has some updates around that as well.

Currently all this sits on Github:

https://github.com/jjn1056/pagi
https://github.com/jjn1056/PAGI-Server
https://github.com/jjn1056/PAGI-Tools

Right now I'm giving the Thunderhorse author some time to vet a handful of changes needed to be compatible and I want to review all the updates and doc tweaks one last time. This will land on CPAN before the Austin Perl Community conference first week of July (where I will be presenting on PAGI for those interested).
For people who might currently be depending on the PAGI distribution, for the near term I will have PAGI::Server and PAGI::Tools as dependencies of PAGI, that way your currently toolchains don't break. That will last a few months for transition.

Top comments (1)

Collapse
 
joel_horvath_0c470c6260a9 profile image
Joel Horvath

Nice, this is actually a pretty sane evolution of the ecosystem.
The split into spec / server / tools feels like it’s basically paying down hidden coupling that was temporarily useful early on.
Do you expect most users to ever directly depend on the spec, or will it stay more of a “read once, implement against it” thing?