Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add partial packet detection and fixup #2714

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

Wraith2
Copy link
Contributor

@Wraith2 Wraith2 commented Jul 24, 2024

Split out from #2608 per discussion detailed in #2608 (comment)

Adds packet multiplexer and covering tests.

@Wraith2
Copy link
Contributor Author

Wraith2 commented Jul 25, 2024

I've added comments to the Packet class as requested. The CI was green apart from some ubuntu legs which timed out, many other ubuntu legs succeeded so I don't see any direct inference on from that.

Ready for review @David-Engel @saurabh500 @cheenamalhotra

@Wraith2 Wraith2 marked this pull request as ready for review July 25, 2024 18:20
@saurabh500 saurabh500 self-requested a review July 29, 2024 19:29
@saurabh500
Copy link
Contributor

@Wraith2 We are reviewing this and hope to get faster traction towards EOW.
Wanted to give an update, instead of maintaining radio silence.

cc @VladimirReshetnikov

@cheenamalhotra
Copy link
Member

cheenamalhotra commented Aug 6, 2024

Pasting test failure for reference:

    Failed Microsoft.Data.SqlClient.ManualTesting.Tests.AsyncCancelledConnectionsTest.CancelAsyncConnections [2 m 38 s]
EXEC : error Message:  [/mnt/vss/_work/1/s/build.proj]
     Assert.Empty() Failure: Collection was not empty
  Collection: ["Microsoft.Data.SqlClient.SqlException (0x80131904)"···]
    Stack Trace:
       at Microsoft.Data.SqlClient.ManualTesting.Tests.AsyncCancelledConnectionsTest.RunCancelAsyncConnections(SqlConnectionStringBuilder connectionStringBuilder) in /_/src/Microsoft.Data.SqlClient/tests/ManualTests/SQL/AsyncTest/AsyncCancelledConnectionsTest.cs:line 66
     at Microsoft.Data.SqlClient.ManualTesting.Tests.AsyncCancelledConnectionsTest.CancelAsyncConnections() in /_/src/Microsoft.Data.SqlClient/tests/ManualTests/SQL/AsyncTest/AsyncCancelledConnectionsTest.cs:line 31
     at System.RuntimeMethodHandle.InvokeMethod(Object target, Void** arguments, Signature sig, Boolean isConstructor)
     at System.Reflection.MethodBaseInvoker.InvokeWithNoArgs(Object obj, BindingFlags invokeAttr)

    Standard Output Messages:
   00:00:05.8665447 True Started:8 Done:0 InFlight:8 RowsRead:39 ResultRead:3 PoisonedEnded:1 nonPoisonedExceptions:0 PoisonedCleanupExceptions:0 Count:0 Found:0
   00:00:10.8624529 True Started:12 Done:0 InFlight:12 RowsRead:832 ResultRead:64 PoisonedEnded:6 nonPoisonedExceptions:6 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:00:15.8646242 True Started:17 Done:0 InFlight:17 RowsRead:2327 ResultRead:179 PoisonedEnded:11 nonPoisonedExceptions:9 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:00:20.8677772 True Started:42 Done:6 InFlight:36 RowsRead:4810 ResultRead:370 PoisonedEnded:18 nonPoisonedExceptions:14 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:00:25.8731904 True Started:71 Done:12 InFlight:59 RowsRead:9126 ResultRead:702 PoisonedEnded:30 nonPoisonedExceptions:29 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:00:30.8714979 True Started:77 Done:14 InFlight:63 RowsRead:12207 ResultRead:939 PoisonedEnded:38 nonPoisonedExceptions:36 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:00:35.0004685 True Started:86 Done:25 InFlight:61 RowsRead:17173 ResultRead:1321 PoisonedEnded:49 nonPoisonedExceptions:43 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:00:39.9987443 True Started:97 Done:64 InFlight:33 RowsRead:31798 ResultRead:2446 PoisonedEnded:64 nonPoisonedExceptions:62 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:00:44.9985663 True Started:97 Done:64 InFlight:33 RowsRead:31798 ResultRead:2446 PoisonedEnded:64 nonPoisonedExceptions:62 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:00:49.9982022 True Started:97 Done:64 InFlight:33 RowsRead:31798 ResultRead:2446 PoisonedEnded:64 nonPoisonedExceptions:62 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:00:54.9982968 True Started:97 Done:64 InFlight:33 RowsRead:31798 ResultRead:2446 PoisonedEnded:64 nonPoisonedExceptions:62 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:00:59.9996354 True Started:97 Done:64 InFlight:33 RowsRead:31798 ResultRead:2446 PoisonedEnded:64 nonPoisonedExceptions:62 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:01:04.9991460 True Started:97 Done:64 InFlight:33 RowsRead:31798 ResultRead:2446 PoisonedEnded:64 nonPoisonedExceptions:62 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:01:09.9983868 True Started:97 Done:64 InFlight:33 RowsRead:31798 ResultRead:2446 PoisonedEnded:64 nonPoisonedExceptions:62 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:01:14.9975925 True Started:97 Done:64 InFlight:33 RowsRead:31798 ResultRead:2446 PoisonedEnded:64 nonPoisonedExceptions:62 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:01:19.9977701 True Started:97 Done:64 InFlight:33 RowsRead:31798 ResultRead:2446 PoisonedEnded:64 nonPoisonedExceptions:62 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:01:25.0122289 True Started:97 Done:64 InFlight:33 RowsRead:31798 ResultRead:2446 PoisonedEnded:64 nonPoisonedExceptions:62 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:01:30.0025709 True Started:97 Done:64 InFlight:33 RowsRead:31798 ResultRead:2446 PoisonedEnded:64 nonPoisonedExceptions:62 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:01:35.0024237 True Started:98 Done:65 InFlight:33 RowsRead:32344 ResultRead:2488 PoisonedEnded:65 nonPoisonedExceptions:62 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:01:40.0025057 True Started:100 Done:98 InFlight:2 RowsRead:50297 ResultRead:3869 PoisonedEnded:98 nonPoisonedExceptions:63 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:01:45.0002633 True Started:100 Done:98 InFlight:2 RowsRead:50297 ResultRead:3869 PoisonedEnded:98 nonPoisonedExceptions:63 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:01:49.9986071 True Started:100 Done:98 InFlight:2 RowsRead:50297 ResultRead:3869 PoisonedEnded:98 nonPoisonedExceptions:63 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:01:54.9998736 True Started:100 Done:98 InFlight:2 RowsRead:50297 ResultRead:3869 PoisonedEnded:98 nonPoisonedExceptions:63 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:01:59.9957745 True Started:100 Done:98 InFlight:2 RowsRead:50297 ResultRead:3869 PoisonedEnded:98 nonPoisonedExceptions:63 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:02:04.9985369 True Started:100 Done:98 InFlight:2 RowsRead:50297 ResultRead:3869 PoisonedEnded:98 nonPoisonedExceptions:63 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:02:09.9982641 True Started:100 Done:98 InFlight:2 RowsRead:50297 ResultRead:3869 PoisonedEnded:98 nonPoisonedExceptions:63 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:02:14.9983408 True Started:100 Done:98 InFlight:2 RowsRead:50297 ResultRead:3869 PoisonedEnded:98 nonPoisonedExceptions:63 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:02:19.9988637 True Started:100 Done:98 InFlight:2 RowsRead:50297 ResultRead:3869 PoisonedEnded:98 nonPoisonedExceptions:63 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:02:25.0003251 True Started:100 Done:98 InFlight:2 RowsRead:50297 ResultRead:3869 PoisonedEnded:98 nonPoisonedExceptions:63 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:02:29.9988943 True Started:100 Done:98 InFlight:2 RowsRead:50297 ResultRead:3869 PoisonedEnded:98 nonPoisonedExceptions:63 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:02:35.0000752 True Started:100 Done:99 InFlight:1 RowsRead:50830 ResultRead:3910 PoisonedEnded:99 nonPoisonedExceptions:63 PoisonedCleanupExceptions:0 Count:1 Found:0
   00:02:38.0752114 True Started:100 Done:100 InFlight:0 RowsRead:51376 ResultRead:3952 PoisonedEnded:100 nonPoisonedExceptions:63 PoisonedCleanupExceptions:0 Count:1 Found:0
   Microsoft.Data.SqlClient.SqlException (0x80131904): A severe error occurred on the current command.  The results, if any, should be discarded.
      at Microsoft.Data.SqlClient.SqlConnection.OnError(SqlE

This test should be looked at carefully.

It failed on Ubuntu with .NET 6 and 8 , and also hung up on Windows when ran with Managed SNI, link to logs 1 link to logs 2.
In this use case, multiple parallel async read operations are being performed, which means connection isolation should be intact while cancellation occurs in between, but it doesn't seem to be happening.

@Wraith2 can you confirm if this is something you're able to repro in Windows with Managed SNI? Please make sure config file is configured to enable Managed SNI on Windows.

{
// Do nothing with callback if closed or broken and error not 0 - callback can occur
// after connection has been closed. PROBLEM IN NETLIB - DESIGN FLAW.
return;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add a Debug Assert here and check if this is taking any hit?

Copy link
Member

@cheenamalhotra cheenamalhotra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Test needs to be fixed, before reviewing any further.

@Wraith2
Copy link
Contributor Author

Wraith2 commented Aug 6, 2024

Isn't this the set of tests that @David-Engel pointed out in #2608 (comment) ? If so we discussed it at length on the teams call. I don't believe that those tests are reliable.

Setup a breakpoint or Debug.WriteLine where an exception is added to the state object and run the test. You should find that an exception is always added to the state object but that the test will usually succeed. That should not be possible, an exception if added should be thrown. The test is missing failures and if that's the case then the test is unreliable.

@Wraith2
Copy link
Contributor Author

Wraith2 commented Aug 6, 2024

When you work past the terrible code in SNITCPHandle and make the test run for long enough it settles into a steady state where it can't reach the end. There is no indication why yet.

00:05:45.3696502 True Started:97 Done:88 InFlight:9 RowsRead:241216 ResultRead:3769 PoisonedEnded:88 nonPoisonedExceptions:0 PoisonedCleanupExceptions:0 Count:0 Found:0
00:05:50.3638134 True Started:97 Done:88 InFlight:9 RowsRead:241216 ResultRead:3769 PoisonedEnded:88 nonPoisonedExceptions:0 PoisonedCleanupExceptions:0 Count:0 Found:0

those 9 in flight items just don't seem to complete but i don't know why.
This is going to need your help from MS side to identify what's going on here.

@Wraith2
Copy link
Contributor Author

Wraith2 commented Aug 6, 2024

After a few more hours investigation I know what the problem is but I have no clue what change has caused it.

In SqlDataReader when an async method is called we use a context object to contain some state and pass that context object to all the async methods that are used to implement the async read machinery. Part of this state is the TaskCompletionSource.
When running the test CancelAsyncConnections many connections are opened and then SqlCommand.Cancel is called after a brief timed wait. If the timing of the cancel operation is exact then an async operation can be in progress and between packets at the time when the cancellation is executed.
This causes the thread awaiting the async operation to wait indefinitely for a task that will never be completed. This is what causes the stuck threads. The threads as stuck so the test can never complete and it then times out.

What I don't understand is how cancel is supposed to work. I'm unable to run the tests in native sni mode because the native sni can't be initialized (can't find the sni dll). So I can't compare the managed to unmanaged implementations here. I don't believe that I have made any change that should affect cancellation. I have verified that there are no partial packets in the state objects when the async tasks get stuck.

I don't understand how async cancellation is supposed to work at all.

Add debugging and tighten the exception detection in async cancel tests.
@Wraith2
Copy link
Contributor Author

Wraith2 commented Aug 10, 2024

Can someone with CI access rerun the failed legs? the failures are random or CI resources not being available as far as i can tell.

@Wraith2
Copy link
Contributor Author

Wraith2 commented Aug 10, 2024

The current failures are interesting. They're in the test that was failing before but they new ones are only detected because i made the test more accurate.

  [xUnit.net 00:06:40.39]     Microsoft.Data.SqlClient.ManualTesting.Tests.AsyncCancelledConnectionsTest.CancelAsyncConnections [FAIL]
  [xUnit.net 00:06:40.39]       Assert.Empty() Failure: Collection was not empty
  [xUnit.net 00:06:40.39]       Collection: ["Microsoft.Data.SqlClient.SqlException (0x80131904)"···]
  [xUnit.net 00:06:40.39]       Stack Trace:
  [xUnit.net 00:06:40.39]         /_/src/Microsoft.Data.SqlClient/tests/ManualTests/SQL/AsyncTest/AsyncCancelledConnectionsTest.cs(71,0): at Microsoft.Data.SqlClient.ManualTesting.Tests.AsyncCancelledConnectionsTest.RunCancelAsyncConnections(SqlConnectionStringBuilder connectionStringBuilder)
  [xUnit.net 00:06:40.39]         /_/src/Microsoft.Data.SqlClient/tests/ManualTests/SQL/AsyncTest/AsyncCancelledConnectionsTest.cs(32,0): at Microsoft.Data.SqlClient.ManualTesting.Tests.AsyncCancelledConnectionsTest.CancelAsyncConnections()
  [xUnit.net 00:06:40.39]            at System.RuntimeMethodHandle.InvokeMethod(Object target, Void** arguments, Signature sig, Boolean isConstructor)
  [xUnit.net 00:06:40.39]            at System.Reflection.MethodBaseInvoker.InvokeWithNoArgs(Object obj, BindingFlags invokeAttr)
  [xUnit.net 00:06:40.39]       Output:
  [xUnit.net 00:06:40.39]         00:00:05.4318805 True Started:21 Done:0 InFlight:21 RowsRead:117 ResultRead:9 PoisonedEnded:4 nonPoisonedExceptions:2 PoisonedCleanupExceptions:0 Count:1 Found:0
  [xUnit.net 00:06:40.39]         00:00:10.4374767 True Started:25 Done:0 InFlight:25 RowsRead:1469 ResultRead:113 PoisonedEnded:11 nonPoisonedExceptions:9 PoisonedCleanupExceptions:0 Count:1 Found:0
  [xUnit.net 00:06:40.39]         00:00:15.4529038 True Started:31 Done:1 InFlight:30 RowsRead:4732 ResultRead:364 PoisonedEnded:14 nonPoisonedExceptions:13 PoisonedCleanupExceptions:0 Count:1 Found:0
  [xUnit.net 00:06:40.39]         00:00:20.4568918 True Started:67 Done:12 InFlight:55 RowsRead:7852 ResultRead:604 PoisonedEnded:28 nonPoisonedExceptions:21 PoisonedCleanupExceptions:0 Count:1 Found:0
  [xUnit.net 00:06:40.39]         00:00:24.9990795 True Started:91 Done:32 InFlight:59 RowsRead:19955 ResultRead:1535 PoisonedEnded:43 nonPoisonedExceptions:35 PoisonedCleanupExceptions:0 Count:1 Found:0
  [xUnit.net 00:06:40.39]         00:00:28.1341854 True Started:100 Done:100 InFlight:0 RowsRead:52273 ResultRead:4021 PoisonedEnded:100 nonPoisonedExceptions:44 PoisonedCleanupExceptions:0 Count:1 Found:0
  [xUnit.net 00:06:40.39]         Microsoft.Data.SqlClient.SqlException (0x80131904): A severe error occurred on the current command.  The results, if any, should be discarded.
  [xUnit.net 00:06:40.39]            at Microsoft.Data.SqlClient.SqlConnection.OnError(SqlE
    Failed Microsoft.Data.SqlClient.ManualTesting.Tests.AsyncCancelledConnectionsTest.CancelAsyncConnections [28 s]
EXEC : error Message:  [/mnt/vss/_work/1/s/build.proj]
     Assert.Empty() Failure: Collection was not empty

The previous version of the test accepted any exception when it was expecting a cancellation exception. It was passing on netfx with my previous changes because timeout exceptions were being thrown. I judged that accepting a timeout when we were supposed to be testing whether cancellation had occurred was not correct.

If we retained the previous version of the test then everything would have passed cleanly. In the current situation since the test completed correctly without hanging the result is equivalent to what we would have experienced in all test runs in the past, all started threads that we expected to be cancelled exited with an exception.

[edit]
I ran that single test locally in Net6 managed SNI mode using the vs "Run Until Failure" option. This runs the test up to 1000 times sequentially and stops if it fails. It completed 1000 runs successfully.

@David-Engel
Copy link
Contributor

@Wraith2 You might be banging your head against an unrelated issue in the driver. IIRC, the test was only introduced to ensure we don't regress "The MARS TDS header contained errors." issue. (The test code came from the repro.)

If you isolate your test changes and run them against main code, does it still fail? Yes, the correct exception is probably "Operation cancelled by user." where the exception is being caught. But if it's unrelated to your other changes, I would leave that part of the test as it was and file a new issue with repro code. As it is, it's unclear if and how this behavior is impacting users and I wouldn't hold up your perf improvements for it.

@Wraith2
Copy link
Contributor Author

Wraith2 commented Aug 12, 2024

There was definitely a real problem. The results differed between main and my branch. I've solved that issue now and the current state is that we're seeing a real failure because I've made the test more sensitive. I think it's probably safe to lower the sensitivity of the test again now because the new test that I've added covers the specific scenario in the multiplexer that I had missed and everything else is pass. I'll try that and see how the CI likes it.

I think the current state on this branch is that it is as stable as live. We need to have confidence that this set of changes is correct before we can merge it. It's high risk and high complexity code. Even understanding it very deeply it has taken me a week to actively debug a very important behaviour change that I missed.

@Wraith2
Copy link
Contributor Author

Wraith2 commented Aug 12, 2024

Can someone re-run the failed legs? the only failing test is something to do with event counters which I've been no-where near.

@Wraith2
Copy link
Contributor Author

Wraith2 commented Aug 12, 2024

The failing test is EventCounter_ReclaimedConnectionsCounter_Functional. It's doing something with GC specific to net6. It's failing sporadically on net6 managed sni runs but not deterministically. I can't make it fail locally to trace what might be happening.

@Wraith2
Copy link
Contributor Author

Wraith2 commented Aug 19, 2024

Any thoughts?

@David-Engel
Copy link
Contributor

David-Engel commented Aug 26, 2024

I'm not seeing the failures you mentioned in EventCounter_ReclaimedConnectionsCounter_Functional [in the CI results]. I mainly see fairly consistent failures of CancelAsyncConnections on Linux. It seems to pass on Windows managed SNI, so there might be something that is Linux/Ubuntu network specific. Can you run/debug the test against a local WSL or Docker instance?

@Wraith2
Copy link
Contributor Author

Wraith2 commented Aug 26, 2024

If i click through the failure i get to this page https://sqlclientdrivers.visualstudio.com/public/_build/results?buildId=95784&view=ms.vss-test-web.build-test-results-tab
image

The cancel tests are passing now, those failed in the previous runs but not the current ones.

@David-Engel
Copy link
Contributor

I think there is something wrong with the Tests tab. I don't usually reference it. I scroll down the summary tab to see what jobs had failures:

image

Then drill into the job and the task that failed to see the log:

image

@Wraith2
Copy link
Contributor Author

Wraith2 commented Aug 27, 2024

If it's AsyncCancelledConnectionsTest again then there isn't anything further I can do. That test is multithreaded and timing dependent. I've traced the individual packets through the entire call stack. I've run it for 1000 iterations successfully after fixing a reproducible error in it. If someone can isolate a reproducible problem from it then i'll investigate.

@David-Engel
Copy link
Contributor

I chatted with @saurabh500 and I just want to add that this is definitely something we all want to see get merged. It'll just take someone finding time (could take a few days dedicated time) to get their head wrapped around the new code and be able to help repro/debug to find the issue.

@Wraith2
Copy link
Contributor Author

Wraith2 commented Aug 28, 2024

I'm happy to make myself available to talk through the code with anyone that needs it.

@saurabh500
Copy link
Contributor

@Wraith2 and @David-Engel I was looking at the lifecycle of the snapshots and something that stood out in NetCore vs NetFx is that SqlDataReader for NetCore is storing the cached snapshot with the SqlInternalConnectionTds which is a shared resource among all the SqlDataReader(s) running on a MARS connection.

private void PrepareAsyncInvocation(bool useSnapshot)
{
    // if there is already a snapshot, then the previous async command
    // completed with exception or cancellation.  We need to continue
    // with the old snapshot.
    if (useSnapshot)
    {
        Debug.Assert(!_stateObj._asyncReadWithoutSnapshot, "Can't prepare async invocation with snapshot if doing async without snapshots");

        if (_snapshot == null)
        {
            if (_connection?.InnerConnection is SqlInternalConnection sqlInternalConnection)
            {
                _snapshot = Interlocked.Exchange(ref sqlInternalConnection.CachedDataReaderSnapshot, null) ?? new Snapshot();
            }
            else
            {
                _snapshot = new Snapshot();
            }

This means that we are saving the reader snapshot on the shared resource, which can be overwritten by any other reader.
Also a reader can receive another reader's snapshot.

@Wraith2 have you had a chance to pursue this line of investigation for hanging test?

I wonder if the timing is causing the wrong cached snapshot to be provided to a SqlDataReader, causing data corruption and likely causing a hang.

@saurabh500
Copy link
Contributor

SqlInternalConnection.cs


#if NET6_0_OR_GREATER
        internal SqlCommand.ExecuteReaderAsyncCallContext CachedCommandExecuteReaderAsyncContext;
        internal SqlCommand.ExecuteNonQueryAsyncCallContext CachedCommandExecuteNonQueryAsyncContext;
        internal SqlCommand.ExecuteXmlReaderAsyncCallContext CachedCommandExecuteXmlReaderAsyncContext;

        internal SqlDataReader.Snapshot CachedDataReaderSnapshot;
        internal SqlDataReader.IsDBNullAsyncCallContext CachedDataReaderIsDBNullContext;
        internal SqlDataReader.ReadAsyncCallContext CachedDataReaderReadAsyncContext;
#endif

@saurabh500
Copy link
Contributor

saurabh500 commented Sep 4, 2024

@Wraith2 I see that you had made the changes in the first place. Can you try another PR where you remove the storage of these contexts and snapshots on SqlInternalConnection and with the multiplexing change, try to see if this solves the problem.

Also, I am Happy to be told that my theory is wrong, but I would like to understand how in MARS cases, the shared Cached contexts on InternalConnection is a safe design choice.

@Wraith2
Copy link
Contributor Author

Wraith2 commented Sep 4, 2024

The snapshot caching has been present for a long time now and it's cleared and never moves between owners. The snapshot lifetime is dealt with by the async prepare and related functions which are highly conserved between both versions of the driver.

The cached async context objects are kept on the internal connection because that's the long-lived objects that is kept in the pool. Their ownership is opportunistic so if one is present on the internal connection it is always safe to use (see the Clear method on the base object for lifetime management) and if one isn't present then a new one is created. We could remove those caches for a small memory cost on repeated async operations but there's been no indication that they're in any way involved in a problem.

Also, I am Happy to be told that my theory is wrong, but I would like to understand how in MARS cases, the shared Cached contexts on InternalConnection is a safe design choice.

They're safe because interlocked is used to change their ownership. In Mars cases if you have multipe active readers that try to use the cached object only one can use it and the other will silently create a new object and use it. Only one can be put back in the cache and the other is dropped to the GC. Mars is not a common case and does not need to be as efficient as the non-mars case.

@saurabh500
Copy link
Contributor

saurabh500 commented Sep 4, 2024

I see. So its necessarily an object for anyone to opportunistically grab/reset and then reuse? Is this correct ?

@Wraith2
Copy link
Contributor Author

Wraith2 commented Sep 4, 2024

The async contexts, yes. All of them should be used through interlocks.

@saurabh500
Copy link
Contributor

@Wraith2 Have you looked at this failure ?

[xUnit.net 00:05:24.42]       Microsoft.Data.SqlClient.SqlException : Transaction (Process ID 138) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
  [xUnit.net 00:05:24.42]     Microsoft.Data.SqlClient.ManualTesting.Tests.BatchTests.MixedBatchSupported [FAIL]
  [xUnit.net 00:05:24.42]       Stack Trace:
  [xUnit.net 00:05:24.42]         /_/src/Microsoft.Data.SqlClient/netcore/src/Microsoft/Data/SqlClient/SqlConnection.cs(2132,0): at Microsoft.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
  [xUnit.net 00:05:24.42]         /_/src/Microsoft.Data.SqlClient/src/Microsoft/Data/SqlClient/SqlInternalConnection.cs(773,0): at Microsoft.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
  [xUnit.net 00:05:24.42]         /_/src/Microsoft.Data.SqlClient/netcore/src/Microsoft/Data/SqlClient/TdsParser.cs(1436,0): at Microsoft.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, SqlCommand command, Boolean callerHasConnectionLock, Boolean asyncClose)
  [xUnit.net 00:05:24.42]         /_/src/Microsoft.Data.SqlClient/netcore/src/Microsoft/Data/SqlClient/TdsParser.cs(2699,0): at Microsoft.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)
  [xUnit.net 00:05:24.42]         /_/src/Microsoft.Data.SqlClient/netcore/src/Microsoft/Data/SqlClient/SqlCommand.cs(5298,0): at Microsoft.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption, Boolean shouldCacheForAlwaysEncrypted)
  [xUnit.net 00:05:24.42]         /_/src/Microsoft.Data.SqlClient/netcore/src/Microsoft/Data/SqlClient/SqlCommand.cs(5168,0): at Microsoft.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean isAsync, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest)
  [xUnit.net 00:05:24.42]         /_/src/Microsoft.Data.SqlClient/netcore/src/Microsoft/Data/SqlClient/SqlCommand.cs(4845,0): at Microsoft.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry, String method)
  [xUnit.net 00:05:24.42]         /_/src/Microsoft.Data.SqlClient/netcore/src/Microsoft/Data/SqlClient/SqlCommand.cs(1701,0): at Microsoft.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(TaskCompletionSource`1 completion, Boolean sendToPipe, Int32 timeout, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry, String methodName)
  [xUnit.net 00:05:24.42]         /_/src/Microsoft.Data.SqlClient/netcore/src/Microsoft/Data/SqlClient/SqlCommand.cs(1221,0): at Microsoft.Data.SqlClient.SqlCommand.ExecuteNonQuery()
  [xUnit.net 00:05:24.42]         /_/src/Microsoft.Data.SqlClient/src/Microsoft/Data/SqlClient/SqlBatch.cs(92,0): at Microsoft.Data.SqlClient.SqlBatch.ExecuteNonQuery()
  [xUnit.net 00:05:24.42]         /_/src/Microsoft.Data.SqlClient/tests/ManualTests/SQL/Batch/BatchTests.cs(117,0): at Microsoft.Data.SqlClient.ManualTesting.Tests.BatchTests.MixedBatchSupported()
  [xUnit.net 00:05:24.42]            at System.RuntimeMethodHandle.InvokeMethod(Object target, Void** arguments, Signature sig, Boolean isConstructor)
  [xUnit.net 00:05:24.42]            at System.Reflection.MethodBaseInvoker.InvokeWithNoArgs(Object obj, BindingFlags invokeAttr)


@Wraith2
Copy link
Contributor Author

Wraith2 commented Sep 4, 2024

I did, it doesn't repro locally.

On the topic of reproducing problems. I've build an ubuntu 22.04 vm and installed rider to allow me to build this project. The tests require runtime version 2.1 for some reason and that isn't available (and hasn't been for a long time) on any supported ubuntu build. How are you running development environments on linux to investigate things? Is there some magic way to get netcore2.1 onto ubuntu that i can't find?

@saurabh500
Copy link
Contributor

saurabh500 commented Sep 5, 2024

I personally use the Ubuntu distribution with the .Net runtime and mostly use command line to launch the tests, and leverage console logs and traces.
In case I need to attach a debugger I use VS on windows with ssh remote debugging.
I am going to setup a new VM tomorrow. If the steps differ from what I described, I will let you know.

@Wraith2
Copy link
Contributor Author

Wraith2 commented Sep 11, 2024

I'm trying the linux thing again. The buildguide should be up to date but it's not helping. For example, the commands list just running msbuild but that's not available, the only option is to use dotnet msbuild which I can do but it doesn't reflect well on the accuracy. The build doesn't work because it can't find powershell. I have powershell installed but the executable is just called pwsh.

Have you had any luck getting a linux system build and working? has anyone else?

@Wraith2
Copy link
Contributor Author

Wraith2 commented Sep 13, 2024

wraith@UbuntuDev2204:~/RiderProjects/SqlClient$ dotnet test "src\Microsoft.Data.SqlClient\tests\ManualTests\Microsoft.Data.SqlClient.ManualTesting.Tests.csproj" -p:Platform="AnyCPU" -p:Configuration="Release" -p:TestTargetOS="Unixnetcoreapp" --no-build -v n --filter "FullyQualifiedName=Microsoft.Data.SqlClient.ManualTesting.Tests.AsyncCancelledConnectionsTest.CancelAsyncConnections"
Build started 13/09/2024 22:11:16.
Test run for /home/wraith/RiderProjects/SqlClient/artifacts/Project/bin/Unix/Release.AnyCPU.ManualTests/netcoreapp2.1/ManualTests.dll (.NETCoreApp,Version=v2.1)
Microsoft (R) Test Execution Command Line Tool Version 17.3.3 (x64)
Copyright (c) Microsoft Corporation.  All rights reserved.

Starting test execution, please wait...
A total of 1 test files matched the specified pattern.

Passed!  - Failed:     0, Passed:     1, Skipped:     0, Total:     1, Duration: < 1 ms - /home/wraith/RiderProjects/SqlClient/artifacts/Project/bin/Unix/Release.AnyCPU.ManualTests/netcoreapp2.1/ManualTests.dll (netcoreapp2.1)

Build succeeded.
    0 Warning(s)
    0 Error(s)

Time Elapsed 00:00:41.22

@cheenamalhotra
Copy link
Member

You can find the command from the CI logs (e.g. link to log) actually, in this case the command run on Unix agents is:

dotnet msbuild -t:BuildAll -p:TestEnabled=true -p:GenerateDocumentationFile=false -p:configuration=Release

I only needed to install dotnet SDKs (8.0 and 6.0) and PowerShell on Ubuntu 22 in order to run this command successfully.

Further steps to build and run steps are also available in logs likewise.

Note: These steps don't apply to WSL.

@Wraith2
Copy link
Contributor Author

Wraith2 commented Sep 20, 2024

Getting those items installed on the right version of Ubuntu didn't prove to be simple. It would also have been good to know that it has to be done on Ubuntu 2204 not 2404 because of package availability. Even with those things installed the test does not fail on my machine, as you can see from #2714 (comment) , and i cannot use remote debug over ssh to try and step through i can only run locally.

So all in all a month mostly wasted.

@David-Engel
Copy link
Contributor

David-Engel commented Sep 27, 2024

@Wraith2

I finally got the error to repro. Haven't debugged anything, yet. But here's my setup:

Installed Ubuntu 22.04 under WSL (install Ubuntu 22.04 from Microsoft Store).

Install PowerShell on Ubuntu: https://learn.microsoft.com/en-us/powershell/scripting/install/install-ubuntu?view=powershell-7.4#installation-via-package-repository-the-package-repository

Set MS packages repo preferred over Ubuntu's to avoid .NET errors wrt package conflicts. Create /etc/apt/99microsoft-dotnet.pref

Package: dotnet* aspnet* netstandard*
Pin: origin "archive.ubuntu.com"
Pin-Priority: -10

Package: dotnet* aspnet* netstandard*
Pin: origin "security.ubuntu.com"
Pin-Priority: -10
sudo apt update

Install .NET 6.0 and 8.0 SDKs:

sudo apt-get install dotnet-sdk-6.0 dotnet-sdk-8.0

Clone SqlClient and checkout branch:

git clone https://github.com/Wraith2/SqlClient
cd SqlClient
git checkout operation-status-part2

Define src/Microsoft.Data.SqlClient/tests/tools/Microsoft.Data.SqlClient.TestUtilities/config.json I pointed it at the IP that resolved to SQL Server on my machine outside of WSL, which already had Northwind created. Use nslookup <host machine name> for a list of potential IP addresses this might be in your Ubuntu instance.

{
    "TCPConnectionString": "Data Source=tcp:172.20.1.2;Database=Northwind;user id=sa;password=*****;Encrypt=f
alse;",
    "NPConnectionString": "Data Source=np:172.20.1.2;Database=Northwind;user id=sa;password=*****;Encrypt=fal
se;",
    "TCPConnectionStringHGSVBS": "",
    "TCPConnectionStringNoneVBS": "",
    "TCPConnectionStringAASSGX": "",
    "EnclaveEnabled": false,
    "TracingEnabled": false,
    "AADAuthorityURL": "",
    "AADPasswordConnectionString": "",
    "AADServicePrincipalId": "",
    "AADServicePrincipalSecret": "",
    "AzureKeyVaultURL": "",
    "AzureKeyVaultTenantId": "",
    "SupportsIntegratedSecurity": false,
    "LocalDbAppName": "",
    "LocalDbSharedInstanceName": "",
    "SupportsFileStream": false,
    "FileStreamDirectory": "",
    "UseManagedSNIOnWindows": false,
    "DNSCachingConnString": "",
    "DNSCachingServerCR": "",
    "DNSCachingServerTR": "",
    "IsDNSCachingSupportedCR": false,
    "IsDNSCachingSupportedTR": false,
    "IsAzureSynapse": false,
    "EnclaveAzureDatabaseConnString": "",
    "ManagedIdentitySupported": false,
    "UserManagedIdentityClientId": "",
    "PowerShellPath": "",
    "AliasName": ""
}

Restore NuGets:

cd src/Microsoft.Data.SqlClient/tests/ManualTests/
# or it might have been cd src/Microsoft.Data.SqlClient/tests/tools/Microsoft.Data.SqlClient.ExtUtilities/
# restoring one of these gets you past the failed to download package error from the feed on the root restore
dotnet restore
cd ~SqlClient
dotnet restore

Build

cd ~SqlClient
dotnet msbuild build.proj -t:BuildTestsNetCore -p:TF=net8.0 -p:TestSet=1 -p:ReferenceType=Project -p:OSGroup=Unix -p:platform=AnyCPU -p:Configuration=Release
dotnet msbuild build.proj -t:RunFunctionalTests -p:TF=net8.0 -p:TestSet=1 -p:ReferenceType=Project -p:platform=AnyCPU -p:Configuration=Release
dotnet msbuild build.proj -t:RunManualTests -p:TF=net8.0 -p:TestSet=1 -p:ReferenceType=Project -p:platform=AnyCPU -p:Configuration=Release
# Test fails in the above run
# Subsequent runs of just the one test fail for me, too
dotnet test "src\Microsoft.Data.SqlClient\tests\ManualTests\Microsoft.Data.SqlClient.ManualTesting.Tests.csproj" -p:TF=net8.0 -p:TargetnetcoreVersion=net8.0 -p:Platform="AnyCPU" -p:Configuration="Release" -p:TestTargetOS="Unixnetcoreapp" --no-build -v n --filter "FullyQualifiedName=Microsoft.Data.SqlClient.ManualTesting.Tests.AsyncCancelledConnectionsTest.CancelAsyncConnections"

Hopefully I didn't miss any steps. I am leaving out a bunch of commands that failed to resolve the various issues I encountered just to get tests to run. My hope is this will get you to a point where you can actually debug the issue.

[xUnit.net 00:00:08.99]   Finished:    ManualTests
  Failed Microsoft.Data.SqlClient.ManualTesting.Tests.AsyncCancelledConnectionsTest.CancelAsyncConnections [8 s]
  Error Message:
   Assert.Empty() Failure: Collection was not empty
Collection: ["Microsoft.Data.SqlClient.SqlException (0x80131904)"···, "Microsoft.Data.SqlClient.SqlException (0x80131904)"···]
  Stack Trace:
     at Microsoft.Data.SqlClient.ManualTesting.Tests.AsyncCancelledConnectionsTest.RunCancelAsyncConnections(SqlConnectionStringBuilder connectionStringBuilder) in /home/user/Source/SqlClient/src/Microsoft.Data.SqlClient/tests/ManualTests/SQL/AsyncTest/AsyncCancelledConnectionsTest.cs:line 71
   at Microsoft.Data.SqlClient.ManualTesting.Tests.AsyncCancelledConnectionsTest.CancelAsyncConnections() in /home/user/Source/SqlClient/src/Microsoft.Data.SqlClient/tests/ManualTests/SQL/AsyncTest/AsyncCancelledConnectionsTest.cs:line 32
   at System.RuntimeMethodHandle.InvokeMethod(Object target, Void** arguments, Signature sig, Boolean isConstructor)
   at System.Reflection.MethodBaseInvoker.InvokeWithNoArgs(Object obj, BindingFlags invokeAttr)
  Standard Output Messages:
 00:00:04.9921941 True Started:93 Done:54 InFlight:39 RowsRead:26559 ResultRead:2043 PoisonedEnded:54 nonPoisonedExceptions:54 PoisonedCleanupExceptions:0 Count:2 Found:0
 00:00:08.4835368 True Started:100 Done:100 InFlight:0 RowsRead:49582 ResultRead:3814 PoisonedEnded:100 nonPoisonedExceptions:97 PoisonedCleanupExceptions:0 Count:2 Found:0
 Microsoft.Data.SqlClient.SqlException (0x80131904): A severe error occurred on the current command.  The results, if any, should be discarded.
    at Microsoft.Data.SqlClient.SqlConnection.OnError(SqlE
 Microsoft.Data.SqlClient.SqlException (0x80131904): A severe error occurred on the current command.  The results, if any, should be discarded.
    at Microsoft.Data.SqlClient.TdsParser.ThrowExceptionAn

@Wraith2
Copy link
Contributor Author

Wraith2 commented Sep 28, 2024

That works flawlessly up until the build part.

wraith@Ubuntu:~/SqlClient$ dotnet msbuild
MSBuild version 17.11.4+37eb419ad for .NET
  Determining projects to restore...
  All projects are up-to-date for restore.
  Determining projects to restore...
  All projects are up-to-date for restore.
  Determining projects to restore...
  All projects are up-to-date for restore.
    Determining projects to restore...
    All projects are up-to-date for restore.
    Microsoft.Cci.Extensions -> /home/wraith/SqlClient/tools/GenAPI/Microsoft.Cci.Extensions/bin/Release/netstandard2.0/Microsoft.Cci.Extensions.dll
    Microsoft.DotNet.GenAPI -> /home/wraith/SqlClient/tools/GenAPI/Microsoft.DotNet.GenAPI/bin/Release/net6.0/Microsoft.DotNet.GenAPI.dll
    Microsoft.DotNet.GenAPI -> /home/wraith/SqlClient/tools/GenAPI/Microsoft.DotNet.GenAPI/bin/Release/net8.0/Microsoft.DotNet.GenAPI.dll
    Microsoft.DotNet.GenAPI -> /home/wraith/SqlClient/tools/GenAPI/Microsoft.DotNet.GenAPI/bin/Release/net472/Microsoft.DotNet.GenAPI.exe

  Build succeeded.
      0 Warning(s)
      0 Error(s)

  Time Elapsed 00:00:01.13
  Microsoft.SqlServer.Server -> /home/wraith/SqlClient/artifacts/Project/bin/Unix/Debug.AnyCPU/Microsoft.SqlServer.Server/netstandard2.0/Microsoft.SqlServer.Server.dll
  Microsoft.SqlServer.Server -> /home/wraith/SqlClient/artifacts/Project/bin/Unix/Debug.AnyCPU/Microsoft.SqlServer.Server/net46/Microsoft.SqlServer.Server.dll
  Microsoft.Data.SqlClient -> /home/wraith/SqlClient/artifacts/Project/bin/Unix/Debug/Microsoft.Data.SqlClient/ref/net6.0/Microsoft.Data.SqlClient.dll
  Microsoft.Data.SqlClient -> /home/wraith/SqlClient/artifacts/Project/bin/Unix/Debug/Microsoft.Data.SqlClient/ref/net8.0/Microsoft.Data.SqlClient.dll
  Microsoft.Data.SqlClient -> /home/wraith/SqlClient/artifacts/Project/bin/Unix/Debug.AnyCPU/Microsoft.Data.SqlClient/netcore/net8.0/Microsoft.Data.SqlClient.dll
  Microsoft.Data.SqlClient -> /home/wraith/SqlClient/artifacts/Project/bin/Unix/Debug.AnyCPU/Microsoft.Data.SqlClient/netcore/net6.0/Microsoft.Data.SqlClient.dll
  Microsoft.Data.SqlClient -> /home/wraith/SqlClient/artifacts/Project/bin/AnyOS/Debug/Microsoft.Data.SqlClient/ref/net6.0/Microsoft.Data.SqlClient.dll
  Microsoft.Data.SqlClient -> /home/wraith/SqlClient/artifacts/Project/bin/AnyOS/Debug/Microsoft.Data.SqlClient/ref/net8.0/Microsoft.Data.SqlClient.dll
  /usr/bin/sh: 2: /tmp/MSBuildTempwraith/tmp6c4f199d3704486ab7f21105cfc06597.exec.cmd:  /home/wraith/SqlClient/src/../artifacts/Project/tools/net8.0\Microsoft.DotNet.GenAPI.dll: not found
/home/wraith/SqlClient/tools/targets/NotSupported.targets(48,5): error MSB3073: The command " " /home/wraith/SqlClient/src/../artifacts/Project/tools/net8.0\Microsoft.DotNet.GenAPI.dll" "/home/wraith/SqlClient/artifacts/Project/bin/AnyOS/Debug/Microsoft.Data.SqlClient/ref/net8.0/Microsoft.Data.SqlClient.dll" -l:"/home/wraith/.nuget/packages/azure.core/1.38.0/lib/net6.0/;/home/wraith/.nuget/packages/azure.identity/1.11.4/lib/netstandard2.0/;/home/wraith/.nuget/packages/microsoft.bcl.asyncinterfaces/1.1.1/ref/netstandard2.1/;/usr/share/dotnet/packs/Microsoft.NETCore.App.Ref/8.0.8/ref/net8.0/;/home/wraith/.nuget/packages/microsoft.extensions.caching.abstractions/8.0.0/lib/net8.0/;/home/wraith/.nuget/packages/microsoft.extensions.caching.memory/8.0.0/lib/net8.0/;/home/wraith/.nuget/packages/microsoft.extensions.dependencyinjection.abstractions/8.0.0/lib/net8.0/;/home/wraith/.nuget/packages/microsoft.extensions.logging.abstractions/8.0.0/lib/net8.0/;/home/wraith/.nuget/packages/microsoft.extensions.options/8.0.0/lib/net8.0/;/home/wraith/.nuget/packages/microsoft.extensions.primitives/8.0.0/lib/net8.0/;/home/wraith/.nuget/packages/microsoft.identity.client/4.61.3/lib/net6.0/;/home/wraith/.nuget/packages/microsoft.identity.client.extensions.msal/4.61.3/lib/net6.0/;/home/wraith/.nuget/packages/microsoft.identitymodel.abstractions/7.5.0/lib/net8.0/;/home/wraith/.nuget/packages/microsoft.identitymodel.jsonwebtokens/7.5.0/lib/net8.0/;/home/wraith/.nuget/packages/microsoft.identitymodel.logging/7.5.0/lib/net8.0/;/home/wraith/.nuget/packages/microsoft.identitymodel.protocols/7.5.0/lib/net8.0/;/home/wraith/.nuget/packages/microsoft.identitymodel.protocols.openidconnect/7.5.0/lib/net8.0/;/home/wraith/.nuget/packages/microsoft.identitymodel.tokens/7.5.0/lib/net8.0/;/home/wraith/.nuget/packages/microsoft.sqlserver.server/1.0.0/lib/netstandard2.0/;/home/wraith/.nuget/packages/system.clientmodel/1.0.0/lib/net6.0/;/home/wraith/.nuget/packages/system.configuration.configurationmanager/8.0.0/lib/net8.0/;/home/wraith/.nuget/packages/system.diagnostics.eventlog/8.0.0/lib/net8.0/;/home/wraith/.nuget/packages/system.identitymodel.tokens.jwt/7.5.0/lib/net8.0/;/home/wraith/.nuget/packages/system.memory.data/1.0.2/lib/netstandard2.0/;/home/wraith/.nuget/packages/system.security.cryptography.protecteddata/8.0.0/lib/net8.0/" -o:"/home/wraith/SqlClient/src/../artifacts/Project/obj/Debug.AnyCPU/Microsoft.Data.SqlClient/netcore//net8.0/Microsoft.Data.SqlClient.notsupported.cs" -t:"Microsoft.Data.SqlClient is not supported on this platform."" exited with code 127. [/home/wraith/SqlClient/src/Microsoft.Data.SqlClient/netcore/src/Microsoft.Data.SqlClient.csproj::TargetFramework=net8.0]
  /usr/bin/sh: 2: /tmp/MSBuildTempwraith/tmp6cd4c5148eef4de6983e6d1ce31ff54f.exec.cmd:  /home/wraith/SqlClient/src/../artifacts/Project/tools/net6.0\Microsoft.DotNet.GenAPI.dll: not found
/home/wraith/SqlClient/tools/targets/NotSupported.targets(48,5): error MSB3073: The command " " /home/wraith/SqlClient/src/../artifacts/Project/tools/net6.0\Microsoft.DotNet.GenAPI.dll" "/home/wraith/SqlClient/artifacts/Project/bin/AnyOS/Debug/Microsoft.Data.SqlClient/ref/net6.0/Microsoft.Data.SqlClient.dll" -l:"/home/wraith/.nuget/packages/azure.core/1.38.0/lib/net6.0/;/home/wraith/.nuget/packages/azure.identity/1.11.4/lib/netstandard2.0/;/home/wraith/.nuget/packages/microsoft.bcl.asyncinterfaces/1.1.1/ref/netstandard2.1/;/home/wraith/.nuget/packages/microsoft.netcore.app.ref/6.0.33/ref/net6.0/;/home/wraith/.nuget/packages/microsoft.extensions.caching.abstractions/6.0.0/lib/netstandard2.0/;/home/wraith/.nuget/packages/microsoft.extensions.caching.memory/6.0.1/lib/netstandard2.0/;/home/wraith/.nuget/packages/microsoft.extensions.dependencyinjection.abstractions/6.0.0/lib/net6.0/;/home/wraith/.nuget/packages/microsoft.extensions.logging.abstractions/6.0.0/lib/net6.0/;/home/wraith/.nuget/packages/microsoft.extensions.options/6.0.0/lib/netstandard2.1/;/home/wraith/.nuget/packages/microsoft.extensions.primitives/6.0.0/lib/net6.0/;/home/wraith/.nuget/packages/microsoft.identity.client/4.61.3/lib/net6.0/;/home/wraith/.nuget/packages/microsoft.identity.client.extensions.msal/4.61.3/lib/net6.0/;/home/wraith/.nuget/packages/microsoft.identitymodel.abstractions/7.5.0/lib/net6.0/;/home/wraith/.nuget/packages/microsoft.identitymodel.jsonwebtokens/7.5.0/lib/net6.0/;/home/wraith/.nuget/packages/microsoft.identitymodel.logging/7.5.0/lib/net6.0/;/home/wraith/.nuget/packages/microsoft.identitymodel.protocols/7.5.0/lib/net6.0/;/home/wraith/.nuget/packages/microsoft.identitymodel.protocols.openidconnect/7.5.0/lib/net6.0/;/home/wraith/.nuget/packages/microsoft.identitymodel.tokens/7.5.0/lib/net6.0/;/home/wraith/.nuget/packages/microsoft.sqlserver.server/1.0.0/lib/netstandard2.0/;/home/wraith/.nuget/packages/microsoft.win32.systemevents/6.0.0/lib/net6.0/;/home/wraith/.nuget/packages/system.clientmodel/1.0.0/lib/net6.0/;/home/wraith/.nuget/packages/system.configuration.configurationmanager/6.0.1/lib/net6.0/;/home/wraith/.nuget/packages/system.drawing.common/6.0.0/lib/net6.0/;/home/wraith/.nuget/packages/system.identitymodel.tokens.jwt/7.5.0/lib/net6.0/;/home/wraith/.nuget/packages/system.memory.data/1.0.2/lib/netstandard2.0/;/home/wraith/.nuget/packages/system.security.cryptography.protecteddata/6.0.0/lib/net6.0/;/home/wraith/.nuget/packages/system.security.permissions/6.0.0/lib/net6.0/;/home/wraith/.nuget/packages/system.windows.extensions/6.0.0/lib/net6.0/" -o:"/home/wraith/SqlClient/src/../artifacts/Project/obj/Debug.AnyCPU/Microsoft.Data.SqlClient/netcore//net6.0/Microsoft.Data.SqlClient.notsupported.cs" -t:"Microsoft.Data.SqlClient is not supported on this platform."" exited with code 127. [/home/wraith/SqlClient/src/Microsoft.Data.SqlClient/netcore/src/Microsoft.Data.SqlClient.csproj::TargetFramework=net6.0]
wraith@Ubuntu:~/SqlClient$

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants