Appearance
Ping
Sends one ICMP echo request (ping) to a host for every record it receives and emits the result. Use it for simple availability checks of servers and network devices.
Pins
| Pin | Kind | Types | Description |
|---|---|---|---|
| Input | input | any | Each record triggers one ping. The input content is not used. |
| Output | output | Viaducta.Plugins.PingPlugin.PingReply | Result of the ping. |
| Continue | continue | same as input | Called after Output with the original input data and metadata. |
Configuration
| Field | Type | Default | Description |
|---|---|---|---|
Address | string | IP address or host name to ping. | |
Timeout | integer (seconds) | 20 | How long to wait for the echo reply. 0 or less means 60 seconds. |
Behaviour
- For every input record one ping is sent synchronously; the component blocks until the reply arrives or the timeout expires.
Outputreceives aPingReplywith:Address: the address that replied (as text),RoundtripTime: round-trip time in milliseconds,Status: name of the .NETIPStatusvalue, e.g.Success,TimedOut,DestinationHostUnreachable.
- After
Output,Continueis called with the original input. - A timeout or unreachable host is not an error: check
Status(for example with a filter onStatus == "Success").
Notes
PingReply.IsTimeoutis never set (alwaysfalse); useStatus=TimedOutinstead.- A host name that cannot be resolved throws an exception instead of producing a
PingReply. - ICMP may be blocked by firewalls or require privileges on some Linux hosts; a failing ping does not prove that a TCP service is down.
Addresscomes only from the configuration, not from the input record; to ping several hosts, use one component per host.
Example
json
{ "Address": "192.168.1.10", "Timeout": 5 }Timer → Ping → Decision router (Status is not Success) → Mail client