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

fix AspNet productInfo #2168

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from
Open

fix AspNet productInfo #2168

wants to merge 1 commit into from

Conversation

terencefan
Copy link
Member

@terencefan terencefan commented Feb 26, 2025

This pull request focuses on improving the handling of headers in the ConnectionFactory classes and updating relevant tests to ensure proper functionality. The key changes include refactoring methods for setting headers, adding a new method for setting the internal user agent, and updating test cases accordingly.

Improvements to header handling:

Updates to test cases:

@terencefan terencefan enabled auto-merge (squash) February 26, 2025 03:39
@terencefan terencefan force-pushed the tefa/fix-aspnet-header branch from 827676f to 515bb98 Compare February 26, 2025 05:58
protected abstract void SetCustomHeaders(IDictionary<string, string> headers);

private static void CheckHeaders(IDictionary<string, string> headers, string forbidPrefix)
private static void CheckHeadersPrefix(IDictionary<string, string> headers, string forbidPrefix)
Copy link
Member

Choose a reason for hiding this comment

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

use params string[]?

{
var key = item.First().Key;
var key = item[0].Key;
Copy link
Member

Choose a reason for hiding this comment

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

why only reporting first key

return headers;
}

internal virtual void SetInternalHeaders(IDictionary<string, string> headers)
internal virtual void SetServerId(IDictionary<string, string> headers)
Copy link
Member

Choose a reason for hiding this comment

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

private is enough? We already have customServerIdProvider to hook in server id

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.

2 participants