mirror of
https://github.com/space-wizards/RobustToolbox.git
synced 2026-02-15 03:30:53 +01:00
Add net.mtu_ipv6 CVar.
Wires up to the new MaximumTransmissionUnitV6 configuration in Lidgren. Default is that of Lidgren.
This commit is contained in:
@@ -42,6 +42,7 @@ END TEMPLATE-->
|
||||
* Made a new `IMetricsManager` interface with an `UpdateMetrics` event that can be used to update Prometheus metrics whenever they are scraped.
|
||||
* Also added a `metrics.update_interval` CVar to go along with this, when metrics are scraped without usage of Prometheus directly.
|
||||
* IoC now contains an `IMeterFactory` implementation that you can use to instantiate metric meters.
|
||||
* `net.mtu_ipv6` CVar allows specifying a different MTU value for IPv6.
|
||||
|
||||
### Bugfixes
|
||||
|
||||
|
||||
@@ -65,16 +65,26 @@ namespace Robust.Shared
|
||||
CVarDef.Create("net.pool_size", 512, CVar.CLIENT | CVar.SERVER);
|
||||
|
||||
/// <summary>
|
||||
/// Maximum UDP payload size to send.
|
||||
/// Maximum UDP payload size to send by default, for IPv4.
|
||||
/// </summary>
|
||||
/// <seealso cref="NetMtuExpand"/>
|
||||
/// <seealso cref="NetMtuIpv6"/>
|
||||
public static readonly CVarDef<int> NetMtu =
|
||||
CVarDef.Create("net.mtu", 900, CVar.ARCHIVE);
|
||||
|
||||
/// <summary>
|
||||
/// Maximum UDP payload size to send by default, for IPv6.
|
||||
/// </summary>
|
||||
/// <seealso cref="NetMtu"/>
|
||||
/// <seealso cref="NetMtuExpand"/>
|
||||
public static readonly CVarDef<int> NetMtuIpv6 =
|
||||
CVarDef.Create("net.mtu_ipv6", NetPeerConfiguration.kDefaultMTUV6, CVar.ARCHIVE);
|
||||
|
||||
/// <summary>
|
||||
/// If set, automatically try to detect MTU above <see cref="NetMtu"/>.
|
||||
/// </summary>
|
||||
/// <seealso cref="NetMtu"/>
|
||||
/// <seealso cref="NetMtuIpv6"/>
|
||||
/// <seealso cref="NetMtuExpandFrequency"/>
|
||||
/// <seealso cref="NetMtuExpandFailAttempts"/>
|
||||
public static readonly CVarDef<bool> NetMtuExpand =
|
||||
|
||||
@@ -619,6 +619,7 @@ namespace Robust.Shared.Network
|
||||
|
||||
// MTU stuff.
|
||||
netConfig.MaximumTransmissionUnit = _config.GetCVar(CVars.NetMtu);
|
||||
netConfig.MaximumTransmissionUnitV6 = _config.GetCVar(CVars.NetMtuIpv6);
|
||||
netConfig.AutoExpandMTU = _config.GetCVar(CVars.NetMtuExpand);
|
||||
netConfig.ExpandMTUFrequency = _config.GetCVar(CVars.NetMtuExpandFrequency);
|
||||
netConfig.ExpandMTUFailAttempts = _config.GetCVar(CVars.NetMtuExpandFailAttempts);
|
||||
|
||||
Reference in New Issue
Block a user