URL detection regex was including trailing content in the URL after semi-colon. In some connection strings this would pick up extra values, e.g. content after the URL would be included in Endpoint=http://myaccount.example.com/;key=abc.
The new URL is based on GitHub's URL detection for source code. It excludes content after ; from the URL. This is the same behavior as VS. Technically ; can be part of a URL, but more commonly it is used as a delimiter for connection strings and collections of URLs.
There isn't a perfect answer here, but the new regex match seems the better alternative. We should be conservative when assuming what content should be in the URL rather than aggressively including too much.
Checklist
Is this feature complete?
[x] Yes. Ready to ship.
[ ] No. Follow-up changes expected.
Are you including unit tests for the changes and scenario tests if relevant?
[x] Yes
[ ] No
Did you add public API?
[ ] Yes
If yes, did you have an API Review for it?
[ ] Yes
[ ] No
Did you add <remarks /> and <code /> elements on your triple slash comments?
[ ] Yes
[ ] No
[x] No
Does the change make any security assumptions or guarantees?
[x] Yes
If yes, have you done a threat model and had a security review?
[ ] Yes
[x] No TBD
[ ] No
Does the change require an update in our Aspire docs?
Description
URL detection regex was including trailing content in the URL after semi-colon. In some connection strings this would pick up extra values, e.g. content after the URL would be included in
Endpoint=http://myaccount.example.com/;key=abc
.The new URL is based on GitHub's URL detection for source code. It excludes content after
;
from the URL. This is the same behavior as VS. Technically;
can be part of a URL, but more commonly it is used as a delimiter for connection strings and collections of URLs.There isn't a perfect answer here, but the new regex match seems the better alternative. We should be conservative when assuming what content should be in the URL rather than aggressively including too much.
Checklist
<remarks />
and<code />
elements on your triple slash comments?Does the change require an update in our Aspire docs?
breaking-change
template):doc-idea
template):Microsoft Reviewers: Open in CodeFlow