com.atlassian.crowd.manager.webhook
Class WebhookPinger

java.lang.Object
  extended by com.atlassian.crowd.manager.webhook.WebhookPinger

public class WebhookPinger
extends Object

Synchronously ping a Webhook.

Since:
v2.7

Constructor Summary
WebhookPinger()
          Constructs a pinger using an HTTP client with the default configuration.
WebhookPinger(org.apache.http.client.HttpClient httpClient)
          Constructs a pinger using the provided, already configured HTTP client.
 
Method Summary
 void ping(Webhook webhook)
          Synchronously ping a Webhook and throw IOException if the ping cannot be delivered.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WebhookPinger

public WebhookPinger()
Constructs a pinger using an HTTP client with the default configuration. This constructor exists to simplify the wiring of this object in host applications.


WebhookPinger

public WebhookPinger(org.apache.http.client.HttpClient httpClient)
Constructs a pinger using the provided, already configured HTTP client.

Parameters:
httpClient - a configured HTTP client which will be used to ping the Webhook callbacks.
Method Detail

ping

public void ping(Webhook webhook)
          throws IOException
Synchronously ping a Webhook and throw IOException if the ping cannot be delivered.

Parameters:
webhook - webhook to be pinged.
Throws:
IOException - if the ping cannot be delivered.


Copyright © 2016 Atlassian. All Rights Reserved.