Skip to content

Commit 37e7272

Browse files
CurtHagenlocherkou
authored andcommitted
apacheGH-41375: [C#] Move to .NET 8.0 (apache#41376)
### What changes are included in this PR? Changes to workflow infrastructure and projects to install and target net8.0 instead of net7.0. ### Are these changes tested? Yes ### Are there any user-facing changes? Users will need to install .NET 8 to run tests and examples. No impact on product code. Closes apache#41375 * GitHub Issue: apache#41375 Lead-authored-by: Curt Hagenlocher <curt@hagenlocher.org> Co-authored-by: Sutou Kouhei <kou@clear-code.com> Signed-off-by: Curt Hagenlocher <curt@hagenlocher.org>
1 parent 4525f6a commit 37e7272

File tree

19 files changed

+28
-26
lines changed

19 files changed

+28
-26
lines changed

.env

+1-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ UBUNTU=20.04
5656
CLANG_TOOLS=14
5757
CUDA=11.2.2
5858
DASK=latest
59-
DOTNET=7.0
59+
DOTNET=8.0
6060
GCC_VERSION=""
6161
GO=1.21.8
6262
STATICCHECK=v0.4.7

.github/workflows/csharp.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ jobs:
4646
strategy:
4747
fail-fast: false
4848
matrix:
49-
dotnet: ['7.0.x']
49+
dotnet: ['8.0.x']
5050
steps:
5151
- name: Install C#
5252
uses: actions/setup-dotnet@v4
@@ -74,7 +74,7 @@ jobs:
7474
strategy:
7575
fail-fast: false
7676
matrix:
77-
dotnet: ['7.0.x']
77+
dotnet: ['8.0.x']
7878
steps:
7979
- name: Install C#
8080
uses: actions/setup-dotnet@v4
@@ -101,7 +101,7 @@ jobs:
101101
strategy:
102102
fail-fast: false
103103
matrix:
104-
dotnet: ['7.0.x']
104+
dotnet: ['8.0.x']
105105
steps:
106106
- name: Install C#
107107
uses: actions/setup-dotnet@v4

.github/workflows/dev.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ jobs:
115115
- name: Install .NET
116116
uses: actions/setup-dotnet@4d6c8fcf3c8f7a60068d26b594648e99df24cee3 # v4.0.0
117117
with:
118-
dotnet-version: '7.0.x'
118+
dotnet-version: '8.0.x'
119119
- name: Install Dependencies
120120
shell: bash
121121
run: |

ci/docker/conda-integration.dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ RUN wget -nv -O - https://dl.google.com/go/go${go}.linux-${arch}.tar.gz | tar -x
5656

5757
ENV DOTNET_ROOT=/opt/dotnet \
5858
PATH=/opt/dotnet:$PATH
59-
RUN curl -sSL https://dot.net/v1/dotnet-install.sh | bash /dev/stdin -Channel 7.0 -InstallDir /opt/dotnet
59+
RUN curl -sSL https://dot.net/v1/dotnet-install.sh | bash /dev/stdin -Channel 8.0 -InstallDir /opt/dotnet
6060

6161
ENV ARROW_ACERO=OFF \
6262
ARROW_AZURE=OFF \

ci/docker/ubuntu-22.04-csharp.dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
# under the License.
1717

1818
ARG arch=amd64
19-
ARG dotnet=7.0
19+
ARG dotnet=8.0
2020
ARG platform=jammy
2121
FROM mcr.microsoft.com/dotnet/sdk:${dotnet}-${platform}-${arch}
2222

csharp/examples/FlightAspServerExample/FlightAspServerExample.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<Project Sdk="Microsoft.NET.Sdk.Web">
2121

2222
<PropertyGroup>
23-
<TargetFramework>net7.0</TargetFramework>
23+
<TargetFramework>net8.0</TargetFramework>
2424
<Nullable>enable</Nullable>
2525
<ImplicitUsings>enable</ImplicitUsings>
2626
<LangVersion>10</LangVersion>

csharp/examples/FlightClientExample/FlightClientExample.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
<PropertyGroup>
2323
<OutputType>Exe</OutputType>
24-
<TargetFramework>net7.0</TargetFramework>
24+
<TargetFramework>net8.0</TargetFramework>
2525
</PropertyGroup>
2626

2727
<ItemGroup>

csharp/examples/FluentBuilderExample/FluentBuilderExample.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
<PropertyGroup>
44
<OutputType>Exe</OutputType>
5-
<TargetFramework>net7.0</TargetFramework>
5+
<TargetFramework>net8.0</TargetFramework>
66
</PropertyGroup>
77

88
<ItemGroup>

csharp/test/Apache.Arrow.Benchmarks/Apache.Arrow.Benchmarks.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
<PropertyGroup>
44
<OutputType>Exe</OutputType>
5-
<TargetFramework>net7.0</TargetFramework>
5+
<TargetFramework>net8.0</TargetFramework>
66
</PropertyGroup>
77

88
<ItemGroup>

csharp/test/Apache.Arrow.Compression.Tests/Apache.Arrow.Compression.Tests.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>net7.0</TargetFramework>
4+
<TargetFramework>net8.0</TargetFramework>
55

66
<IsPackable>false</IsPackable>
77
</PropertyGroup>

csharp/test/Apache.Arrow.Flight.Sql.Tests/Apache.Arrow.Flight.Sql.Tests.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>net7.0</TargetFramework>
4+
<TargetFramework>net8.0</TargetFramework>
55
<IsPackable>false</IsPackable>
66
</PropertyGroup>
77

csharp/test/Apache.Arrow.Flight.TestWeb/Apache.Arrow.Flight.TestWeb.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk.Web">
22

33
<PropertyGroup>
4-
<TargetFrameworks>net7.0</TargetFrameworks>
4+
<TargetFrameworks>net8.0</TargetFrameworks>
55
</PropertyGroup>
66

77
<ItemGroup>

csharp/test/Apache.Arrow.Flight.Tests/Apache.Arrow.Flight.Tests.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFrameworks>net7.0</TargetFrameworks>
4+
<TargetFrameworks>net8.0</TargetFrameworks>
55
<IsPackable>false</IsPackable>
66
</PropertyGroup>
77

csharp/test/Apache.Arrow.IntegrationTest/Apache.Arrow.IntegrationTest.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<PropertyGroup>
55
<OutputType>Exe</OutputType>
66
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
7-
<TargetFrameworks>net7.0</TargetFrameworks>
7+
<TargetFrameworks>net8.0</TargetFrameworks>
88
</PropertyGroup>
99

1010
<ItemGroup>

csharp/test/Apache.Arrow.Tests/Apache.Arrow.Tests.csproj

+4-2
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,15 @@
44
<PropertyGroup>
55
<IsWindows Condition="'$([System.Runtime.InteropServices.RuntimeInformation]::IsOSPlatform($([System.Runtime.InteropServices.OSPlatform]::Windows)))' == 'true'">true</IsWindows>
66
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
7+
<!-- Required for PythonNET -->
8+
<EnableUnsafeBinaryFormatterSerialization>true</EnableUnsafeBinaryFormatterSerialization>
79
</PropertyGroup>
810

911
<PropertyGroup Condition="'$(IsWindows)'=='true'">
10-
<TargetFrameworks>net7.0;net472;net462</TargetFrameworks>
12+
<TargetFrameworks>net8.0;net472;net462</TargetFrameworks>
1113
</PropertyGroup>
1214
<PropertyGroup Condition="'$(IsWindows)'!='true'">
13-
<TargetFrameworks>net7.0</TargetFrameworks>
15+
<TargetFrameworks>net8.0</TargetFrameworks>
1416
</PropertyGroup>
1517

1618
<ItemGroup>

dev/archery/archery/integration/tester_csharp.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828

2929
_EXE_PATH = os.path.join(_ARTIFACTS_PATH,
3030
"Apache.Arrow.IntegrationTest",
31-
"Debug/net7.0/Apache.Arrow.IntegrationTest",
31+
"Debug/net8.0/Apache.Arrow.IntegrationTest",
3232
)
3333

3434
_clr_loaded = False
@@ -44,10 +44,10 @@ def _load_clr():
4444
import clr
4545
clr.AddReference(
4646
f"{_ARTIFACTS_PATH}/Apache.Arrow.IntegrationTest/"
47-
f"Debug/net7.0/Apache.Arrow.IntegrationTest.dll")
47+
f"Debug/net8.0/Apache.Arrow.IntegrationTest.dll")
4848
clr.AddReference(
4949
f"{_ARTIFACTS_PATH}/Apache.Arrow.Tests/"
50-
f"Debug/net7.0/Apache.Arrow.Tests.dll")
50+
f"Debug/net8.0/Apache.Arrow.Tests.dll")
5151

5252
from Apache.Arrow.IntegrationTest import CDataInterface
5353
CDataInterface.Initialize()

dev/release/verify-release-candidate.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -347,15 +347,15 @@ install_csharp() {
347347

348348
show_info "Ensuring that C# is installed..."
349349

350-
if dotnet --version | grep 7\.0 > /dev/null 2>&1; then
350+
if dotnet --version | grep 8\.0 > /dev/null 2>&1; then
351351
local csharp_bin=$(dirname $(which dotnet))
352352
show_info "Found C# at $(which csharp) (.NET $(dotnet --version))"
353353
else
354354
if which dotnet > /dev/null 2>&1; then
355355
show_info "dotnet found but it is the wrong version and will be ignored."
356356
fi
357357
local csharp_bin=${ARROW_TMPDIR}/csharp/bin
358-
local dotnet_version=7.0.102
358+
local dotnet_version=8.0.204
359359
local dotnet_platform=
360360
case "$(uname)" in
361361
Linux)

dev/tasks/verify-rc/github.macos.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,9 @@ jobs:
5151
distribution: 'temurin'
5252
java-version: '11'
5353

54-
- uses: actions/setup-dotnet@v2
54+
- uses: actions/setup-dotnet@v4
5555
with:
56-
dotnet-version: '7.0.x'
56+
dotnet-version: '8.0.x'
5757

5858
- uses: actions/setup-node@v4
5959
with:

docs/source/developers/release_verification.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ As an example:
152152
* NVIDIA CUDA Build cuda_11.5.r11.5/compiler.30672275_0
153153
* openjdk version "17.0.9" 2023-10-17
154154
* ruby 3.0.2p107 (2021-07-07 revision 0db68f0233) [x86_64-linux-gnu]
155-
* dotnet 7.0.115
155+
* dotnet 8.0.204
156156
* Ubuntu 22.04 LTS
157157
158158
If there were some issues during verification please report them on the

0 commit comments

Comments
 (0)