Uploaded image for project: 'Slider'
  1. Slider
  2. SLIDER-1155

Code issues - 16 multithreaded correctness

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: Slider 0.91
    • Fix Version/s: Slider 0.92
    • Component/s: other
    • Labels:
      None

      Description

      Following 16 possible multithreaded correctness issues need to be evaluated and fixed.

      slider-core/src/main/java/org/apache/slider/server/services/workflow/ForkedProcessService.java
      244    synchronized (processTerminated) {
      

      defect: Synchronization performed on java.util.concurrent.atomic.AtomicBoolean

      213      synchronized (processTerminated) {
      

      defect: Synchronization performed on java.util.concurrent.atomic.AtomicBoolean

      slider-core/src/main/java/org/apache/slider/server/appmaster/state/RoleStatus.java
      320  public long getCompleted() {
      

      defect: org.apache.slider.server.appmaster.state.RoleStatus.getCompleted() is unsynchronized, org.apache.slider.server.appmaster.state.RoleStatus.setCompleted(int) is synchronized.

      slider-core/src/main/java/org/apache/slider/server/appmaster/state/ProviderAppState.java
      94      synchronized (publishedConfigSets) {
      

      defect: Synchronization performed on java.util.concurrent.ConcurrentHashMap

      110    synchronized (publishedConfigSets) {
      

      defect: Synchronization performed on java.util.concurrent.ConcurrentHashMap

      slider-core/src/main/java/org/apache/slider/server/appmaster/management/RecordedEvent.java
      54    this.time = timestamp > 0 ? dateFormat.format(timestamp) : "";
      

      defect: Call to method of static java.text.DateFormat

      slider-core/src/main/java/org/apache/slider/server/appmaster/management/RangeLimitedCounter.java
      77  public long get() {
      

      defect: org.apache.slider.server.appmaster.management.RangeLimitedCounter.get() is unsynchronized, org.apache.slider.server.appmaster.management.RangeLimitedCounter.set(long) is synchronized.

      slider-core/src/main/java/org/apache/slider/server/appmaster/SliderAppMaster.java
      1532        isAMCompleted.awaitUninterruptibly();
      

      defect: Condition.await() not in loop.

      slider-core/src/main/java/org/apache/slider/providers/agent/ComponentTagProvider.java
      119      synchronized (allTags) {
      

      defect: Synchronization performed on java.util.concurrent.ConcurrentHashMap

       56              compTags.put(tempKey, FREE);
      

      defect: Sequence of calls to java.util.concurrent.ConcurrentHashMap may not be atomic.

      106        synchronized (compTags) {
      

      defect: Synchronization performed on java.util.concurrent.ConcurrentHashMap

       52        synchronized (compTags) {
      

      defect: Synchronization performed on java.util.concurrent.ConcurrentHashMap

      121          allTags.put(component, new ConcurrentHashMap<String, String>());
      

      defect: Sequence of calls to java.util.concurrent.ConcurrentHashMap may not be atomic

       76      synchronized (compTags) {
      

      defect: Synchronization performed on java.util.concurrent.ConcurrentHashMap

      slider-core/src/main/java/org/apache/slider/core/zk/BlockingZKWatcher.java
      39    synchronized (connectedFlag) {
      

      defect: Synchronization performed on java.util.concurrent.atomic.AtomicBoolean

      55    synchronized (connectedFlag) {
      

      defect: Synchronization performed on java.util.concurrent.atomic.AtomicBoolean

        Attachments

          Activity

            People

            • Assignee:
              gsaha Gour Saha
              Reporter:
              gsaha Gour Saha
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: