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

Implement Crate Feature to Disable SSL on Windows for ScyllaDB Node.js Driver #21

Open
Daniel-Boll opened this issue Oct 18, 2023 · 0 comments
Labels
CI/CD enhancement New feature or request good first issue Good for newcomers hacktoberfest help wanted Extra attention is needed

Comments

@Daniel-Boll
Copy link
Owner

Daniel-Boll commented Oct 18, 2023

The driver is currently facing a build issue on Windows due to problems encountered with OpenSSL configuration. To work around this issue and re-establish Windows support, this task proposes the introduction of a crate feature that will disable SSL on Windows platforms. This will simplify the build process and ensure functionality, albeit without SSL support for the time being.

Here's a breakdown of the task:

  1. Feature Flag Creation:
    • Create a new feature flag, e.g., disable-ssl, in the Cargo.toml file.
    • Ensure this feature is conditional for Windows platforms only.
[features]
disable-ssl = ["cfg(windows)"]
  1. Conditional Compilation and Dependency Exclusion:
    • Use Rust's conditional compilation attributes to disable the SSL-related code and dependencies when the disable-ssl feature is enabled.
    • Adjust the dependency declarations in Cargo.toml to exclude SSL dependencies on Windows.
#[cfg(not(feature = "disable-ssl"))]
extern crate openssl;
[dependencies]
scylla = { version = "0.10.1", features = ["ssl"], optional = true }
openssl = { version = "0.10", features = ["vendored"], optional = true }

[target.'cfg(windows)'.dependencies]
scylla = { version = "0.10.1", default-features = false } # There might be more things necessary
  1. Documentation:

    • Update the project documentation to explain the new feature flag and its implications.
    • Include clear instructions for Windows users on how to use this feature to build the project, while making them aware of the temporary lack of SSL support.
  2. Testing:

    • Ensure that the project builds successfully on Windows with the disable-ssl feature enabled.
    • Test the functionality of the driver on Windows to ensure it operates as expected without SSL.
  3. Future Work:

    • Mention that this is a temporary workaround, and that a more robust solution to fix the OpenSSL issue on Windows and re-enable SSL support is in the pipeline.

This issue serves as a call for contributions to implement this feature, and invites discussion on any alternative solutions or potential implications. By addressing the OpenSSL configuration problem in a phased manner, we can promptly restore Windows compatibility for the ScyllaDB Node.js driver while working towards a complete solution.

@Daniel-Boll Daniel-Boll added enhancement New feature or request help wanted Extra attention is needed good first issue Good for newcomers hacktoberfest CI/CD labels Oct 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI/CD enhancement New feature or request good first issue Good for newcomers hacktoberfest help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant