3.68.0.txt

doc/release_notes/3.68.0.txt
Last Update: 2023-05-05 09:16:51 -0700

New Feature

  • Roda.run in the multi_run plugin now accepts blocks, to allow autoloading of apps to dispatch to:

    class App < Roda
      plugin :multi_run
    
      run("other_app"){OtherApp}
    
      route do |r|
        r.multi_run
      end
    end
    

    With the above example, the block is not evaluated until a request for the /other_app branch is received. If OtherApp is autoloaded, this can speed up application startup and partial testing. When freezing the application (for production use), the block is eagerly loaded, so that requests to the /other_app branch do not call the block on every request.