-
Notifications
You must be signed in to change notification settings - Fork 13.8k
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
chore(ssh): Allow users to set TUNNEL_TIMEOUT from config #24202
Conversation
superset/config.py
Outdated
@@ -515,6 +515,7 @@ class D3Format(TypedDict, total=False): | |||
# ---------------------------------------------------------------------- | |||
SSH_TUNNEL_MANAGER_CLASS = "superset.extensions.ssh.SSHManager" | |||
SSH_TUNNEL_LOCAL_BIND_ADDRESS = "127.0.0.1" | |||
SSH_TUNNEL_TIMEOUT = 1.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe SSH_TUNNEL_TIMEOUT_SECS
?
superset/extensions/ssh.py
Outdated
@@ -34,6 +34,7 @@ class SSHManager: | |||
def __init__(self, app: Flask) -> None: | |||
super().__init__() | |||
self.local_bind_address = app.config["SSH_TUNNEL_LOCAL_BIND_ADDRESS"] | |||
TUNNEL_TIMEOUT = app.config["SSH_TUNNEL_TIMEOUT"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does this set the TUNNEL_TIMEOUT
constant back to sshtunel? or we still need to invoke sshtunel. TUNNEL_TIMEOUT = "value"
can we add a test for this?
Codecov Report
@@ Coverage Diff @@
## master #24202 +/- ##
===========================================
- Coverage 68.30% 57.23% -11.08%
===========================================
Files 1957 1957
Lines 75588 75590 +2
Branches 8223 8223
===========================================
- Hits 51633 43264 -8369
- Misses 21848 30219 +8371
Partials 2107 2107
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 305 files with indirect coverage changes 📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
a015cd8
to
af94f53
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
…ache#24202)" This reverts commit 8b0c68c.
SUMMARY
Creating a new config variable
SSH_TUNNEL_TIMEOUT
this setting will allowsshtunnel
to hold request for this time limit with the VPC.BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
TESTING INSTRUCTIONS
ADDITIONAL INFORMATION