• Icon: Improvement Improvement
    • Resolution: Done
    • Icon: Major Major
    • influxdb-plugin
    • None
    • 2.1

      I want to customize the tags and keys in the collected data. As of now only the project name is the tag in influxdb. But i want add some more fields as tags in influxdb.

      Example

      I want to filter the data build wise. So that i want to add the build number as tag in the influxdb.

       

       

      And also i could not get the pipeline data such as stage duration, failed at which stage.

       

          [JENKINS-54445] Add more common tags for all measurements

          Thank you so much

          Mohamed Nazeer Mohamed Ibrahim added a comment - Thank you so much

          Sorry to reopen this issue.

          The given solution is effect only for jenkins_data measurement. But the same is not reflect in other measurements which are collected by the same plugin such as "jacaco_data, suite_results, rf_results...etc"

           

          Thanks in advance

          Mohamed Nazeer Mohamed Ibrahim added a comment - Sorry to reopen this issue. The given solution is effect only for jenkins_data measurement. But the same is not reflect in other measurements which are collected by the same plugin such as "jacaco_data, suite_results, rf_results...etc"   Thanks in advance

          We have implemented the given solution but it seems the tags are not present in the databases.

          The influx version is : 1.5.4

          jenkins Configuration is :

          step([$class: 'InfluxDbPublisher', customData: myDataMap, customDataMap: null, customPrefix: null, target: 'Jenkins Build Status', jenkinsEnvParameterTag: 'build_number=' + env.BUILD_NUMBER])

           

          When we execute the below query in influxdb it shows nothing.

          SHOW TAG KEYS FROM "testcase_point"

           

           

           

          Mohamed Nazeer Mohamed Ibrahim added a comment - We have implemented the given solution but it seems the tags are not present in the databases. The influx version is : 1.5.4 jenkins Configuration is : step( [$class: 'InfluxDbPublisher', customData: myDataMap, customDataMap: null, customPrefix: null, target: 'Jenkins Build Status', jenkinsEnvParameterTag: 'build_number=' + env.BUILD_NUMBER] )   When we execute the below query in influxdb it shows nothing. SHOW TAG KEYS FROM "testcase_point"      

          Aleksi Simell added a comment - - edited

          That is because with the current configuration the jenkinsEnvParameterTag adds the tags only to the measurement "jenkins_data", as documented. I will try to add those tags to all measurements once I find time.

          Aleksi Simell added a comment - - edited That is because with the current configuration the jenkinsEnvParameterTag adds the tags only to the measurement "jenkins_data", as documented. I will try to add those tags to all measurements once I find time.

          Thanks for reply!!

          If i want to add some more tag keys then what should i do?

          Any specific format for this?

           

           

          Mohamed Nazeer Mohamed Ibrahim added a comment - Thanks for reply!! If i want to add some more tag keys then what should i do? Any specific format for this?    

          _peedus added a comment - - edited

          Hi aleksisimell,

          > the current configuration the jenkinsEnvParameterTag adds the tags only to the measurement "jenkins_data", as documented. I will try to add those tags to all measurements once I find time.

          Is there any tentative time when this will be available? Hope the same could be also done for 
          jenkinsEnvParameterField ?

          Thanks!

          _peedus added a comment - - edited Hi aleksisimell , > the current configuration the jenkinsEnvParameterTag adds the tags only to the measurement " jenkins_data ", as documented. I will try to add those tags to all measurements once I find time. Is there any tentative time when this will be available? Hope the same could be also done for  jenkinsEnvParameterField  ? Thanks!

          Aleksi Simell added a comment -

          Hi _peedus,

          I had completely forgotten this one. I made a note for myself to have this in my own "backlog". I will try to make this ASAP, but might not make it for the next release (I try to make releases ~once a month or so).

          Aleksi Simell added a comment - Hi _peedus , I had completely forgotten this one. I made a note for myself to have this in my own "backlog". I will try to make this ASAP, but might not make it for the next release (I try to make releases ~once a month or so).

          Aleksi Simell added a comment -

          I created https://github.com/jenkinsci/influxdb-plugin/pull/92 for myself today. It's mergeable, but will check a previous PR before merging that and then make necessary corrections to my PR after that.

          Aleksi Simell added a comment - I created  https://github.com/jenkinsci/influxdb-plugin/pull/92  for myself today. It's mergeable, but will check a previous PR before merging that and then make necessary corrections to my PR after that.

          Aleksi Simell added a comment -

          PR 92 merged. Will be available in the next release.

          Aleksi Simell added a comment - PR 92 merged. Will be available in the next release.

          bose boban added a comment -

          aleksisimell is there any way for enabling new fields along with global  Listener? while I am using publish it's pulling the middle of the job and missing build status message and pulling last build details instead of current. Its making confusing while reading data.

          So can I get it to know is there any way for proceed this

           

          bose boban added a comment - aleksisimell  is there any way for enabling new fields along with global  Listener? while I am using publish it's pulling the middle of the job and missing build status message and pulling last build details instead of current. Its making confusing while reading data. So can I get it to know is there any way for proceed this  

            aleksisimell Aleksi Simell
            mohamednazeer Mohamed Nazeer Mohamed Ibrahim
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: