AlexPikalov / cdrs

Cassandra DB native client written in Rust language. Find 1.x versions on https://github.com/AlexPikalov/cdrs/tree/v.1.x Looking for an async version? - Check WIP https://github.com/AlexPikalov/cdrs-async
Apache License 2.0
341 stars 58 forks source link

Introduce rust-tls feature #321

Closed DoumanAsh closed 4 years ago

DoumanAsh commented 4 years ago

This introduces rust-tls features with rustls and webpki

For simplicity sake user is the one who configures rustls as it is rather complicated.

I feel like it would be better to come up with some generic for transport layer, but I decided for now we can go with code duplication

Closes #315

AlexPikalov commented 4 years ago

Hi @DoumanAsh ,

Appreciate your work in this important topic. 🥇 I see it's a draft, please let me know when you think it's ready for review and merge so I can start looking on it.

DoumanAsh commented 4 years ago

@AlexPikalov Actually I htink it is pretty ready, but I wasn't sure about unit tests

AlexPikalov commented 4 years ago

Taking into account that unit tests assume mocks for a network e2e tests could be more valuable in this case.

Similarly to other Rust projects we have our e2e in ./tests. Potentially you could create setup function which would use your transport for connection and then use both transport option in tests. Though we don't have a code for running tests using different transport so some transportoptions. So, some resolver for tests purposes may be needed.

DoumanAsh commented 4 years ago

@AlexPikalov Sorry, it takes me sometime. I'll try to test it with my other PC where I have cassandra already installed and ready

AlexPikalov commented 4 years ago

@AlexPikalov Sorry, it takes me sometime. I'll try to test it with my other PC where I have cassandra already installed and ready

@DoumanAsh No worries. I know testing is always time-consuming. Please just let me know when we can proceed with it.