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

feat: Send + Sync trait to AsyncFtpStream/FtpStream #61

Merged
merged 3 commits into from
Nov 14, 2023

Conversation

newfla
Copy link
Contributor

@newfla newfla commented Nov 13, 2023

45 - Send + Sync traits to AsyncFtpStream/FtpStream

Fixes #45

Description

To make AsyncFtpStream/FtpStream Send+Sync, tls_ctx should be declared as Send+Sync. AsyncTlsConnector and TlsConnector already satisfay Send+Sync traits so no breaking change is expected

List here your changes

  • tls_ctx: Option<Box<dyn AsyncTlsConnector<Stream = T>>> to tls_ctx: Option<Box<dyn AsyncTlsConnector<Stream = T> + Send + Sync + 'static>

Type of change

Please select relevant options.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Acceptance tests

wait for a project maintainer to fulfill this section...

  • regression test: ...

@veeso veeso self-assigned this Nov 13, 2023
@newfla
Copy link
Contributor Author

newfla commented Nov 14, 2023

@veeso I've missed a trait bound in both async and sync code.
Similarly, Sync trait can be added to make the use of the library much more ergonomic in multi-threaded contexts. Should I prepare a new pr or would you prefer an addition to this one?

@veeso
Copy link
Owner

veeso commented Nov 14, 2023

@newfla No, I think you can add it here. Thank you in advance

@newfla newfla changed the title feat: Send trait to AsyncFtpStream/FtpStream feat: Send + Sync trait to AsyncFtpStream/FtpStream Nov 14, 2023
@veeso veeso merged commit 388533e into veeso:main Nov 14, 2023
2 of 4 checks passed
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.

[Feature Request] - Add Send trait to AsyncFtpStream/FtpStream
2 participants