PoC for ARM64 support of LocalDB#1952
Closed
Matteo-T wants to merge 1 commit intodotnet:3.1-servicingfrom
Closed
Conversation
Matteo-T
commented
Mar 14, 2023
| private bool LoadUserInstanceDll() | ||
| { | ||
| _sqlUserInstanceLibraryHandle = null; | ||
| throw new Exception(); |
Author
There was a problem hiding this comment.
This was not meant to be part of the change. I may have been playing around with it on my AMD64 dev box, so I wanted to make it fail artificially. Oops...
Author
|
Any takers? Good? Bad? Horrible? :) |
ErikEJ
reviewed
Mar 19, 2023
|
|
||
| // TODO: Are named pipes the only option for SqlLocaLDB? | ||
| // TODO: Probably sensitive to move out of this method to avoid compiling it all the time | ||
| System.Text.RegularExpressions.Regex regex = new System.Text.RegularExpressions.Regex("(np:.+)\r", System.Text.RegularExpressions.RegexOptions.Compiled | System.Text.RegularExpressions.RegexOptions.CultureInvariant); |
Author
There was a problem hiding this comment.
Yup - keep in mind this is very crude PoC.
ErikEJ
reviewed
Mar 19, 2023
|
|
||
| var lines = alllines.Split(new[] { Environment.NewLine }, StringSplitOptions.RemoveEmptyEntries); | ||
|
|
||
| // TODO: Are named pipes the only option for SqlLocaLDB? |
Contributor
There was a problem hiding this comment.
Yes, LocalDB only uses named pipes (no networking)
ErikEJ
reviewed
Mar 19, 2023
| // the connection string we are looking for! | ||
| foreach (var line in lines) | ||
| { | ||
| var foo = regex.Match(line); |
Contributor
|
Closing as this is a POC and work has been carried forward in a different PR. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
@DavoudEshtehari / @cheenamalhotra / @David-Engel - FYI, this the "Proof of Concept" I've been toying with in the last couple of days.
The logic is as follows:
SqlUserInstance.dllthat is AMD64):SqlLocalDB.exe s <instancename>(to make sure the instance is started) - it's a no-op if it is already running, I believeSqlLocalDB.exe i <instancename>to get the connection string, i.e. the named pipe to use - assumption: SqlLocalDB always exposed named pipesHere's my test app (built for net7.0):
It's output looks like this on my ARM64 box: