Uploaded image for project: 'Sidecar for Apache Cassandra'
  1. Sidecar for Apache Cassandra
  2. CASSSIDECAR-140

Updating traffic shaping options throws IllegalStateException

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Normal
    • Resolution: Fixed
    • 1.0
    • Rest API
    • None
    • Correctness - Unrecoverable Corruption / Loss
    • Normal
    • Low Hanging Fruit
    • DTest
    • Hide

      Added a unit test that surfaces the issue. The unit test uses a non-zero port, which will help surface the issue.

      Show
      Added a unit test that surfaces the issue. The unit test uses a non-zero port, which will help surface the issue.

    Description

      When updating the traffic shaping options in Sidecar in org.apache.cassandra.sidecar.server.Server#updateTrafficShapingOptions, we are encountering a bug in vert.x. The problem happens in io.vertx.core.net.impl.TCPServerBase#updateTrafficShapingOptions where the trafficShapingHandler is null for childHandler}}s. When a {{null trafficShapingHandler is encountered, the following exception is thrown:

      throw new IllegalStateException("Unable to update traffic shaping options because the server was not configured " +
                                      "to use traffic shaping during startup");
      

      I propose a stopgap measure to fix the issue in Sidecar while we wait for a new vert.x release that includes a fix for this issue. Without a fix, we risk leaving Sidecar in unknown state after updating the traffic shaping options. Because applying the traffic shaping options can succeed or fail before encountering the exception. This can potentially leave a cluster of Sidecar servers in an inconsistent state across all Sidecars. The only option to return to a well-known state is by restarting the Sidecar process across the cluster with the updated traffic shaping options applied in the yaml before starting the process.

      Attachments

        Activity

          People

            frankgh Francisco Guerrero
            frankgh Francisco Guerrero
            Francisco Guerrero
            Arjun Ashok, Saranya Krishnakumar, Yifan Cai
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: