Mojolicious

 view release on metacpan or  search on metacpan

lib/Mojolicious/Guides/FAQ.pod  view on Meta::CPAN


=encoding utf8

=head1 NAME

Mojolicious::Guides::FAQ - Frequently Asked Questions

=head1 OVERVIEW

This document contains answers for the most frequently asked questions about L<Mojolicious>.

=head1 QUESTIONS

We hope these answers are to your satisfaction.

=head2 How does Mojolicious compare to other Perl web frameworks?

The short answer is "it doesn't", because we interpret the term "web framework" much more literally than others. With
the emergence of the real-time web and new technologies such as WebSockets, we are facing new challenges that go way
beyond what commonly used modules like L<LWP> were designed for. Because of this, L<Mojolicious> contains a whole new
HTTP client/server stack called L<Mojo>, which was heavily inspired by the original LWPng effort and carefully designed
with these new requirements in mind. So while some of the higher abstraction layers might look similar to other web
frameworks, it is more of a web toolkit and can even be used as the foundation for more advanced web frameworks.

=head2 Why doesn't Mojolicious have any dependencies?

We are optimizing L<Mojolicious> for user-friendliness and development speed, without compromises. While there are no
rules in L<Mojolicious::Guides::Contributing> that forbid dependencies, we do currently discourage adding non-optional
ones in favor of a faster and more painless installation process. And we do in fact already use several optional CPAN
modules such as L<Cpanel::JSON::XS>, L<CryptX>, L<EV>, L<IO::Socket::Socks>, L<IO::Socket::SSL>, L<Net::DNS::Native>,
L<Plack> and L<Role::Tiny> to provide advanced functionality if possible.

=head2 Why reinvent wheels?

Because we can make them rounder. Components specifically designed for user-friendliness and development speed are not
easy to come by. We are strong believers of the Perl mantra "There is more than one way to do it", and our quest is to
develop the best possible solutions for these two criteria.

=head2 What about backwards compatibility?

In conformance with L<Mojolicious::Guides::Contributing>, we will always deprecate a feature for 3 months, before
removing or changing it in incompatible ways between major releases. New features can however be marked as experimental
to explicitly exclude them from these rules. This gives us the necessary freedom to ensure a healthy future for
L<Mojolicious>. So, as long as you are not using anything marked experimental, untested or undocumented, you can always
count on backwards compatibility, everything else would be considered a bug. However, to completely avoid any risk of
accidental breakage, we do recommend following current best practices for version pinning with L<Carton> for production
setups.

=head2 Why not split up Mojolicious into many smaller distributions?

Because there are no advantages, it drastically increases maintenance costs and installation times without giving us
anything in return. It would only make sense if we wanted to pass ownership of a module to a new maintainer, which we
already have done in the past.

=head2 Where can I discuss my patches for Mojolicious?

We'd love to discuss your contributions to L<Mojolicious> on L<IRC|https://web.libera.chat/#mojo>.

=head2 Which versions of Perl are supported by Mojolicious?

First of all, you need to be aware that according to the L<perlpolicy>, only the two most recent stable release series
of Perl are supported by the community and receive bug fixes, which are currently 5.32.x and 5.30.x. L<Mojolicious>
follows this model and fully supports these two release series. In addition we will also keep the distribution
installable (and that means passing all tests) up to a certain legacy version that the core team deems worthy of
supporting, but not specifically optimize for it, this is currently 5.16.0.

=head2 How well is Windows supported by Mojolicious?

Windows is not officially supported by L<Mojolicious>, even though we try to keep the distribution installable. There
may be serious security and/or reliability issues. Some of the more advanced features, such as
L<subprocesses|Mojo::IOLoop/"subprocess"> and the L<Hypnotoad|Mojo::Server::Hypnotoad> web server, will also require
the use of the L<Windows Subsystem for Linux|https://msdn.microsoft.com/commandline/wsl/>.

=head2 Is Perl's taint mode supported by Mojolicious?

No. There is no benefit at all to using taint mode. Modern Perl applications are much too complex to benefit from such a
naive mechanism in any meaningful way. At best it would give you a false sense of security.

=head2 Do I need to clean my environment before testing Mojolicious?

L<Mojolicious> uses many environment variables both internally and externally, notably (but not exclusively) those



( run in 0.583 second using v1.01-cache-2.11-cpan-524268b4103 )