If the JIRA WebHook destination connection fails for any reason, such as the below, there will be no errors in the log, so no exceptions - essentially WebHooks fail silently:
- The domain uses self signed certificate that's not in the Java trust store.
- There's any other problem with verifying SSL connection (like certificate issued by an unknown CA, protocol/cipher mismatch and so on).
- The host cannot be reached, due to network configuration.
- The URL is invalid.
This makes it hard to understand why the connection failed, as nothing is written about the failure.
- Setup a WebHook to send to a target that will fail (for example, it uses a self-signed certificate not in the JIRA's trust store, or SSL is configured in a way that will generate an exception, or the URL does not exist).
- Attempt to send the WebHook by performing the JIRA action that triggers it.
The exception is written to the logs.
No exception is written to the logs or thrown.
Identify why the connection is failing - this can be tested outside of JIRA by using network tools such as cURL, telnet and/or ping. For example, if the target URL is www.example.com/webhook/test/ perform these tests from the JIRA server:
- If using the -Dhttp.nonProxyHosts argument, the request may be failing due to
JRA-43143(WebHooks are not respecting this argument).
- ping www.example.com to see if the servers can establish a network connection.
- telnet www.example.com 80 to see if the appropriate port is open.
- curl -X POST www.example.com/webhook/test/ to see that you can submit a POST to the target server.
If these tests fail, it can indicate that network / firewall / DNS configurations may need to be addressed, depending upon the errors returned from the different tests.
If this is SSL related, ensure to import the self-signed certificate into the trust store as per Connecting to SSL services.