jenkinsci / urltrigger-plugin

https://plugins.jenkins.io/urltrigger/
16 stars 42 forks source link

URL Trigger with MD5Sum not working #48

Closed inidona closed 2 years ago

inidona commented 2 years ago

Jenkins and plugins versions report

Environment ```text Jenkins: 2.319.1 OS: Linux - 4.15.0-112-generic --- Office-365-Connector:4.15.2 PrioritySorter:4.1.0 ace-editor:1.1 analysis-model-api:10.8.1 ansicolor:1.0.1 ant:1.13 antisamy-markup-formatter:2.6 apache-httpcomponents-client-4-api:4.5.13-1.0 authentication-tokens:1.4 authorize-project:1.4.0 badge:1.9 basic-branch-build-strategies:1.3.2 blackduck-detect:7.0.0 bootstrap4-api:4.6.0-3 bootstrap5-api:5.1.3-4 bouncycastle-api:2.25 branch-api:2.7.0 build-token-root:1.9 buildtriggerbadge:2.11 caffeine-api:2.9.2-29.v717aac953ff3 checks-api:1.7.2 cloudbees-folder:6.17 cloudfoundry:2.3.2 command-launcher:1.6 config-file-provider:3.8.2 copyartifact:1.46.2 credentials:1074.v60e6c29b_b_44b_ credentials-binding:1.27 dark-theme:155.v497c78bbdbb3 data-tables-api:1.11.3-6 disk-usage:0.28 display-url-api:2.3.5 docker-commons:1.17 docker-workflow:1.26 durable-task:493.v195aefbb0ff2 echarts-api:5.2.2-2 email-ext:2.86 extended-read-permission:3.2 external-monitor-job:1.7 extra-columns:1.25 favorite:2.3.3 folder-properties:1.2.1 font-awesome-api:5.15.4-5 forensics-api:1.7.0 generic-webhook-trigger:1.79 ghprb:1.42.2 git:4.10.1 git-client:3.11.0 git-forensics:1.3.0 git-parameter:0.9.14 git-server:1.10 github:1.34.1 github-api:1.301-378.v9807bd746da5 github-branch-source:2.11.4 github-checks:1.0.14 github-issues:1.2.4 github-oauth:0.37 google-oauth-plugin:1.0.6 gradle:1.38 gradle-daemon:0.1.0 greenballs:1.15.1 groovy:2.4 groovy-postbuild:2.5 handlebars:3.0.8 handy-uri-templates-2-api:2.1.8-1.0 htmlpublisher:1.28 http_request:1.12 jackson2-api:2.13.1-246.va8a9f3eaf46a jdk-tool:1.5 jenkins-design-language:1.25.2 jira:3.6 jjwt-api:0.11.2-9.c8b45b8bb173 job-dsl:1.78.3 jobConfigHistory:2.31-rc1098.b666422863b2 jquery:1.12.4-1 jquery-detached:1.2.1 jquery3-api:3.6.0-2 jsch:0.1.55.2 junit:1.53 kubernetes:1.31.2 kubernetes-client-api:5.11.2-182.v0f1cf4c5904e kubernetes-credentials:0.9.0 ldap:2.7 lockable-resources:2.13 logstash:2.5.0205.vd05825ed46bd mailer:391.ve4a_38c1b_cf4b_ mapdb-api:1.0.9.0 material-theme:0.4.1 matrix-auth:3.0 matrix-project:1.19 mattermost:3.1.1 metrics:4.0.2.8 momentjs:1.1.1 monitoring:1.90.0 next-build-number:1.7 nodejs:1.4.3 nvm-wrapper:0.1.7 oauth-credentials:0.5 oic-auth:1.8 okhttp-api:4.9.3-105.vb96869f8ac3a pam-auth:1.6.1 parameter-separator:1.3 pipeline-build-step:2.15 pipeline-github:2.8-138.d766e30bb08b pipeline-github-lib:1.0 pipeline-graph-analysis:188.v3a01e7973f2c pipeline-input-step:427.va6441fa17010 pipeline-milestone-step:1.3.2 pipeline-model-api:1.9.3 pipeline-model-definition:1.9.3 pipeline-model-extensions:1.9.3 pipeline-rest-api:2.20 pipeline-stage-step:291.vf0a8a7aeeb50 pipeline-stage-tags-metadata:1.9.3 pipeline-stage-view:2.20 pipeline-utility-steps:2.11.0 plain-credentials:1.7 plugin-util-api:2.12.0 popper-api:1.16.1-2 popper2-api:2.11.0-1 prism-api:1.25.0-1 proc-cleaner-plugin:2.4 pubsub-light:1.16 rebuild:1.32 resource-disposer:0.17 reverse-proxy-auth-plugin:1.7.1 role-strategy:3.2.0 scm-api:595.vd5a_df5eb_0e39 script-security:1131.v8b_b_5eda_c328e simple-build-for-pipeline:0.2 snakeyaml-api:1.29.1 solarized-theme:0.1 sonar:2.14 sse-gateway:1.24 ssh-agent:1.23 ssh-credentials:1.19 ssh-slaves:1.33.0 ssh-steps:2.0.0 sshd:3.1.0 statistics-gatherer:2.0.3 structs:308.v852b473a2b8c subversion:2.15.1 theme-manager:0.6 timestamper:1.15 token-macro:267.vcdaea6462991 trilead-api:1.0.13 urltrigger:0.50 variant:1.4 view-job-filters:2.3 warnings-ng:9.10.2 windows-slaves:1.8 workflow-aggregator:2.6 workflow-api:1108.v57edf648f5d4 workflow-basic-steps:2.24 workflow-cps:2648.va9433432b33c workflow-cps-global-lib:552.vd9cc05b8a2e1 workflow-durable-task-step:1112.vda00e6febcc1 workflow-job:1145.v7f2433caa07f workflow-multibranch:704.v8f039a_e2e8cf workflow-scm-step:2.13 workflow-step-api:622.vb_8e7c15b_c95a_ workflow-support:804.vba10a18a1476 ws-cleanup:0.40 xml-job-to-job-dsl:0.1.13 ```

What Operating System are you using (both controller, and any agents involved in the problem)?

Ubuntu

Reproduction steps

These URL Trigger

URLTrigger( cronTabSpec: '@daily', entries: [ URLTriggerEntry( url: "https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb", proxyActivated: true, contentTypes: [ MD5Sum() ] ), URLTriggerEntry( url: 'https://chromedriver.storage.googleapis.com/LATEST_RELEASE', proxyActivated: true, contentTypes: [ MD5Sum() ] ) ] )

Expected Results

Build was triggered if content on Server changed, works fine for years

Actual Results

Polling on master. Resolving environment variables using global values [ERROR] - Polling error... [ERROR] - Error message: javax/ws/rs/ext/MessageBodyReader [ERROR] - Error cause: javax.ws.rs.ext.MessageBodyReader

Anything else?

No response

piesarmin commented 2 years ago

Probably related to https://github.com/jenkinsci/urltrigger-plugin/issues/45 ?

TonyNoble commented 2 years ago

@inidona - urltrigger-0.51 has been released with fixes in this area. Could you please try that and let me know if the issue persists?

inidona commented 2 years ago

@TonyNoble i tested it an received always a UnknownHostException on our Jenkins behind a proxy server. I added the PullRequest which fixes the issue.

After that everything works again.

TonyNoble commented 2 years ago

@inidona - thanks for that - merged and released as 0.52

piesarmin commented 2 years ago

I have actually updated all our Plugins and Jenkins LTS especially URLTrigger 0.50 -> 1.01, Jenkins 2.319.1 -> 2.319.2 (CentOS 7).

Now I get these errors mentioned above, too:

Polling on master. Resolving environment variables using global values [ERROR] - Polling error... [ERROR] - Error message: javax/ws/rs/ext/MessageBodyReader [ERROR] - Error cause: javax.ws.rs.ext.MessageBodyReader

Our Windows Servers do not have this problem.

What version(s) do I need to update to fix this?

TonyNoble commented 2 years ago

Hi @piesarmin - a couple of requests:

Thanks,

Tony

piesarmin commented 2 years ago

I checked the configuration file for that one job in a text editor (other jobs on the same jenkins server did not show any errors concerning URLTrigger) and found two entries of a trigger specification, one was "". I do not know how this could happen. I have removed that entry from the configuration and the errors went away.

Sorry about that.

TonyNoble commented 2 years ago

Hi @piesarmin - that's good to hear, thanks for the update :0)