You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@arrow.apache.org by ks...@apache.org on 2022/04/24 17:58:18 UTC

[arrow] branch master updated: ARROW-16176: [Release][C#] Use .NET 6.0 on Ubuntu 22.04

This is an automated email from the ASF dual-hosted git repository.

kszucs pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/arrow.git


The following commit(s) were added to refs/heads/master by this push:
     new f275f50792 ARROW-16176: [Release][C#] Use .NET 6.0 on Ubuntu 22.04
f275f50792 is described below

commit f275f50792fb80e1615427620fd32681ecf3e07a
Author: Sutou Kouhei <ko...@clear-code.com>
AuthorDate: Sun Apr 24 19:58:05 2022 +0200

    ARROW-16176: [Release][C#] Use .NET 6.0 on Ubuntu 22.04
    
    Ubuntu 22.04 ships OpenSSL 3 and .NET 5.0 or earlier doesn't support
    OpenSSL 3 yet.
    
    Closes #12870 from kou/release-ubuntu-22.04-csharp
    
    Lead-authored-by: Sutou Kouhei <ko...@clear-code.com>
    Co-authored-by: Krisztián Szűcs <sz...@gmail.com>
    Co-authored-by: Eric Erhardt <er...@microsoft.com>
    Signed-off-by: Krisztián Szűcs <sz...@gmail.com>
---
 .env                                                              | 2 +-
 .github/workflows/csharp.yml                                      | 6 +++---
 ci/docker/conda-integration.dockerfile                            | 2 +-
 ci/docker/ubuntu-18.04-csharp.dockerfile                          | 2 +-
 csharp/examples/FluentBuilderExample/FluentBuilderExample.csproj  | 2 +-
 csharp/src/Apache.Arrow/Apache.Arrow.csproj                       | 8 ++++----
 ...Extensions.netcoreapp2.1.cs => StreamExtensions.netcoreapp.cs} | 0
 .../test/Apache.Arrow.Benchmarks/Apache.Arrow.Benchmarks.csproj   | 2 +-
 .../Apache.Arrow.Flight.TestWeb.csproj                            | 2 +-
 .../Apache.Arrow.Flight.Tests/Apache.Arrow.Flight.Tests.csproj    | 2 +-
 .../Apache.Arrow.IntegrationTest.csproj                           | 2 +-
 csharp/test/Apache.Arrow.Tests/Apache.Arrow.Tests.csproj          | 2 +-
 dev/archery/archery/integration/tester_csharp.py                  | 2 +-
 dev/release/verify-release-candidate.sh                           | 4 ++--
 dev/tasks/verify-rc/github.macos.amd64.yml                        | 4 ++++
 15 files changed, 23 insertions(+), 19 deletions(-)

diff --git a/.env b/.env
index 73ecaf70a1..9be6198bbb 100644
--- a/.env
+++ b/.env
@@ -55,7 +55,7 @@ UBUNTU=20.04
 CLANG_TOOLS=12
 CUDA=9.1
 DASK=latest
-DOTNET=3.1
+DOTNET=6.0
 GCC_VERSION=""
 GO=1.16
 HDFS=3.2.1
diff --git a/.github/workflows/csharp.yml b/.github/workflows/csharp.yml
index ac902ccb31..07fd2aec5a 100644
--- a/.github/workflows/csharp.yml
+++ b/.github/workflows/csharp.yml
@@ -43,7 +43,7 @@ jobs:
     strategy:
       fail-fast: false
       matrix:
-        dotnet: ['3.1.x']
+        dotnet: ['6.0.x']
     steps:
       - name: Install C#
         uses: actions/setup-dotnet@v1
@@ -71,7 +71,7 @@ jobs:
     strategy:
       fail-fast: false
       matrix:
-        dotnet: ['3.1.x']
+        dotnet: ['6.0.x']
     steps:
       - name: Install C#
         uses: actions/setup-dotnet@v1
@@ -98,7 +98,7 @@ jobs:
     strategy:
       fail-fast: false
       matrix:
-        dotnet: ['3.1.x']
+        dotnet: ['6.0.x']
     steps:
       - name: Install C#
         uses: actions/setup-dotnet@v1
diff --git a/ci/docker/conda-integration.dockerfile b/ci/docker/conda-integration.dockerfile
index 652d4f4901..0964d5da4f 100644
--- a/ci/docker/conda-integration.dockerfile
+++ b/ci/docker/conda-integration.dockerfile
@@ -52,7 +52,7 @@ RUN wget -nv -O - https://dl.google.com/go/go${go}.linux-${arch}.tar.gz | tar -x
 
 ENV DOTNET_ROOT=/opt/dotnet \
     PATH=/opt/dotnet:$PATH
-RUN curl -sSL https://dot.net/v1/dotnet-install.sh | bash /dev/stdin -Channel 3.1 -InstallDir /opt/dotnet
+RUN curl -sSL https://dot.net/v1/dotnet-install.sh | bash /dev/stdin -Channel 6.0 -InstallDir /opt/dotnet
 
 ENV ARROW_BUILD_INTEGRATION=ON \
     ARROW_BUILD_STATIC=OFF \
diff --git a/ci/docker/ubuntu-18.04-csharp.dockerfile b/ci/docker/ubuntu-18.04-csharp.dockerfile
index 624ce259d5..cfed8018bb 100644
--- a/ci/docker/ubuntu-18.04-csharp.dockerfile
+++ b/ci/docker/ubuntu-18.04-csharp.dockerfile
@@ -16,7 +16,7 @@
 # under the License.
 
 ARG platform=bionic
-ARG dotnet=3.1
+ARG dotnet=6.0
 FROM mcr.microsoft.com/dotnet/core/sdk:${dotnet}-${platform}
 
 RUN dotnet tool install --tool-path /usr/local/bin sourcelink
diff --git a/csharp/examples/FluentBuilderExample/FluentBuilderExample.csproj b/csharp/examples/FluentBuilderExample/FluentBuilderExample.csproj
index 575a2743eb..ff66d69800 100644
--- a/csharp/examples/FluentBuilderExample/FluentBuilderExample.csproj
+++ b/csharp/examples/FluentBuilderExample/FluentBuilderExample.csproj
@@ -2,7 +2,7 @@
   
   <PropertyGroup>
     <OutputType>Exe</OutputType>
-    <TargetFramework>netcoreapp2.1</TargetFramework>
+    <TargetFramework>net6.0</TargetFramework>
   </PropertyGroup>
 
   <ItemGroup>
diff --git a/csharp/src/Apache.Arrow/Apache.Arrow.csproj b/csharp/src/Apache.Arrow/Apache.Arrow.csproj
index 62574029f9..70f821218d 100644
--- a/csharp/src/Apache.Arrow/Apache.Arrow.csproj
+++ b/csharp/src/Apache.Arrow/Apache.Arrow.csproj
@@ -1,7 +1,7 @@
 <Project Sdk="Microsoft.NET.Sdk">
 
   <PropertyGroup>
-    <TargetFrameworks>netstandard1.3;netcoreapp2.1</TargetFrameworks>
+    <TargetFrameworks>netstandard1.3;netcoreapp3.1</TargetFrameworks>
     <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
     <DefineConstants>$(DefineConstants);UNSAFE_BYTEBUFFER;BYTEBUFFER_NO_BOUNDS_CHECK;ENABLE_SPAN_T</DefineConstants>
     
@@ -32,10 +32,10 @@
     </EmbeddedResource>
   </ItemGroup>
 
-  <ItemGroup Condition="'$(TargetFramework)' == 'netstandard1.3'">
-    <Compile Remove="Extensions\StreamExtensions.netcoreapp2.1.cs" />
+  <ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETStandard'">
+    <Compile Remove="Extensions\StreamExtensions.netcoreapp.cs" />
   </ItemGroup>
-  <ItemGroup Condition="'$(TargetFramework)' == 'netcoreapp2.1'">
+  <ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETCoreApp'">
     <Compile Remove="Extensions\StreamExtensions.netstandard.cs" />
     <Compile Remove="Extensions\TupleExtensions.netstandard.cs" />
   </ItemGroup>
diff --git a/csharp/src/Apache.Arrow/Extensions/StreamExtensions.netcoreapp2.1.cs b/csharp/src/Apache.Arrow/Extensions/StreamExtensions.netcoreapp.cs
similarity index 100%
rename from csharp/src/Apache.Arrow/Extensions/StreamExtensions.netcoreapp2.1.cs
rename to csharp/src/Apache.Arrow/Extensions/StreamExtensions.netcoreapp.cs
diff --git a/csharp/test/Apache.Arrow.Benchmarks/Apache.Arrow.Benchmarks.csproj b/csharp/test/Apache.Arrow.Benchmarks/Apache.Arrow.Benchmarks.csproj
index e38d538af6..a2d142911c 100644
--- a/csharp/test/Apache.Arrow.Benchmarks/Apache.Arrow.Benchmarks.csproj
+++ b/csharp/test/Apache.Arrow.Benchmarks/Apache.Arrow.Benchmarks.csproj
@@ -2,7 +2,7 @@
 
   <PropertyGroup>
     <OutputType>Exe</OutputType>
-    <TargetFramework>netcoreapp3.1</TargetFramework>
+    <TargetFramework>net6.0</TargetFramework>
   </PropertyGroup>
 
   <ItemGroup>
diff --git a/csharp/test/Apache.Arrow.Flight.TestWeb/Apache.Arrow.Flight.TestWeb.csproj b/csharp/test/Apache.Arrow.Flight.TestWeb/Apache.Arrow.Flight.TestWeb.csproj
index 0270283a46..b07959cf55 100644
--- a/csharp/test/Apache.Arrow.Flight.TestWeb/Apache.Arrow.Flight.TestWeb.csproj
+++ b/csharp/test/Apache.Arrow.Flight.TestWeb/Apache.Arrow.Flight.TestWeb.csproj
@@ -1,7 +1,7 @@
 <Project Sdk="Microsoft.NET.Sdk.Web">
 
   <PropertyGroup>
-    <TargetFramework>netcoreapp3.1</TargetFramework>
+    <TargetFramework>net6.0</TargetFramework>
   </PropertyGroup>
 
   <ItemGroup>
diff --git a/csharp/test/Apache.Arrow.Flight.Tests/Apache.Arrow.Flight.Tests.csproj b/csharp/test/Apache.Arrow.Flight.Tests/Apache.Arrow.Flight.Tests.csproj
index 31efc526ef..b72720642d 100644
--- a/csharp/test/Apache.Arrow.Flight.Tests/Apache.Arrow.Flight.Tests.csproj
+++ b/csharp/test/Apache.Arrow.Flight.Tests/Apache.Arrow.Flight.Tests.csproj
@@ -1,7 +1,7 @@
 <Project Sdk="Microsoft.NET.Sdk">
 
   <PropertyGroup>
-    <TargetFramework>netcoreapp3.1</TargetFramework>
+    <TargetFramework>net6.0</TargetFramework>
 
     <IsPackable>false</IsPackable>
   </PropertyGroup>
diff --git a/csharp/test/Apache.Arrow.IntegrationTest/Apache.Arrow.IntegrationTest.csproj b/csharp/test/Apache.Arrow.IntegrationTest/Apache.Arrow.IntegrationTest.csproj
index 8137340840..8d85b0952c 100644
--- a/csharp/test/Apache.Arrow.IntegrationTest/Apache.Arrow.IntegrationTest.csproj
+++ b/csharp/test/Apache.Arrow.IntegrationTest/Apache.Arrow.IntegrationTest.csproj
@@ -3,7 +3,7 @@
 
   <PropertyGroup>
     <OutputType>Exe</OutputType>
-    <TargetFramework>netcoreapp3.1</TargetFramework>
+    <TargetFramework>net6.0</TargetFramework>
   </PropertyGroup>
 
   <ItemGroup>
diff --git a/csharp/test/Apache.Arrow.Tests/Apache.Arrow.Tests.csproj b/csharp/test/Apache.Arrow.Tests/Apache.Arrow.Tests.csproj
index a725fe57e8..b0de6df148 100644
--- a/csharp/test/Apache.Arrow.Tests/Apache.Arrow.Tests.csproj
+++ b/csharp/test/Apache.Arrow.Tests/Apache.Arrow.Tests.csproj
@@ -2,7 +2,7 @@
 <Project Sdk="Microsoft.NET.Sdk">
 
   <PropertyGroup>
-    <TargetFramework>netcoreapp3.1</TargetFramework>
+    <TargetFramework>net6.0</TargetFramework>
     <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
   </PropertyGroup>
 
diff --git a/dev/archery/archery/integration/tester_csharp.py b/dev/archery/archery/integration/tester_csharp.py
index 5750eacfeb..144709f2e9 100644
--- a/dev/archery/archery/integration/tester_csharp.py
+++ b/dev/archery/archery/integration/tester_csharp.py
@@ -24,7 +24,7 @@ from .util import run_cmd, ARROW_ROOT_DEFAULT, log
 _EXE_PATH = os.path.join(
     ARROW_ROOT_DEFAULT,
     "csharp/artifacts/Apache.Arrow.IntegrationTest",
-    "Debug/netcoreapp3.1/Apache.Arrow.IntegrationTest",
+    "Debug/net6.0/Apache.Arrow.IntegrationTest",
 )
 
 
diff --git a/dev/release/verify-release-candidate.sh b/dev/release/verify-release-candidate.sh
index c61a55db6b..01b2173d1d 100755
--- a/dev/release/verify-release-candidate.sh
+++ b/dev/release/verify-release-candidate.sh
@@ -342,7 +342,7 @@ install_csharp() {
     show_info "Found C# at $(which csharp) (.NET $(dotnet --version))"
   else
     local csharp_bin=${ARROW_TMPDIR}/csharp/bin
-    local dotnet_version=3.1.405
+    local dotnet_version=6.0.202
     local dotnet_platform=
     case "$(uname)" in
       Linux)
@@ -795,7 +795,7 @@ test_csharp() {
   fi
 
   sourcelink test artifacts/Apache.Arrow/Release/netstandard1.3/Apache.Arrow.pdb
-  sourcelink test artifacts/Apache.Arrow/Release/netcoreapp2.1/Apache.Arrow.pdb
+  sourcelink test artifacts/Apache.Arrow/Release/netcoreapp3.1/Apache.Arrow.pdb
 
   popd
 }
diff --git a/dev/tasks/verify-rc/github.macos.amd64.yml b/dev/tasks/verify-rc/github.macos.amd64.yml
index a60932a9a3..3ab9be3157 100644
--- a/dev/tasks/verify-rc/github.macos.amd64.yml
+++ b/dev/tasks/verify-rc/github.macos.amd64.yml
@@ -50,6 +50,10 @@ jobs:
           distribution: 'temurin'
           java-version: '11'
 
+      - uses: actions/setup-dotnet@v2
+        with:
+          dotnet-version: '6.0.x'
+
       - uses: actions/setup-node@v2-beta
         with:
           node-version: '16'