From cd8639d3cb7f3a752682ae5e133822d88397e004 Mon Sep 17 00:00:00 2001 From: barshaul Date: Tue, 19 Dec 2023 15:31:11 +0000 Subject: [PATCH] Trying to fix C# naming --- benchmarks/install_and_test.sh | 1 - csharp/lib/AsyncClient.cs | 8 ++++---- csharp/lib/Cargo.toml | 1 + csharp/lib/Logger.cs | 4 ++-- csharp/lib/glide.csproj | 2 +- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/benchmarks/install_and_test.sh b/benchmarks/install_and_test.sh index fbdb139c93..dcbaa9307d 100755 --- a/benchmarks/install_and_test.sh +++ b/benchmarks/install_and_test.sh @@ -31,7 +31,6 @@ dataSize="100 4000" clientCount="1" chosenClients="all" host="localhost" -host="localhost" port=6379 tlsFlag="--tls" javaTlsFlag="-tls" diff --git a/csharp/lib/AsyncClient.cs b/csharp/lib/AsyncClient.cs index 6aec816ee1..96519395fd 100644 --- a/csharp/lib/AsyncClient.cs +++ b/csharp/lib/AsyncClient.cs @@ -95,17 +95,17 @@ private void FailureCallback(ulong index) private delegate void StringAction(ulong index, IntPtr str); private delegate void FailureAction(ulong index); - [DllImport("libglide-rs", CallingConvention = CallingConvention.Cdecl, EntryPoint = "get")] + [DllImport("libglide_rs", CallingConvention = CallingConvention.Cdecl, EntryPoint = "get")] private static extern void GetFfi(IntPtr client, ulong index, IntPtr key); - [DllImport("libglide-rs", CallingConvention = CallingConvention.Cdecl, EntryPoint = "set")] + [DllImport("libglide_rs", CallingConvention = CallingConvention.Cdecl, EntryPoint = "set")] private static extern void SetFfi(IntPtr client, ulong index, IntPtr key, IntPtr value); private delegate void IntAction(IntPtr arg); - [DllImport("libglide-rs", CallingConvention = CallingConvention.Cdecl, EntryPoint = "create_client")] + [DllImport("libglide_rs", CallingConvention = CallingConvention.Cdecl, EntryPoint = "create_client")] private static extern IntPtr CreateClientFfi(String host, UInt32 port, bool useTLS, IntPtr successCallback, IntPtr failureCallback); - [DllImport("libglide-rs", CallingConvention = CallingConvention.Cdecl, EntryPoint = "close_client")] + [DllImport("libglide_rs", CallingConvention = CallingConvention.Cdecl, EntryPoint = "close_client")] private static extern void CloseClientFfi(IntPtr client); #endregion diff --git a/csharp/lib/Cargo.toml b/csharp/lib/Cargo.toml index 4a219f8d4f..f0f9f0889c 100644 --- a/csharp/lib/Cargo.toml +++ b/csharp/lib/Cargo.toml @@ -8,6 +8,7 @@ authors = ["Amazon Web Services"] # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [lib] +name = "glide_rs" crate-type = ["cdylib"] [dependencies] diff --git a/csharp/lib/Logger.cs b/csharp/lib/Logger.cs index 8a529350e3..8d2636134b 100644 --- a/csharp/lib/Logger.cs +++ b/csharp/lib/Logger.cs @@ -71,10 +71,10 @@ public static void SetLoggerConfig(Level? level, string? filename = null) #endregion public methods #region FFI function declaration - [DllImport("libglide-rs", CallingConvention = CallingConvention.Cdecl, EntryPoint = "log")] + [DllImport("libglide_rs", CallingConvention = CallingConvention.Cdecl, EntryPoint = "log")] private static extern void log(Int32 logLevel, byte[] logIdentifier, byte[] message); - [DllImport("libglide-rs", CallingConvention = CallingConvention.Cdecl, EntryPoint = "init")] + [DllImport("libglide_rs", CallingConvention = CallingConvention.Cdecl, EntryPoint = "init")] private static extern Level InitInternalLogger(Int32 level, byte[]? filename); #endregion diff --git a/csharp/lib/glide.csproj b/csharp/lib/glide.csproj index 19206fe70d..232637d96c 100644 --- a/csharp/lib/glide.csproj +++ b/csharp/lib/glide.csproj @@ -12,7 +12,7 @@ - + PreserveNewest %(FileName)%(Extension)