Background
I have a Jenkins job that does the resigning of android and ios apps based on the files uploaded to the Nexus repository.
I have 3 app versions for each android and ios.
Using nexus repo level webhook triggering concept + Jenkins generic Webhooks concept, we have achieved automated triggering of the builds when an app file is pushed to the nexus repository.
Problem
When all the 3 files are pushed in one go for any of the android or ios apps, can see only 2 Jenkins jobs webhook triggers only. one hook trigger is missing. Currently, we are seeing this issue very consistently.
The only observation that I have identified is, that whenever 3 files are pushed in one go, In the Jenkins job you see the webhook entry. see below screenshot of Jenkins job
I tried looking at multiple places but could not find a solution.
Any help here is appreciated...
Is there any possibility that we can count the number of webhooks received by the Jenkins job via code which we can see in the screenshot attached?
I have found similar issue reports in github.com: #64 #116 #126 #162 #171.
After going through all these solutions, The solution which worked for me is: