summaryrefslogtreecommitdiff
path: root/docs/src/api/overview
diff options
context:
space:
mode:
authorjwijenbergh <jeroenwijenbergh@protonmail.com>2023-03-21 15:43:46 +0100
committerJeroen Wijenbergh <46386452+jwijenbergh@users.noreply.github.com>2023-09-25 09:43:37 +0200
commita8e43d757000fbfd783026925ad4ea4ef9efc0d0 (patch)
tree61e60ae45934d9a7699feb208c7d4dc76fd82cd7 /docs/src/api/overview
parent68d43ba53ec44dd8e008d8c6ce564d051ef0a88d (diff)
Docs API: Update links to .md
Diffstat (limited to 'docs/src/api/overview')
-rw-r--r--docs/src/api/overview/README.md10
1 files changed, 6 insertions, 4 deletions
diff --git a/docs/src/api/overview/README.md b/docs/src/api/overview/README.md
index 475f9fb..989e8a6 100644
--- a/docs/src/api/overview/README.md
+++ b/docs/src/api/overview/README.md
@@ -242,7 +242,7 @@ Arguments:
Return type:
- The servers (`types.discovery.Servers`)
-- An error message (`string`). Empty string if no error. Note that if an error is returned, when building this library in [release mode](https://eduvpn.github.io/eduvpn-common/gettingstarted/building/release.html) this function is guaranteed to return a result for the servers, unless there is an issue with parsing the internal data representation. So the error can be used for logging instead of being a hard-fail
+- An error message (`string`). Empty string if no error. Note that if an error is returned, when building this library in [release mode](/gettingstarted/building/release.md) this function is guaranteed to return a result for the servers, unless there is an issue with parsing the internal data representation. So the error can be used for logging instead of being a hard-fail
### Discovery organizations
Get the discovery organizations from <https://disco.eduvpn.org/v2/organizations_list.json>. This returns a cached list if the server should not be contacted according to the eduvpn spec at <https://github.com/eduvpn/documentation/blob/v3/SERVER_DISCOVERY.md>. So you do not have to worry about when to call this functions. Clients may cache further to prevent parsing this data every time.
@@ -252,7 +252,7 @@ Arguments:
Return type:
- The organizations (`types.discovery.Organizations`)
-- An error. Note that if an error is returned, when building this library in [release mode](https://eduvpn.github.io/eduvpn-common/gettingstarted/building/release.html) this function is guaranteed to return a result for the organizations, unless there is an issue with parsing the internal data representation. So the error can be used for logging instead of being a hard-fail
+- An error. Note that if an error is returned, when building this library in [release mode](/gettingstarted/building/release.md) this function is guaranteed to return a result for the organizations, unless there is an issue with parsing the internal data representation. So the error can be used for logging instead of being a hard-fail
### Cancel OAuth
Cancel the current OAuth process.
@@ -306,12 +306,14 @@ Return type:
### Start Failover
-Eduvpn-common also has a `failover` implementation. This is used to check whether or not the VPN can reach the internet. Useful when connecting to WireGuard or OpenVPN over TCP. This functions sends pings for a maximum of 10 seconds up until it is dropped. If a ping can be send and a pong returns within a timeout of 2 seconds, it returns after this pong is received.
+Eduvpn-common also has a `failover` implementation that can be started with `start failover`. This is used to check whether or not the VPN can reach the internet. Useful when connecting to WireGuard or OpenVPN over UDP. This functions sends pings for a maximum of 10 seconds up until it is dropped. If a ping can be send and a pong returns within a timeout of 2 seconds, it returns after this pong is received.
+
+If this functions tells you that the VPN is dropped, it might be wise to get a configuration again using Prefer TCP (see [Get VPN Config](#get-vpn-config)) and disabling WireGuard (see [Set Support Wireguard](#set-support-wireguard)). Note that this `start failover` function also checks if the current profile supports OpenVPN and will return an error if it doesn't.
Arguments:
- Gateway (`string`), the IP endpoint to ping to check if the VPN can reach the internet. As the name suggests, this should be the gateway
- MTU (`int`), the packet size to send for each ping. As the name suggests, this should be the MTU of the connection
-- readRxBytes, a function that returns the current Rx bytes counter for the connection. Used to check if any bytes have been received after a maximum of 10 seconds
+- `readRxBytes`, a function that returns the current Rx bytes counter (`int64` in Go, `long long int` in CGO api) for the connection. Used to check if any bytes have been received in an interval of maximum 10 seconds
Return type:
- Dropped: a boolean that indicates whether or not the connection is dropped according to eduvpn-common. This means that the VPN is unable to reach the gateway