Skip to content

removeAfter* is broken on keep-alive connections #2

Description

@fancy-rabbit

it ends with

TypeError: Cannot set property 'data' of undefined
at middleware (/path/to/node_modules/http-request-context/index.js:89:29)

if either removeAfterFinish or removeAfterClose is set to true. the first request

and I guess if the connection is kept alive longer than options.alive, it will be out of order, either...

acoording to the document and your zhihu zhuanlan,

The TCPWRAP is the new connection from the client. When a new connection is made, the TCPWrap instance is immediately constructed.

i guess that connection and request might not be a 1:1 map.
emmm... but not sure. because i'm using it with koa-convert.back for koav1 compatibility. haven't dig deeply into async_hooks internal yet.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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