diff --git a/Directory.Packages.props b/Directory.Packages.props
index d4d47c86..9a37ea70 100644
--- a/Directory.Packages.props
+++ b/Directory.Packages.props
@@ -19,11 +19,12 @@
-
+
+
-
-
+
+
diff --git a/README.md b/README.md
index c8951599..c4a3776b 100644
--- a/README.md
+++ b/README.md
@@ -12,12 +12,13 @@ We use this library within our components to publish [StatsD](http://github.com/
### Supported platforms
-`JustEat.StatsD` version 4.1.0 is built for these target frameworks:
+`JustEat.StatsD` version 4.2.0 is built for these target frameworks:
* `net461`
* `netstandard2.0`
* `netstandard2.1`
* `netcoreapp2.1`
+* `net5.0`
### Features
diff --git a/global.json b/global.json
index ee50270a..e0f5e71e 100644
--- a/global.json
+++ b/global.json
@@ -1,6 +1,6 @@
{
"sdk": {
- "version": "3.1.403",
+ "version": "5.0.100",
"allowPrerelease": false,
"rollForward": "latestMajor"
}
diff --git a/src/JustEat.StatsD/ConnectedSocketPool.cs b/src/JustEat.StatsD/ConnectedSocketPool.cs
index ed84fa6e..7de3adb7 100644
--- a/src/JustEat.StatsD/ConnectedSocketPool.cs
+++ b/src/JustEat.StatsD/ConnectedSocketPool.cs
@@ -48,7 +48,7 @@ private Socket CreateSocket()
/// An object from the pool.
private Socket? Pop()
{
- if (_pool.TryTake(out Socket result))
+ if (_pool.TryTake(out Socket? result))
{
return result;
}
diff --git a/src/JustEat.StatsD/EndpointLookups/EndPointFactory.cs b/src/JustEat.StatsD/EndpointLookups/EndPointFactory.cs
index c89e58c4..ef3ca90b 100644
--- a/src/JustEat.StatsD/EndpointLookups/EndPointFactory.cs
+++ b/src/JustEat.StatsD/EndpointLookups/EndPointFactory.cs
@@ -57,7 +57,7 @@ public static IEndPointSource MakeEndPointSource(string host, int port, TimeSpan
IEndPointSource source;
- if (IPAddress.TryParse(host, out IPAddress address))
+ if (IPAddress.TryParse(host, out IPAddress? address))
{
// If we were given an IP instead of a hostname,
// we can happily keep it the life of this class
diff --git a/src/JustEat.StatsD/JustEat.StatsD.csproj b/src/JustEat.StatsD/JustEat.StatsD.csproj
index 4521d393..10fcec5b 100644
--- a/src/JustEat.StatsD/JustEat.StatsD.csproj
+++ b/src/JustEat.StatsD/JustEat.StatsD.csproj
@@ -7,7 +7,7 @@
JustEat.StatsD
JustEat.StatsD
A .NET library for publishing metrics to StatsD.
- net461;netstandard2.0;netstandard2.1;netcoreapp2.1
+ net461;netstandard2.0;netstandard2.1;netcoreapp2.1;net5.0
diff --git a/tests/JustEat.StatsD.Tests/JustEat.StatsD.Tests.csproj b/tests/JustEat.StatsD.Tests/JustEat.StatsD.Tests.csproj
index 3d6f41ed..c1b5b477 100644
--- a/tests/JustEat.StatsD.Tests/JustEat.StatsD.Tests.csproj
+++ b/tests/JustEat.StatsD.Tests/JustEat.StatsD.Tests.csproj
@@ -2,7 +2,7 @@
$(NoWarn);CA1707;CA2007
JustEat.StatsD
- netcoreapp3.1
+ net5.0
diff --git a/version.props b/version.props
index 6357ee5e..21604418 100644
--- a/version.props
+++ b/version.props
@@ -1,7 +1,7 @@
4.0.0.0
- 4.1.0
+ 4.2.0
beta$([System.Convert]::ToInt32(`$(GITHUB_RUN_NUMBER)`).ToString(`0000`))
$(GITHUB_REF.Replace('refs/tags/v', ''))