Skip to content

Commit

Permalink
committing from Mac to work in Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
birojnayak committed Oct 9, 2023
1 parent 03a47fa commit d3ba5c9
Show file tree
Hide file tree
Showing 27 changed files with 420 additions and 493 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>$(ScenarioTestTargetFrameworks)</TargetFrameworks>
<CLSCompliant>false</CLSCompliant>
<IsTestProject>true</IsTestProject>
<IsPackable>false</IsPackable>
</PropertyGroup>

<ItemGroup>
<ProjectReference Include="..\..\..\..\..\System.ServiceModel.Primitives\src\System.ServiceModel.Primitives.csproj" />
<ProjectReference Include="..\..\..\..\..\System.ServiceModel.NetTcp\src\System.ServiceModel.NetTcp.csproj" />
<ProjectReference Include='$(WcfScenarioTestCommonProj)' />
<ProjectReference Include="$(WcfInfrastructureCommonProj)" />
<PackageReference Include="CoreWCF.UnixDomainSocket" Version="1.5.0-preview1" />
</ItemGroup>
</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

using System;
using System.ServiceModel;
using System.Threading;
using System.Threading.Tasks;
using Infrastructure.Common;
using Xunit;

public partial class Binding_UDSBindingTests : ConditionalWcfTest
{
// Simple echo of a string using NetTcpBinding on both client and server with SecurityMode=None
[WcfFact]
[OuterLoop]
public static void SecurityModeNone_Echo_RoundTrips_String()
{
string testString = "Hello";
ChannelFactory<IWcfService> factory = null;
IWcfService serviceProxy = null;

try
{
// *** SETUP *** \\
UnixDomainSocketBinding binding = new UnixDomainSocketBinding(SecurityMode.None);
factory = new ChannelFactory<IWcfService>(binding, new EndpointAddress(Endpoints.Tcp_NoSecurity_Address));
serviceProxy = factory.CreateChannel();

// *** EXECUTE *** \\
string result = serviceProxy.Echo(testString);

// *** VALIDATE *** \\
Assert.Equal(testString, result);

// *** CLEANUP *** \\
((ICommunicationObject)serviceProxy).Close();
factory.Close();
}
finally
{
// *** ENSURE CLEANUP *** \\
ScenarioTestHelpers.CloseCommunicationObjects((ICommunicationObject)serviceProxy, factory);
}
}
}
22 changes: 11 additions & 11 deletions src/System.ServiceModel.UnixDomainSocket/src/Resources/strings.resx
Original file line number Diff line number Diff line change
Expand Up @@ -138,28 +138,28 @@
<data name="ChannelTypeNotSupported" xml:space="preserve">
<value>The specified channel type {0} is not supported by this channel manager.</value>
</data>
<data name="TcpConnectError" xml:space="preserve">
<value>Could not connect to {0}. TCP error code {1}: {2}. </value>
<data name="UDSConnectError" xml:space="preserve">
<value>Could not connect to {0}. UDS error code {1}: {2}. </value>
</data>
<data name="TcpConnectErrorWithTimeSpan" xml:space="preserve">
<value>Could not connect to {0}. The connection attempt lasted for a time span of {3}. TCP error code {1}: {2}. </value>
<data name="UDSConnectErrorWithTimeSpan" xml:space="preserve">
<value>Could not connect to {0}. The connection attempt lasted for a time span of {3}. UDS error code {1}: {2}. </value>
</data>
<data name="TcpTransferError" xml:space="preserve">
<value>A TCP error ({0}: {1}) occurred while transmitting data.</value>
<data name="UDSTransferError" xml:space="preserve">
<value>A UDS error ({0}: {1}) occurred while transmitting data.</value>
</data>
<data name="TcpLocalConnectionAborted" xml:space="preserve">
<data name="UDSLocalConnectionAborted" xml:space="preserve">
<value>The socket connection was aborted by your local machine. This could be caused by a channel Abort(), or a transmission error from another thread using this socket.</value>
</data>
<data name="TcpConnectionResetError" xml:space="preserve">
<data name="UDSConnectionResetError" xml:space="preserve">
<value>The socket connection was aborted. This could be caused by an error processing your message or a receive timeout being exceeded by the remote host, or an underlying network resource issue. Local socket timeout was '{0}'.</value>
</data>
<data name="TcpConnectionTimedOut" xml:space="preserve">
<data name="UDSConnectionTimedOut" xml:space="preserve">
<value>The socket transfer timed out after {0}. You have exceeded the timeout set on your binding. The time allotted to this operation may have been a portion of a longer timeout.</value>
</data>
<data name="SocketConnectionDisposed" xml:space="preserve">
<value>The socket connection has been disposed.</value>
</data>
<data name="TcpConnectNoBufs" xml:space="preserve">
<data name="UDSConnectNoBufs" xml:space="preserve">
<value>Insufficient winsock resources available to complete socket connection initiation.</value>
</data>
<data name="InsufficentMemory" xml:space="preserve">
Expand All @@ -171,7 +171,7 @@
<data name="DnsResolveFailed" xml:space="preserve">
<value>No DNS entries exist for host {0}.</value>
</data>
<data name="TcpConnectingToViaTimedOut" xml:space="preserve">
<data name="UDSConnectingToViaTimedOut" xml:space="preserve">
<value>Connecting to via {0} timed out after {1}. Connection attempts were made to {2} of {3} available addresses ({4}). Check the RemoteAddress of your channel and verify that the DNS records for this endpoint correspond to valid IP Addresses. The time allotted to this operation may have been a portion of a longer timeout.</value>
</data>
<data name="NoIPEndpointsFoundForHost" xml:space="preserve">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,49 +82,49 @@
<target state="translated">Připojení soketu bylo zrušeno.</target>
<note />
</trans-unit>
<trans-unit id="TcpConnectError">
<source>Could not connect to {0}. TCP error code {1}: {2}. </source>
<target state="translated">Nelze připojit k {0}. Kód chyby TCP {1}: {2}. </target>
<trans-unit id="TransferModeNotSupported">
<source>Transfer mode {0} is not supported by {1}.</source>
<target state="translated">{1} nepodporuje režim přenosu {0}.</target>
<note />
</trans-unit>
<trans-unit id="UDSConnectError">
<source>Could not connect to {0}. UDS error code {1}: {2}. </source>
<target state="new">Could not connect to {0}. UDS error code {1}: {2}. </target>
<note />
</trans-unit>
<trans-unit id="TcpConnectErrorWithTimeSpan">
<source>Could not connect to {0}. The connection attempt lasted for a time span of {3}. TCP error code {1}: {2}. </source>
<target state="translated">Nelze připojit k {0}. Pokus o připojení trval po časové období {3}. Kód chyby TCP {1}: {2}. </target>
<trans-unit id="UDSConnectErrorWithTimeSpan">
<source>Could not connect to {0}. The connection attempt lasted for a time span of {3}. UDS error code {1}: {2}. </source>
<target state="new">Could not connect to {0}. The connection attempt lasted for a time span of {3}. UDS error code {1}: {2}. </target>
<note />
</trans-unit>
<trans-unit id="TcpConnectNoBufs">
<trans-unit id="UDSConnectNoBufs">
<source>Insufficient winsock resources available to complete socket connection initiation.</source>
<target state="translated">Nejsou k dispozici dostatečné prostředky rozhraní winsock pro dokončení inicializace připojení.</target>
<target state="new">Insufficient winsock resources available to complete socket connection initiation.</target>
<note />
</trans-unit>
<trans-unit id="TcpConnectingToViaTimedOut">
<trans-unit id="UDSConnectingToViaTimedOut">
<source>Connecting to via {0} timed out after {1}. Connection attempts were made to {2} of {3} available addresses ({4}). Check the RemoteAddress of your channel and verify that the DNS records for this endpoint correspond to valid IP Addresses. The time allotted to this operation may have been a portion of a longer timeout.</source>
<target state="translated">Časový limit připojení přes {0} vypršel po {1}. Pokus o připojení byl proveden u {2} z {3} dostupných adres ({4}). Zkontrolujte adresu RemoteAddress kanálu a ověřte, jestli záznamy DNS pro tento koncový bod odpovídají platným IP adresám. Čas přidělený této operaci byl pravděpodobně částí delšího časového limitu.</target>
<target state="new">Connecting to via {0} timed out after {1}. Connection attempts were made to {2} of {3} available addresses ({4}). Check the RemoteAddress of your channel and verify that the DNS records for this endpoint correspond to valid IP Addresses. The time allotted to this operation may have been a portion of a longer timeout.</target>
<note />
</trans-unit>
<trans-unit id="TcpConnectionResetError">
<trans-unit id="UDSConnectionResetError">
<source>The socket connection was aborted. This could be caused by an error processing your message or a receive timeout being exceeded by the remote host, or an underlying network resource issue. Local socket timeout was '{0}'.</source>
<target state="translated">Připojení k soketu bylo přerušeno. Může to být způsobeno chybou při zpracování zprávy nebo překročením časového limitu příjmu vzdáleným hostitelem nebo problémem se síťovými prostředky. Časový limit místního soketu byl {0}.</target>
<target state="new">The socket connection was aborted. This could be caused by an error processing your message or a receive timeout being exceeded by the remote host, or an underlying network resource issue. Local socket timeout was '{0}'.</target>
<note />
</trans-unit>
<trans-unit id="TcpConnectionTimedOut">
<trans-unit id="UDSConnectionTimedOut">
<source>The socket transfer timed out after {0}. You have exceeded the timeout set on your binding. The time allotted to this operation may have been a portion of a longer timeout.</source>
<target state="translated">Vypršel časový limit přenosu soketu po {0}. Překročili jste časový limit nastavený na vazbě. Čas přidělený této operaci byl pravděpodobně částí delšího časového limitu.</target>
<target state="new">The socket transfer timed out after {0}. You have exceeded the timeout set on your binding. The time allotted to this operation may have been a portion of a longer timeout.</target>
<note />
</trans-unit>
<trans-unit id="TcpLocalConnectionAborted">
<trans-unit id="UDSLocalConnectionAborted">
<source>The socket connection was aborted by your local machine. This could be caused by a channel Abort(), or a transmission error from another thread using this socket.</source>
<target state="translated">Připojení soketu bylo přerušeno místním počítačem. Může to být způsobeno funkcí Abort() kanálu nebo chybou ve vysílání z jiného vlákna používajícího tento soket.</target>
<target state="new">The socket connection was aborted by your local machine. This could be caused by a channel Abort(), or a transmission error from another thread using this socket.</target>
<note />
</trans-unit>
<trans-unit id="TcpTransferError">
<source>A TCP error ({0}: {1}) occurred while transmitting data.</source>
<target state="translated">Při vysílání dat došlo k chybě TCP ({0}: {1}).</target>
<note />
</trans-unit>
<trans-unit id="TransferModeNotSupported">
<source>Transfer mode {0} is not supported by {1}.</source>
<target state="translated">{1} nepodporuje režim přenosu {0}.</target>
<trans-unit id="UDSTransferError">
<source>A UDS error ({0}: {1}) occurred while transmitting data.</source>
<target state="new">A UDS error ({0}: {1}) occurred while transmitting data.</target>
<note />
</trans-unit>
<trans-unit id="UnableToResolveHost">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,49 +82,49 @@
<target state="translated">Die Socketverbindung wurde verworfen.</target>
<note />
</trans-unit>
<trans-unit id="TcpConnectError">
<source>Could not connect to {0}. TCP error code {1}: {2}. </source>
<target state="translated">Es konnte keine Verbindung mit {0} hergestellt werden. TCP-Fehlercode {1}: {2}. </target>
<trans-unit id="TransferModeNotSupported">
<source>Transfer mode {0} is not supported by {1}.</source>
<target state="translated">Der Übertragungsmodus {0} wird von {1} nicht unterstützt.</target>
<note />
</trans-unit>
<trans-unit id="UDSConnectError">
<source>Could not connect to {0}. UDS error code {1}: {2}. </source>
<target state="new">Could not connect to {0}. UDS error code {1}: {2}. </target>
<note />
</trans-unit>
<trans-unit id="TcpConnectErrorWithTimeSpan">
<source>Could not connect to {0}. The connection attempt lasted for a time span of {3}. TCP error code {1}: {2}. </source>
<target state="translated">Es konnte keine Verbindung mit {0} hergestellt werden. Der Verbindungsversuch hat für einen Zeitraum von {3} angedauert. TCP-Fehlercode {1}: {2}. </target>
<trans-unit id="UDSConnectErrorWithTimeSpan">
<source>Could not connect to {0}. The connection attempt lasted for a time span of {3}. UDS error code {1}: {2}. </source>
<target state="new">Could not connect to {0}. The connection attempt lasted for a time span of {3}. UDS error code {1}: {2}. </target>
<note />
</trans-unit>
<trans-unit id="TcpConnectNoBufs">
<trans-unit id="UDSConnectNoBufs">
<source>Insufficient winsock resources available to complete socket connection initiation.</source>
<target state="translated">Es sind nicht ausreichend Winsock-Ressourcen verfügbar, um die Initiierung der Socketverbindung abzuschließen.</target>
<target state="new">Insufficient winsock resources available to complete socket connection initiation.</target>
<note />
</trans-unit>
<trans-unit id="TcpConnectingToViaTimedOut">
<trans-unit id="UDSConnectingToViaTimedOut">
<source>Connecting to via {0} timed out after {1}. Connection attempts were made to {2} of {3} available addresses ({4}). Check the RemoteAddress of your channel and verify that the DNS records for this endpoint correspond to valid IP Addresses. The time allotted to this operation may have been a portion of a longer timeout.</source>
<target state="translated">Beim Herstellen einer Verbindung mit der Umleitung {0} ist nach {1} ein Timeout aufgetreten. Es wurden Verbindungsversuche für {2} von {3} verfügbaren Adressen unternommen ({4}). Überprüfen Sie die RemoteAddress des Kanals, und stellen Sie sicher, dass die DNS-Einträge für diesen Endpunkt gültigen IP-Adressen entsprechen. Der für diesen Vorgang zugewiesene Zeitraum war möglicherweise ein Teil eines längeren Zeitlimits.</target>
<target state="new">Connecting to via {0} timed out after {1}. Connection attempts were made to {2} of {3} available addresses ({4}). Check the RemoteAddress of your channel and verify that the DNS records for this endpoint correspond to valid IP Addresses. The time allotted to this operation may have been a portion of a longer timeout.</target>
<note />
</trans-unit>
<trans-unit id="TcpConnectionResetError">
<trans-unit id="UDSConnectionResetError">
<source>The socket connection was aborted. This could be caused by an error processing your message or a receive timeout being exceeded by the remote host, or an underlying network resource issue. Local socket timeout was '{0}'.</source>
<target state="translated">Die Socketverbindung wurde abgebrochen. Dies kann auf einen Fehler beim Verarbeiten der Nachricht, eine Überschreitung des Empfangszeitlimits durch den Remotehost oder ein Problem mit der zugrunde liegenden Netzwerkressource zurückzuführen sein. Das lokale Socketzeitlimit war "{0}".</target>
<target state="new">The socket connection was aborted. This could be caused by an error processing your message or a receive timeout being exceeded by the remote host, or an underlying network resource issue. Local socket timeout was '{0}'.</target>
<note />
</trans-unit>
<trans-unit id="TcpConnectionTimedOut">
<trans-unit id="UDSConnectionTimedOut">
<source>The socket transfer timed out after {0}. You have exceeded the timeout set on your binding. The time allotted to this operation may have been a portion of a longer timeout.</source>
<target state="translated">Bei der Socketübertragung ist nach {0} ein Timeout aufgetreten. Das für die Bindung festgelegte Zeitlimit wurde überschritten. Der für diesen Vorgang zugewiesene Zeitraum war möglicherweise ein Teil eines längeren Zeitlimits.</target>
<target state="new">The socket transfer timed out after {0}. You have exceeded the timeout set on your binding. The time allotted to this operation may have been a portion of a longer timeout.</target>
<note />
</trans-unit>
<trans-unit id="TcpLocalConnectionAborted">
<trans-unit id="UDSLocalConnectionAborted">
<source>The socket connection was aborted by your local machine. This could be caused by a channel Abort(), or a transmission error from another thread using this socket.</source>
<target state="translated">Die Socketverbindung wurde vom lokalen Computer abgebrochen. Dies wurde möglicherweise verursacht durch einen Abort()-Vorgang für den Kanal oder einen Übertragungsfehler eines anderen Threads, der diesen Socket verwendet.</target>
<target state="new">The socket connection was aborted by your local machine. This could be caused by a channel Abort(), or a transmission error from another thread using this socket.</target>
<note />
</trans-unit>
<trans-unit id="TcpTransferError">
<source>A TCP error ({0}: {1}) occurred while transmitting data.</source>
<target state="translated">Beim Übertragen von Daten ist ein TCP-Fehler ({0}: {1}) aufgetreten.</target>
<note />
</trans-unit>
<trans-unit id="TransferModeNotSupported">
<source>Transfer mode {0} is not supported by {1}.</source>
<target state="translated">Der Übertragungsmodus {0} wird von {1} nicht unterstützt.</target>
<trans-unit id="UDSTransferError">
<source>A UDS error ({0}: {1}) occurred while transmitting data.</source>
<target state="new">A UDS error ({0}: {1}) occurred while transmitting data.</target>
<note />
</trans-unit>
<trans-unit id="UnableToResolveHost">
Expand Down
Loading

0 comments on commit d3ba5c9

Please sign in to comment.