doc: Add warning for rest interface limitation #19050

pull fjahr wants to merge 1 commits into bitcoin:master from fjahr:rest_fd changing 2 files +23 −0
  1. fjahr commented at 2:19 pm on May 22, 2020: member

    libevent, which is used for our rest interface, can use up all of the available file descriptors in a system if too many connections are opened at once. If a new block is connected at the same time and can not be written to disk because there are no file descriptors available, the node crashes. Based on my investigation so far the issue is best solved upstream which means we have to wait for the next release (2.2). In the meantime it would be good if we would warn users of this limitation.

    See #11368 for more background.

  2. fanquake added the label Docs on May 22, 2020
  3. MarcoFalke commented at 2:22 pm on May 22, 2020: member
    Concept ACK
  4. laanwj commented at 11:34 am on May 26, 2020: member

    Concept ACK.

    As long as libevent lacks a way to set an upper bound to the number of concurrent incoming connections to a port (it accept()s always), there’s no way we can handle this at our side. It’s always possible to overwhelm the number of file descriptors (especially when connecting through the loopback interface).

  5. laanwj commented at 10:47 am on May 28, 2020: member
    Is this specific to the REST interface, though? I think any HTTP-related functionality in bitcoin core is affected by this, including RPC requests (when submitted through HTTP)?
  6. doc: Add warnings for http interfaces limitations 5c3eaf9983
  7. fjahr force-pushed on May 31, 2020
  8. fjahr commented at 10:58 pm on May 31, 2020: member

    Is this specific to the REST interface, though? I think any HTTP-related functionality in bitcoin core is affected by this, including RPC requests (when submitted through HTTP)?

    That is correct (confirmed with another small test). But it seems like we only got reports from people running into the issue via the REST interface. But maybe they just found the issue with the search and did not bother with the distinction. I added the same comment block at the bottom of the JSON-RPC interface doc. Do any other or better places come to mind where I should put it?

  9. glozow commented at 9:14 pm on June 16, 2020: member
    Concept ACK. I’m pretty sure there isn’t a good reason to send several hundred requests at once except for not knowing about a more efficient way to get the same information.
  10. adamjonas commented at 10:41 pm on December 16, 2020: member
    Pinging the thread. For those that approved of the idea (@MarcoFalke, @glozow, @laanwj), are there any concerns with ACKing this?
  11. fjahr commented at 11:55 pm on December 16, 2020: member
    FWIW I am watching libevent 2.2 release effort but it still seems pretty far away: https://github.com/libevent/libevent/issues/1094
  12. MarcoFalke commented at 7:55 am on December 17, 2020: member
    Could mention that this is fixed in libevent 2.2 (and later)?
  13. fjahr commented at 8:49 am on December 17, 2020: member

    Could mention that this is fixed in libevent 2.2 (and later)?

    It isn’t fixed by libevent 2.2 automatically. It only adds functionality that allows me then to open a PR that fixes it :)

  14. MarcoFalke commented at 9:00 am on December 17, 2020: member
    ACK 5c3eaf9983043db1b61a98c95d692a6958670b86
  15. MarcoFalke merged this on Dec 17, 2020
  16. MarcoFalke closed this on Dec 17, 2020

  17. MarcoFalke referenced this in commit e4440eb67b on Dec 17, 2020
  18. sidhujag referenced this in commit 9402a9a8c3 on Dec 17, 2020
  19. PastaPastaPasta referenced this in commit f1a25d1923 on Jun 27, 2021
  20. PastaPastaPasta referenced this in commit f021cebd95 on Jun 28, 2021
  21. PastaPastaPasta referenced this in commit c79214739d on Jun 29, 2021
  22. PastaPastaPasta referenced this in commit d4787c11e2 on Jul 1, 2021
  23. PastaPastaPasta referenced this in commit aad0f0d5b9 on Jul 1, 2021
  24. PastaPastaPasta referenced this in commit 3c0b82f6b4 on Jul 15, 2021
  25. PastaPastaPasta referenced this in commit 0e1bfa62d4 on Jul 15, 2021
  26. PastaPastaPasta referenced this in commit d40eedbf01 on Jul 16, 2021
  27. gabriel-bjg referenced this in commit 8a1d9f8c45 on Jul 16, 2021
  28. DrahtBot locked this on Feb 15, 2022

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2024-09-29 04:12 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me