Uploaded image for project: 'Apache Storm'
  1. Apache Storm
  2. STORM-2429

non-string values in supervisor.scheduler.meta cause crash

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 1.0.3
    • 2.0.0, 1.0.4, 1.1.1, 1.2.0
    • storm-core
    • None

    Description

      The type of values in supervisor.scheduler.meta is not validated, but if one is not a string, supervisors crash during Thrift serialization with:

      java.lang.ClassCastException: java.lang.Boolean cannot be cast to java.lang.String
      at org.apache.storm.generated.SupervisorInfo$SupervisorInfoStandardScheme.write(SupervisorInfo.java:1241)
      at org.apache.storm.generated.SupervisorInfo$SupervisorInfoStandardScheme.write(SupervisorInfo.java:1049)
      at org.apache.storm.generated.SupervisorInfo.write(SupervisorInfo.java:923)
      at org.apache.storm.thrift.TSerializer.serialize(TSerializer.java:79)
      at org.apache.storm.serialization.GzipThriftSerializationDelegate.serialize(GzipThriftSerializationDelegate.java:40)
      at org.apache.storm.utils.Utils.serialize(Utils.java:210)
      at org.apache.storm.cluster.StormClusterStateImpl.supervisorHeartbeat(StormClusterStateImpl.java:419)
      at org.apache.storm.daemon.supervisor.timer.SupervisorHeartbeat.run(SupervisorHeartbeat.java:85)
      at org.apache.storm.daemon.supervisor.Supervisor.launch(Supervisor.java:202)
      at org.apache.storm.daemon.supervisor.Supervisor.launchDaemon(Supervisor.java:243)
      at org.apache.storm.daemon.supervisor.Supervisor.main(Supervisor.java:362)

      I will attach a PR with a simple fix

      Attachments

        Issue Links

          Activity

            People

              djudd1905 David Judd
              djudd1905 David Judd
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 0.5h
                  0.5h