Uploaded image for project: 'Cassandra'
  1. Cassandra
  2. CASSANDRA-5481

CQLSH exception handling could leave a session in a bad state

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Low
    • Resolution: Fixed
    • Fix Version/s: 1.2.19, 2.0.10
    • Component/s: None
    • Labels:
      None
    • Environment:

      cqlsh 2.3.0 | Cassandra 1.2.4 | CQL spec 3.0.0 | Thrift protocol 19.35.0

    • Severity:
      Low

      Description

      Playing with CTRL+C in a cqlsh session can leave the (Thrift|Native) connection in a bad state.

      To reproduce :
      1) Run a long running COPY FROM command (COPY test (k, v) FROM '/tmp/test.csv')
      2) Interrupt the importer with CTRL+C

      Repeat step 1 and 2 until you start seeing weird things in the cql shell (see attached screenshot)

      The reason is, I believe, the connection (and the cursor) is not correclty closed and reopened on interruption.

      I am working to propose a fix.

      Jordan

        Attachments

        1. 5481.diff
          2 kB
          Jordan Pittier
        2. CQLSession.png
          83 kB
          Jordan Pittier

          Activity

            People

            • Assignee:
              jpi Jordan Pittier
              Reporter:
              jpi Jordan Pittier
              Authors:
              Jordan Pittier
              Reviewers:
              Brandon Williams
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: