Uploaded image for project: 'Phoenix'
  1. Phoenix
  2. PHOENIX-2500

Small race condition for clients to see application-level exception when PQS shutting down

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • None
    • None
    • None

    Description

      I wrote a little test for PQS where multiple instances sit behind a dumb load balancer. A client thread runs queries against the load balancer, and another thread willy-nilly kills PQS instances (chaos-monkey esque).

      We noticed that when a PQS instance gets killed while a query is running, a client might get an exception stemming from the ThreadPool being shut down by the PhoenixDriver ShutdownHook.

      Ideally, the client would just see an HTTP/500-level error or get some sort of transport-level exception, not an exception with an RejectedExecutionException. The solution, I think, is to let PQS register its own code to run before PhoenixDriver closes itself.

      Attachments

        Activity

          People

            elserj Josh Elser
            elserj Josh Elser
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: