Uploaded image for project: 'Ambari'
  1. Ambari
  2. AMBARI-25811

Optimize ambari metrics build time

    XMLWordPrintableJSON

Details

    Description

      Currently in ambari metrics build, most of the time is taken by ambari-metrics-assembly.
      Looks maven-assembly-plugin is taking lot of time in stitching the artifacts.

      Upgrading maven-assembly-plugin from 2.2-beta-5 to 3.4.2(latest version) reduces the build time significantly

      Before change:

      15:58:46,215 [INFO] Reactor Summary for ambari-metrics 2.0.0.0-SNAPSHOT:
      15:58:46,215 [INFO] 
      15:58:46,218 [INFO] ambari-metrics ..................................... SUCCESS [  3.960 s]
      15:58:46,220 [INFO] Ambari Metrics Common .............................. SUCCESS [ 11.492 s]
      15:58:46,220 [INFO] Ambari Metrics Hadoop Sink ......................... SUCCESS [  7.655 s]
      15:58:46,220 [INFO] Ambari Metrics Flume Sink .......................... SUCCESS [  4.045 s]
      15:58:46,220 [INFO] Ambari Metrics Kafka Sink .......................... SUCCESS [  3.465 s]
      15:58:46,220 [INFO] Ambari Metrics Storm Sink .......................... SUCCESS [  2.887 s]
      15:58:46,220 [INFO] Ambari Metrics Collector ........................... SUCCESS [ 19.416 s]
      15:58:46,220 [INFO] Ambari Metrics Monitor ............................. SUCCESS [  4.791 s]
      15:58:46,220 [INFO] Ambari Metrics Grafana ............................. SUCCESS [  2.838 s]
      15:58:46,220 [INFO] Ambari Metrics Host Aggregator ..................... SUCCESS [  8.363 s]
      15:58:46,220 [INFO] Ambari Metrics Assembly ............................ SUCCESS [09:09 min]
      15:58:46,220 [INFO] ------------------------------------------------------------------------
      15:58:46,220 [INFO] BUILD SUCCESS
      15:58:46,220 [INFO] ------------------------------------------------------------------------
      15:58:46,221 [INFO] Total time:  10:18 min
      15:58:46,221 [INFO] Finished at: 2022-12-14T15:58:46+05:30
      

      After Change:

      16:18:22,667 [INFO] Reactor Summary for ambari-metrics 2.0.0.0-SNAPSHOT:
      16:18:22,667 [INFO] 
      16:18:22,670 [INFO] ambari-metrics ..................................... SUCCESS [  3.897 s]
      16:18:22,671 [INFO] Ambari Metrics Common .............................. SUCCESS [ 10.880 s]
      16:18:22,671 [INFO] Ambari Metrics Hadoop Sink ......................... SUCCESS [  4.681 s]
      16:18:22,671 [INFO] Ambari Metrics Flume Sink .......................... SUCCESS [  2.184 s]
      16:18:22,671 [INFO] Ambari Metrics Kafka Sink .......................... SUCCESS [  2.949 s]
      16:18:22,671 [INFO] Ambari Metrics Storm Sink .......................... SUCCESS [  3.071 s]
      16:18:22,671 [INFO] Ambari Metrics Collector ........................... SUCCESS [ 18.471 s]
      16:18:22,671 [INFO] Ambari Metrics Monitor ............................. SUCCESS [  5.416 s]
      16:18:22,671 [INFO] Ambari Metrics Grafana ............................. SUCCESS [  2.458 s]
      16:18:22,671 [INFO] Ambari Metrics Host Aggregator ..................... SUCCESS [  8.963 s]
      16:18:22,671 [INFO] Ambari Metrics Assembly ............................ SUCCESS [ 57.413 s]
      16:18:22,671 [INFO] ------------------------------------------------------------------------
      16:18:22,671 [INFO] BUILD SUCCESS
      16:18:22,671 [INFO] ------------------------------------------------------------------------
      16:18:22,671 [INFO] Total time:  02:00 min
      16:18:22,673 [INFO] Finished at: 2022-12-14T16:18:22+05:30
      

      As shown above, in my build environment, build time is reduced from 10 minute to 2 minute.

      Attachments

        Activity

          People

            arshad.mohammad Mohammad Arshad
            arshad.mohammad Mohammad Arshad
            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