Skip to content

Conversation

@khushijain21
Copy link
Contributor

@khushijain21 khushijain21 commented Sep 5, 2025

What does this PR do?

This PR supports additonal options on certain method intlscommon package to accept a local logger.

This is part of the effort to get rid of global states.

Why is it important?

Checklist

  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
  • I have added tests that prove my fix is effective or that my feature works

Related issues

@khushijain21 khushijain21 requested a review from a team as a code owner September 5, 2025 07:28
@khushijain21 khushijain21 requested review from andrzej-stencel and leehinman and removed request for a team September 5, 2025 07:28
@khushijain21 khushijain21 changed the title tlsglobal3 "Replace global logger with local logger in tlscommon package" Sep 5, 2025
@elasticmachine
Copy link
Collaborator

💚 Build Succeeded

History

}

func NewClientWithDialer(d Dialer, c Config, network, host string, defaultPort int) (*Client, error) {
func NewClientWithDialer(d Dialer, c Config, network, host string, defaultPort int, logger *logp.Logger) (*Client, error) {
Copy link
Member

Choose a reason for hiding this comment

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

this makes it a breaking change 😅


func TLSDialer(forward Dialer, config *tlscommon.TLSConfig, timeout time.Duration) Dialer {
return TestTLSDialer(testing.NullDriver, forward, config, timeout)
func TLSDialer(forward Dialer, config *tlscommon.TLSConfig, timeout time.Duration, logger *logp.Logger) Dialer {
Copy link
Member

Choose a reason for hiding this comment

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

same as above

@khushijain21 khushijain21 marked this pull request as draft September 5, 2025 07:57
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.

3 participants