Skip to content

Latest commit

 

History

History
45 lines (30 loc) · 1.55 KB

README.md

File metadata and controls

45 lines (30 loc) · 1.55 KB

Handler Examples

A collection of crates that provide examples of handlers, the primary building block of a Gotham web framework application.

A Handler is an asynchronous function, taking a State value which represents the request and related runtime state. It completes by resolving to a HTTP response.

Developers working with the Gotham web framework create handlers and via the Router map them to individual routes. The Router then invokes the appropriate Handler to process incoming requests.

Ordering

We recommend reviewing our handler examples in the order shown below:

  1. Request Data - Accessing common request information
  2. Stateful Handlers - Keeping state in a handler
  3. Simple Async Handlers - Async Request Handlers 101
  4. Simple Async Handlers (.await version) - Request Handlers that use async/.await
  5. Async Handlers - More complicated async request handlers

Help

You can get help for the Gotham web framework at:

License

Licensed under your option of:

Community

The following policies guide participation in our project and our community: