Hello Community,
I have configured pagerduty watcher couple of weeks back and it successfully posted alerts to my company pagerduty portal when I excecute the watcher using simulation. So I thought everything seems working fine but later I realized it worked only when executing from simulation and getting execution failing error when watcher triggers for every 15min (even condition met) with PKIX cert issue.
Between now I am facing a strange issue, I have pagerduty URL in my watcher "mycompnay.pagerduty.com" and I am trying to execute using simulation tab and I am getting Internal server error but is confusing me is In watcher error logs in backend it's showing as failed to connect events.pagerduty.com but no where I gave that URL in my watcher.
My question is how it is possible and why it is contacting without having events.pagerduty.com in my watcher config. Moreover, it worked previously.
Below is my email config for pagerduty and error logs.
"actions": {
"notify-pagerduty": {
"throttle_period_in_millis": 300000,
"pagerduty": {
"description": "ATTENTION: critical logs found in last 1hour and triggered at {{ctx.execution_time}}",
"client_url": "https://kibana.corp.mycompany.com/",
"attach_payload": true,
"account": "team1",
"contexts": [
{
"type": "link",
"href": "https://mycompany.pagerduty.com"
},
{
"type": "link",
"href": "https://mycompany.pagerduty.com",
"text": "View the incident on {{ctx.payload.link}}"
}
]
}
}
}
Simulation (execute) output error from the backend logs
**elasticsearch_cordinator** | org.apache.http.conn.ConnectTimeoutException: Connect to events.pagerduty.com:443 [events.pagerduty.com/13.56.226.208, events.pagerduty.com/18.144.19.36, events.pagerduty.com/54.203.47.92] failed: connect timed out
**elasticsearch_cordinator** | at org.apache.http.impl.conn.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:150) ~[httpclient-4.5.2.jar:4.5.2]
**elasticsearch_cordinator** | at org.apache.http.impl.conn.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:353) ~[httpclient-4.5.2.jar:4.5.2]
**elasticsearch_cordinator** | at org.apache.http.impl.execchain.MainClientExec.establishRoute(MainClientExec.java:380) ~[httpclient-4.5.2.jar:4.5.2]
**elasticsearch_cordinator** | at org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:236) ~[httpclient-4.5.2.jar:4.5.2]
**elasticsearch_cordinator** | at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:184) ~[httpclient-4.5.2.jar:4.5.2]
**elasticsearch_cordinator** | at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:88) ~[httpclient-4.5.2.jar:4.5.2]
**elasticsearch_cordinator** | at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:110) ~[httpclient-4.5.2.jar:4.5.2]
**elasticsearch_cordinator** | at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:184) ~[httpclient-4.5.2.jar:4.5.2]
**elasticsearch_cordinator** | at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82) ~[httpclient-4.5.2.jar:4.5.2]
**elasticsearch_cordinator** | at org.elasticsearch.xpack.watcher.common.http.HttpClient.lambda$execute$0(HttpClient.java:173) ~[?:?]
**elasticsearch_cordinator** | at java.security.AccessController.doPrivileged(Native Method) ~[?:?]
**elasticsearch_cordinator** | at org.elasticsearch.xpack.core.common.socket.SocketAccess.doPrivileged(SocketAccess.java:32) ~[x-pack-core-6.5.0.jar:6.5.0]
**elasticsearch_cordinator** | at org.elasticsearch.xpack.watcher.common.http.HttpClient.execute(HttpClient.java:173) ~[?:?]
**elasticsearch_cordinator** | at org.elasticsearch.xpack.watcher.notification.pagerduty.PagerDutyAccount.send(PagerDutyAccount.java:53) ~[?:?]
**elasticsearch_cordinator** | at org.elasticsearch.xpack.watcher.actions.pagerduty.ExecutablePagerDutyAction.execute(ExecutablePagerDutyAction.java:50) ~[?:?]
**elasticsearch_cordinator** | at org.elasticsearch.xpack.core.watcher.actions.ActionWrapper.execute(ActionWrapper.java:144) [x-pack-core-6.5.0.jar:6.5.0]
**elasticsearch_cordinator** | at org.elasticsearch.xpack.watcher.execution.ExecutionService.executeInner(ExecutionService.java:455) [x-pack-watcher-6.5.0.jar:6.5.0]
**elasticsearch_cordinator** | at org.elasticsearch.xpack.watcher.execution.ExecutionService.execute(ExecutionService.java:295) [x-pack-watcher-6.5.0.jar:6.5.0]
**elasticsearch_cordinator** | at org.elasticsearch.xpack.watcher.transport.actions.execute.TransportExecuteWatchAction$1.doRun(TransportExecuteWatchAction.java:154) [x-pack-watcher-6.5.0.jar:6.5.0]
**elasticsearch_cordinator** | at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37) [elasticsearch-6.5.0.jar:6.5.0]
**elasticsearch_cordinator** | at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) [?:?]
**elasticsearch_cordinator** | at java.util.concurrent.FutureTask.run(FutureTask.java:264) [?:?]
**elasticsearch_cordinator** | at org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingRunnable.run(ThreadContext.java:624) [elasticsearch-6.5.0.jar:6.5.0]
**elasticsearch_cordinator** | at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
**elasticsearch_cordinator** | at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
**elasticsearch_cordinator** | at java.lang.Thread.run(Thread.java:834) [?:?]
**elasticsearch_cordinator** | Caused by: java.net.SocketTimeoutException: connect timed out
**elasticsearch_cordinator** | at java.net.PlainSocketImpl.socketConnect(Native Method) ~[?:?]
**elasticsearch_cordinator** | at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:399) ~[?:?]
**elasticsearch_cordinator** | at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:242) ~[?:?]
**elasticsearch_cordinator** | at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:224) ~[?:?]
**elasticsearch_cordinator** | at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:403) ~[?:?]
**elasticsearch_cordinator** | at java.net.Socket.connect(Socket.java:591) ~[?:?]
**elasticsearch_cordinator** | at org.apache.http.conn.ssl.SSLConnectionSocketFactory.connectSocket(SSLConnectionSocketFactory.java:337) ~[httpclient-4.5.2.jar:4.5.2]
**elasticsearch_cordinator** | ... 25 more