1. 03 Dec, 2008 6 commits
  2. 25 Nov, 2008 1 commit
    • Michael Hanselmann's avatar
      ganeti.http: Don't reuse key and cert objects · 65c6b8e0
      Michael Hanselmann authored
      Reusing the private key and certificate objects gave us problems. This
      patch changes the code to only cache the PEM data, but the objects
      themselves. For every socket, the private key and certificate objects
      are created again.
      Reviewed-by: iustinp
  3. 21 Nov, 2008 1 commit
  4. 19 Nov, 2008 2 commits
    • Michael Hanselmann's avatar
      Make HttpClientManager threadsafe · 33bbdbec
      Michael Hanselmann authored
      This allows a single HttpClientManager to be used from more than one
      thread at the same time. We discussed having one HttpClientManager
      per job queue thread. Assuming there should be one HTTP thread per
      node, this would mean quadratic growth with the number of nodes. By
      being able to reuse the manager, this problem is a defused a bit.
      This patch also fixes a typo in HttpClientRequestExecutor.
      Reviewed-by: iustinp
    • Oleksiy Mishchenko's avatar
      HTTP server: Do not decode empty entity body · 7c46aafd
      Oleksiy Mishchenko authored
      Reviewed-by: imsnah
  5. 11 Nov, 2008 1 commit
    • Michael Hanselmann's avatar
      ganeti.http: Implement SSL for HTTP client · 438a366a
      Michael Hanselmann authored
      Implementing SSL for the HTTP client required more work than I expected.
      For correct error handling, quite a lot of code is needed. To avoid
      code duplication, I moved a lot of the socket handling code into a
      single function named _SocketOperation. It takes care of the polling
      and error handling for OpenSSL. At the same time, the functions calling
      it become a lot smaller.
      This patch brings a few more changes:
      - Error handling for socket.connect_ex (e.g. name resolution failures)
      - Rename "ResponseError" exception class to "_HttpClientError" --
        it's an internal class anyway
      Reviewed-by: iustinp
  6. 10 Nov, 2008 2 commits
  7. 06 Nov, 2008 2 commits
    • Michael Hanselmann's avatar
      Add new HTTP client class · 8a0b06d2
      Michael Hanselmann authored
      It is based on the WorkerPool class which is already used for the job
      queue and master daemon. Each request must be encapsulated in an
      instance of HttpClientRequest, which will then be passed to
      HttpClientManager for processing. Upon completion, the request object
      contains the response or error message.
      While not yet enabled, the HTTP client implementation has been designed
      with HTTP/1.1 and keep-alive in mind. For now it only uses HTTP/1.0,
      HttpClientManager will likely need more changes when integrating with
      the RPC layer. SSL will also be integrated in a second step.
      Reviewed-by: iustinp, ultrotter
    • Michael Hanselmann's avatar
      ganeti.http: Use 411 Length Required in server code · 64357ed8
      Michael Hanselmann authored
      Reviewed-by: iustinp
  8. 05 Nov, 2008 1 commit
  9. 24 Oct, 2008 2 commits
  10. 23 Oct, 2008 1 commit
    • Michael Hanselmann's avatar
      http library: Always fork before reading request · 6526ddcd
      Michael Hanselmann authored
      It turned out that clients not sending a full request will stop
      us from responding to further requests. This patch leverages the
      situation a bit by always forking before handling the request,
      but we still have DoS situations.
      Reviewed-by: ultrotter
  11. 20 Oct, 2008 2 commits
  12. 17 Oct, 2008 1 commit
  13. 10 Oct, 2008 1 commit
    • Michael Hanselmann's avatar
      Add new HTTP server implementation · 42242313
      Michael Hanselmann authored
      This patch adds another implementation of an HTTP server. It's
      based on code of Python's BaseHTTPServer, from both version
      2.4 and 3k. In the future we can write code to decide whether
      we should fork for a request or not. Keep-alive is not supported.
      Reviewed-by: iustinp
  14. 30 Jul, 2008 1 commit
    • Iustin Pop's avatar
      Fix pylint-detected issues · 38206f3c
      Iustin Pop authored
      This is mostly:
        - whitespace fix (space at EOL in some files, not all, broken
          indentation, etc)
        - variable names overriding others (one is a real bug in there)
        - too-long-lines
        - cleanup of most unused imports (not all)
      Reviewed-by: ultrotter
  15. 24 Jul, 2008 1 commit
  16. 11 Jul, 2008 2 commits