Class WebhookPinger

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

public class WebhookPinger extends Object
Synchronously ping a Webhook.
Since:
v2.7
  • Constructor Summary

    Constructors
    Constructor
    Description
    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

    Modifier and Type
    Method
    Description
    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 Details

    • 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 Details

    • 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.