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

Allow both named values and regular values in a single batch

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Open
    • Normal
    • Resolution: Unresolved
    • None
    • Legacy/CQL
    • Clients

    Description

      Currently, there's a single <flag> to determine whether a batch uses named values or not. This forces all query entries in a batch to use the same value encoding. There's also the fact that the current design is broken. See: CASSANDRA-10246

      I propose that this information be encoded using the batch entries' <kind> component and remove "0x40: With names for values" as an option from <flags>. In the current design the <kind> component, a [byte], only uses two values 0 and 1 for non-prepared and prepared, respectively. The proposed solution would add two more values, 2 and 3, for non-prepared w/ names values and prepared w/ named values. This has a couple benefits:

      1) It allows for heterogeneous value encodings in a single batch
      2) It eliminates the need for reading ahead to determine the value encodings (See: CASSANDRA-10246)

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              mpenick Michael Penick
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated: