Skip to content

Review how HTTP parsing is affecting performance  #18

@dbalabka

Description

@dbalabka

There is an assumption that HTTP parsing in Amphp might affect overall server performance.

The assumption is based on experimental results. The variant of pure TCP Amphp server without HTTP parsing performs closer to Swoole and faster than Nodejs.

HTTP parsing implemented with PHP PECL Regexp can be replaced with bind C or Rust library via FFI or Wasmer extension.

Possible fast parsing libraries are:

  1. https://github.com/seanmonstar/httparse/
  2. https://github.com/h2o/picohttpparser

Libraries benchmark: https://github.com/rust-bakery/parser_benchmarks/blob/master/http/README.md

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions