Skip to content

Commit

Permalink
Fix | Addressing documentation issues along with spelling errors (#2889)
Browse files Browse the repository at this point in the history
  • Loading branch information
Javad Rahnama authored Sep 27, 2024
1 parent 6064d02 commit 4806059
Show file tree
Hide file tree
Showing 36 changed files with 79 additions and 79 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -1254,7 +1254,7 @@ This update brings the below changes over the previous release:
- Improved performance of Managed SNI by enhancing utilization of resources [#173](https://github.com/dotnet/SqlClient/pull/173) - Ported [dotnet/corefx#35363](https://github.com/dotnet/corefx/pull/35363) and [dotnet/corefx#40732](https://github.com/dotnet/corefx/pull/40732)
- Improved performance of Managed SNI RPC Parameter Usage [#209](https://github.com/dotnet/SqlClient/pull/209) - Ported [dotnet/corefx#34049](https://github.com/dotnet/corefx/pull/34049)
- Changed enclave key map to be lazy initialized [#372](https://github.com/dotnet/SqlClient/pull/372)
- Changed `Recieve()` and `ReceiveAsync()` implementation to receive null packets on failure [#350](https://github.com/dotnet/SqlClient/pull/350)
- Changed `Receive()` and `ReceiveAsync()` implementation to receive null packets on failure [#350](https://github.com/dotnet/SqlClient/pull/350)
- Changed `EnclaveProviderBase` caching implementation to support Async Scenarios _(Introduces breaking changes)_ [#346](https://github.com/dotnet/SqlClient/pull/346)

## [Stable Release 1.1.0] - 2019-11-20
Expand Down
4 changes: 2 additions & 2 deletions doc/samples/SqlBulkCopy_ColumnMapping.cs
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@ static void Main()
new SqlBulkCopyColumnMapping("Name", "ProdName");
bulkCopy.ColumnMappings.Add(mapName);

SqlBulkCopyColumnMapping mapMumber =
SqlBulkCopyColumnMapping mapNumber =
new SqlBulkCopyColumnMapping("ProductNumber", "ProdNum");
bulkCopy.ColumnMappings.Add(mapMumber);
bulkCopy.ColumnMappings.Add(mapNumber);

// Write from the source to the destination.
try
Expand Down
2 changes: 1 addition & 1 deletion doc/samples/SqlBulkCopy_ColumnMappingRemoveAt.cs
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ static void Main()
bulkCopy.DestinationTableName = "dbo.BulkCopyDemoOrderDetail";

// Rather than clearing mappings that are not necessary
// for the next bulk copyo peration, the unneeded mappings
// for the next bulk copy operation, the unneeded mappings
// are removed with the RemoveAt method.
bulkCopy.ColumnMappings.RemoveAt(2);
bulkCopy.ColumnMappings.RemoveAt(1);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,10 @@
</CopyTo2>
<IndexOf1>
<summary>
Searches for the specified <see cref="T:Microsoft.Data.SqlClient.SqlBatchCommand" /> within the <see cref="T:Microsoft.Data.SqlClient.SqlBatchCommandCollection" /> and returns the zero-based index of the first occurence within the entire <see cref="T:Microsoft.Data.SqlClient.SqlBatchCommandCollection" />.
Searches for the specified <see cref="T:Microsoft.Data.SqlClient.SqlBatchCommand" /> within the <see cref="T:Microsoft.Data.SqlClient.SqlBatchCommandCollection" /> and returns the zero-based index of the first occurrence within the entire <see cref="T:Microsoft.Data.SqlClient.SqlBatchCommandCollection" />.
</summary>
<returns>
Returns the zero-based index of the first occurence within the entire <see cref="T:Microsoft.Data.SqlClient.SqlBatchCommandCollection" />.
Returns the zero-based index of the first occurrence within the entire <see cref="T:Microsoft.Data.SqlClient.SqlBatchCommandCollection" />.
</returns>
</IndexOf1>
<IndexOf2>
Expand Down Expand Up @@ -87,7 +87,7 @@
</Insert2>
<Remove1>
<summary>
Removes the first occurence of a specific <see cref="T:Microsoft.Data.SqlClient.SqlBatchCommand" /> object from the collection.
Removes the first occurrence of a specific <see cref="T:Microsoft.Data.SqlClient.SqlBatchCommand" /> object from the collection.
</summary>
<returns>
Returns <see langword="true" /> if an item is successfully removed. Returns false if an item could not be removed or no item was not found.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,9 +74,9 @@
new SqlBulkCopyColumnMapping("Name", "ProdName");
bulkCopy.ColumnMappings.Add(mapName);

SqlBulkCopyColumnMapping mapMumber =
SqlBulkCopyColumnMapping mapNumber =
new SqlBulkCopyColumnMapping("ProductNumber", "ProdNum");
bulkCopy.ColumnMappings.Add(mapMumber);
bulkCopy.ColumnMappings.Add(mapNumber);

// Write from the source to the destination.
try
Expand Down Expand Up @@ -180,9 +180,9 @@
new SqlBulkCopyColumnMapping("Name", "ProdName");
bulkCopy.ColumnMappings.Add(mapName);

SqlBulkCopyColumnMapping mapMumber =
SqlBulkCopyColumnMapping mapNumber =
new SqlBulkCopyColumnMapping("ProductNumber", "ProdNum");
bulkCopy.ColumnMappings.Add(mapMumber);
bulkCopy.ColumnMappings.Add(mapNumber);

// Write from the source to the destination.
try
Expand Down Expand Up @@ -630,9 +630,9 @@
new SqlBulkCopyColumnMapping("Name", "ProdName");
bulkCopy.ColumnMappings.Add(mapName);

SqlBulkCopyColumnMapping mapMumber =
SqlBulkCopyColumnMapping mapNumber =
new SqlBulkCopyColumnMapping("ProductNumber", "ProdNum");
bulkCopy.ColumnMappings.Add(mapMumber);
bulkCopy.ColumnMappings.Add(mapNumber);

// Write from the source to the destination.
try
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -182,9 +182,9 @@
new SqlBulkCopyColumnMapping("Name", "ProdName");
bulkCopy.ColumnMappings.Add(mapName);

SqlBulkCopyColumnMapping mapMumber =
SqlBulkCopyColumnMapping mapNumber =
new SqlBulkCopyColumnMapping("ProductNumber", "ProdNum");
bulkCopy.ColumnMappings.Add(mapMumber);
bulkCopy.ColumnMappings.Add(mapNumber);

// Write from the source to the destination.
try
Expand Down Expand Up @@ -1252,7 +1252,7 @@
bulkCopy.DestinationTableName = "dbo.BulkCopyDemoOrderDetail";

// Rather than clearing mappings that are not necessary
// for the next bulk copyo peration, the unneeded mappings
// for the next bulk copy operation, the unneeded mappings
// are removed with the RemoveAt method.
bulkCopy.ColumnMappings.RemoveAt(2);
bulkCopy.ColumnMappings.RemoveAt(1);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -488,7 +488,7 @@
<members name="SqlClientTransactionRollbackError">
<SqlClientTransactionRollbackError>
<summary>
Contains diagnostic information emitted after a transaction roll back failes with an exception.
Contains diagnostic information emitted after a transaction roll back fails with an exception.
</summary>
</SqlClientTransactionRollbackError>
<Name>
Expand Down
6 changes: 3 additions & 3 deletions doc/snippets/Microsoft.Data.SqlClient/SqlCommand.xml
Original file line number Diff line number Diff line change
Expand Up @@ -866,7 +866,7 @@
The <see cref="T:Microsoft.Data.SqlClient.SqlConnection" /> closed or dropped during a streaming operation. For more information about streaming, see <see href='/sql/connect/ado-net/sqlclient-streaming-support'>SqlClient Streaming Support</see>.
</item>
<item>
<see cref="P:Microssoft.Data.SqlClient.SqlCommand.EnableOptimizedParameterBinding" /> is set to true and a parameter with direction Output or InputOutput has been added to the <see cref="P:Microsoft.Data.SqlClient.SqlCommand.Parameters" /> collection.
<see cref="P:Microsoft.Data.SqlClient.SqlCommand.EnableOptimizedParameterBinding" /> is set to true and a parameter with direction Output or InputOutput has been added to the <see cref="P:Microsoft.Data.SqlClient.SqlCommand.Parameters" /> collection.
</item>
</list>
</exception>
Expand Down Expand Up @@ -1380,7 +1380,7 @@
The <see cref="T:Microsoft.Data.SqlClient.SqlConnection" /> closed or dropped during a streaming operation. For more information about streaming, see <see href='/sql/connect/ado-net/sqlclient-streaming-support'>SqlClient Streaming Support</see>.
</item>
<item>
<see cref="P:Microssoft.Data.SqlClient.SqlCommand.EnableOptimizedParameterBinding" /> is set to true and a parameter with direction Output or InputOutput has been added to the <see cref="P:Microsoft.Data.SqlClient.SqlCommand.Parameters" /> collection.
<see cref="P:Microsoft.Data.SqlClient.SqlCommand.EnableOptimizedParameterBinding" /> is set to true and a parameter with direction Output or InputOutput has been added to the <see cref="P:Microsoft.Data.SqlClient.SqlCommand.Parameters" /> collection.
</item>
</list>
</exception>
Expand Down Expand Up @@ -2723,7 +2723,7 @@
Gets or sets a value indicating whether the command object should optimize parameter performance by disabling Output and InputOutput directions when submitting the command to the SQL Server. <br /> This option is only used when the <see cref="P:Microsoft.Data.SqlClient.SqlCommand.CommandType" /> is <see cref="F:System.Data.CommandType.Text"/> otherwise it is ignored.
</summary>
<value>
A value indicating whether the command object should optimize parameter performance by disabling Output and InputOuput parameter directions when submitting the command to the SQL Server. The default is <see langword="false" />.
A value indicating whether the command object should optimize parameter performance by disabling Output and InputOutput parameter directions when submitting the command to the SQL Server. The default is <see langword="false" />.
</value>
<remarks>
<para>
Expand Down
2 changes: 1 addition & 1 deletion release-notes/2.0/2.0.0-preview1.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ This update brings the below changes over the previous release:
- Improved performance of Managed SNI by enhancing utilization of resources [#173](https://github.com/dotnet/SqlClient/pull/173) - Ported [dotnet/corefx#35363](https://github.com/dotnet/corefx/pull/35363) and [dotnet/corefx#40732](https://github.com/dotnet/corefx/pull/40732)
- Improved performance of Managed SNI RPC Parameter Usage [#209](https://github.com/dotnet/SqlClient/pull/209) - Ported [dotnet/corefx#34049](https://github.com/dotnet/corefx/pull/34049)
- Changed enclave key map to be lazy initialized [#372](https://github.com/dotnet/SqlClient/pull/372)
- Changed `Recieve()` and `ReceiveAsync()` implementation to receive null packets on failure [#350](https://github.com/dotnet/SqlClient/pull/350)
- Changed `Receive()` and `ReceiveAsync()` implementation to receive null packets on failure [#350](https://github.com/dotnet/SqlClient/pull/350)
- Changed `EnclaveProviderBase` caching implementation to support Async Scenarios _(Introduces breaking changes)_ [#346](https://github.com/dotnet/SqlClient/pull/346)

### Breaking Changes
Expand Down
2 changes: 1 addition & 1 deletion release-notes/2.0/2.0.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ All changes in Microsoft.Data.SqlClient v2.0 over v1.1:
- Improved performance of Managed SNI by enhancing utilization of resources [#173](https://github.com/dotnet/SqlClient/pull/173) - Ported [dotnet/corefx#35363](https://github.com/dotnet/corefx/pull/35363) and [dotnet/corefx#40732](https://github.com/dotnet/corefx/pull/40732)
- Improved performance of Managed SNI RPC Parameter Usage [#209](https://github.com/dotnet/SqlClient/pull/209) - Ported [dotnet/corefx#34049](https://github.com/dotnet/corefx/pull/34049)
- Changed enclave key map to be lazy initialized [#372](https://github.com/dotnet/SqlClient/pull/372)
- Changed `Recieve()` and `ReceiveAsync()` implementation to receive null packets on failure [#350](https://github.com/dotnet/SqlClient/pull/350)
- Changed `Receive()` and `ReceiveAsync()` implementation to receive null packets on failure [#350](https://github.com/dotnet/SqlClient/pull/350)
- Changed `EnclaveProviderBase` caching implementation to support Async Scenarios _(Introduces breaking changes)_ [#346](https://github.com/dotnet/SqlClient/pull/346)
- Updated all driver assemblies to be CLS Compliant [#396](https://github.com/dotnet/SqlClient/pull/396)
- Updated Bulk Copy error messages to also include Column, Row and non-encrypted Data information [#437](https://github.com/dotnet/SqlClient/pull/437)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ public SNIPacket()
public int DataLeft => (_dataLength - _dataOffset);

/// <summary>
/// Indicates that the packet should be sent out of band bypassing the normal send-recieve lock
/// Indicates that the packet should be sent out of band bypassing the normal send-receive lock
/// </summary>
public bool IsOutOfBand { get; set; }

Expand Down Expand Up @@ -181,7 +181,7 @@ public void AppendData(byte[] data, int size)
}

/// <summary>
/// Read data from the packet into the buffer at dataOffset for zize and then remove that data from the packet
/// Read data from the packet into the buffer at dataOffset for size and then remove that data from the packet
/// </summary>
/// <param name="buffer">Buffer</param>
/// <param name="dataOffset">Data offset to write data at</param>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -704,7 +704,7 @@ public override uint Send(SNIPacket packet)
try
{
// is the packet is marked out out-of-band (attention packets only) it must be
// sent immediately even if a send of recieve operation is already in progress
// sent immediately even if a send or receive operation is already in progress
// because out of band packets are used to cancel ongoing operations
// so try to take the lock if possible but continue even if it can't be taken
if (packet.IsOutOfBand)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ internal sealed class SSRP
{
private const char SemicolonSeparator = ';';
private const int SqlServerBrowserPort = 1434; //port SQL Server Browser
private const int RecieveMAXTimeoutsForCLNT_BCAST_EX = 15000; //Default max time for response wait
private const int RecieveTimeoutsForCLNT_BCAST_EX = 1000; //subsequent wait time for response after intial wait
private const int ReceiveMAXTimeoutsForCLNT_BCAST_EX = 15000; //Default max time for response wait
private const int ReceiveTimeoutsForCLNT_BCAST_EX = 1000; //subsequent wait time for response after intial wait
private const int ServerResponseHeaderSizeForCLNT_BCAST_EX = 3;//(SVR_RESP + RESP_SIZE) https://docs.microsoft.com/en-us/openspecs/windows_protocols/mc-sqlr/2e1560c9-5097-4023-9f5e-72b9ff1ec3b1
private const int ValidResponseSizeForCLNT_BCAST_EX = 4096; //valid reponse size should be less than 4096
private const int FirstTimeoutForCLNT_BCAST_EX = 5000;//wait for first response for 5 seconds
Expand Down Expand Up @@ -383,11 +383,11 @@ private static SsrpResult SendUDPRequest(IPEndPoint endPoint, byte[] requestPack
}

/// <summary>
/// Sends request to server, and recieves response from server (SQLBrowser) on port 1434 by UDP
/// Sends request to server, and receives response from server (SQLBrowser) on port 1434 by UDP
/// Request (https://docs.microsoft.com/en-us/openspecs/windows_protocols/mc-sqlr/a3035afa-c268-4699-b8fd-4f351e5c8e9e)
/// Response (https://docs.microsoft.com/en-us/openspecs/windows_protocols/mc-sqlr/2e1560c9-5097-4023-9f5e-72b9ff1ec3b1)
/// </summary>
/// <returns>string constaning list of SVR_RESP(just RESP_DATA)</returns>
/// <returns>string containing list of SVR_RESP(just RESP_DATA)</returns>
internal static string SendBroadcastUDPRequest()
{
StringBuilder response = new StringBuilder();
Expand All @@ -407,9 +407,9 @@ internal static string SendBroadcastUDPRequest()
sw.Start();
try
{
while ((receiveTask = clientListener.ReceiveAsync()).Wait(currentTimeOut) && sw.ElapsedMilliseconds <= RecieveMAXTimeoutsForCLNT_BCAST_EX && receiveTask != null)
while ((receiveTask = clientListener.ReceiveAsync()).Wait(currentTimeOut) && sw.ElapsedMilliseconds <= ReceiveMAXTimeoutsForCLNT_BCAST_EX && receiveTask != null)
{
currentTimeOut = RecieveTimeoutsForCLNT_BCAST_EX;
currentTimeOut = ReceiveTimeoutsForCLNT_BCAST_EX;
SqlClientEventSource.Log.TrySNITraceEvent(nameof(SSRP), EventType.INFO, "Received instnace info from UDP Client.");
if (receiveTask.Result.Buffer.Length < ValidResponseSizeForCLNT_BCAST_EX) //discard invalid response
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ public override long Position
public override bool CanWrite => _stream.CanWrite;

/// <summary>
/// Check if stream can be seeked
/// Check if stream can seek
/// </summary>
public override bool CanSeek => false;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4566,7 +4566,7 @@ private void ReadDescribeEncryptionParameterResults(SqlDataReader ds, ReadOnlyDi
Debug.Assert(rpc != null, "rpc should not be null here.");

int userParamCount = rpc.userParams?.Count ?? 0;
int recievedMetadataCount = 0;
int receivedMetadataCount = 0;
if (!enclaveMetadataExists || ds.NextResult())
{

Expand All @@ -4591,7 +4591,7 @@ private void ReadDescribeEncryptionParameterResults(SqlDataReader ds, ReadOnlyDi
{
Debug.Assert(sqlParameter.CipherMetadata == null, "param.CipherMetadata should be null.");
sqlParameter.HasReceivedMetadata = true;
recievedMetadataCount += 1;
receivedMetadataCount += 1;
// Found the param, setup the encryption info.
byte columnEncryptionType = ds.GetByte((int)DescribeParameterEncryptionResultSet2.ColumnEncryptionType);
if ((byte)SqlClientEncryptionType.PlainText != columnEncryptionType)
Expand Down Expand Up @@ -4633,7 +4633,7 @@ private void ReadDescribeEncryptionParameterResults(SqlDataReader ds, ReadOnlyDi
// When the RPC object gets reused, the parameter array has more parameters that the valid params for the command.
// Null is used to indicate the end of the valid part of the array. Refer to GetRPCObject().

if (recievedMetadataCount != userParamCount)
if (receivedMetadataCount != userParamCount)
{
for (int index = 0; index < userParamCount; index++)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1916,7 +1916,7 @@ private void AttemptOneLogin(
TimeoutTimer timeout,
bool withFailover = false)
{
SqlClientEventSource.Log.TryAdvancedTraceEvent("<sc.SqlInternalConnectionTds.AttemptOneLogin|ADV> {0}, timout={1}[msec], server={2}", ObjectID, timeout.MillisecondsRemaining, serverInfo.ExtendedServerName);
SqlClientEventSource.Log.TryAdvancedTraceEvent("<sc.SqlInternalConnectionTds.AttemptOneLogin|ADV> {0}, timeout={1}[msec], server={2}", ObjectID, timeout.MillisecondsRemaining, serverInfo.ExtendedServerName);
RoutingInfo = null; // forget routing information

_parser._physicalStateObj.SniContext = SniContext.Snix_Connect;
Expand Down
Loading

0 comments on commit 4806059

Please sign in to comment.