Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-22873

Init lastReportTimestamp with system current time when start() called in AsyncEventQueue

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Minor
    • Resolution: Not A Problem
    • 2.2.1
    • None
    • Spark Core
    • Patch

    Description

         if (droppedEventsCounter.compareAndSet(droppedCount, 0)) {
            val prevLastReportTimestamp = lastReportTimestamp
            lastReportTimestamp = System.currentTimeMillis()
            val previous = new java.util.Date(prevLastReportTimestamp)
            logWarning(s"Dropped $droppedEvents events from $name since $previous.")
         }
      

      First time we log previous date, it would be "Thu Jan 01 08:00:00 CST 1970" because of lastReportTimestamp was inited by 0L. Although there is no mistake in theory, AsyncEventQueue's starting time seems better.

      Attachments

        Activity

          People

            Unassigned Unassigned
            Ngone51 wuyi
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: