hypershell 2.9.0a5__tar.gz → 2.9.0a6__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/PKG-INFO +1 -1
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_param_ref.rst +166 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/database.rst +29 -0
- hypershell-2.9.0a6/docs/_include/relay_desc.rst +76 -0
- hypershell-2.9.0a6/docs/_include/relay_help.rst +64 -0
- hypershell-2.9.0a6/docs/_include/relay_usage.rst +2 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/index.rst +1 -0
- hypershell-2.9.0a6/docs/cli/relay.rst +40 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/manual.rst +14 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/security.rst +57 -3
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/pyproject.toml +1 -1
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/share/bash_completion.d/hs +26 -1
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/share/man/man1/hs.1 +335 -1
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/share/man/man1/hsx.1 +335 -1
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/share/man/man1/hyper-shell.1 +335 -1
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/share/zsh/site-functions/_hs +21 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/__init__.py +4 -1
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/cluster/remote.py +8 -1
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/config.py +92 -1
- hypershell-2.9.0a6/src/hypershell/core/heartbeat.py +120 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/logging.py +1 -1
- hypershell-2.9.0a6/src/hypershell/core/reconnect.py +537 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/data/model.py +95 -35
- hypershell-2.9.0a6/src/hypershell/relay/__init__.py +1036 -0
- hypershell-2.9.0a6/src/hypershell/relay/site.py +318 -0
- hypershell-2.9.0a6/src/hypershell/relay/store.py +401 -0
- hypershell-2.9.0a6/src/hypershell/relay/upstream.py +868 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/server.py +79 -6
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/__init__.py +10 -3
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_contended_recovery.py +26 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_contended_write.py +28 -4
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_logging.py +2 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_main.py +11 -1
- hypershell-2.9.0a6/tests/test_relay_connector.py +639 -0
- hypershell-2.9.0a6/tests/test_relay_db.py +415 -0
- hypershell-2.9.0a6/tests/test_relay_fsm.py +929 -0
- hypershell-2.9.0a6/tests/test_relay_judge.py +331 -0
- hypershell-2.9.0a6/tests/test_relay_launch.py +700 -0
- hypershell-2.9.0a6/tests/test_relay_link.py +390 -0
- hypershell-2.9.0a6/tests/test_relay_outage.py +267 -0
- hypershell-2.9.0a6/tests/test_relay_return.py +716 -0
- hypershell-2.9.0a6/tests/test_relay_roster.py +519 -0
- hypershell-2.9.0a6/tests/test_relay_workload.py +1152 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_upgrade_cli.py +3 -1
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_writeback.py +19 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_zone_postgres.py +23 -2
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/uv.lock +1 -1
- hypershell-2.9.0a5/src/hypershell/core/heartbeat.py +0 -81
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/.gitignore +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/CODE_OF_CONDUCT.md +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/LICENSE +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/README.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/Makefile +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/citation.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/client_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/client_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/client_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/cluster_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/cluster_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/cluster_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_edit_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_edit_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_edit_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_get_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_get_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_get_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_intro.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_intro_alt.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_pythonpath.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_set_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_set_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_set_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_site_vars.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_task_env.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_task_env_alt.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_which_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_which_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/config_which_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/database_alt.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/exit_status.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/initdb_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/initdb_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/initdb_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/license.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/security_alt.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/server_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/server_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/server_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/signals.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/submit_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/submit_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/submit_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_groups_alt.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_info_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_info_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_info_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_run_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_run_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_run_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_search_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_search_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_search_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_submit_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_submit_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_submit_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_update_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_update_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_update_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_wait_desc.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_wait_help.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/task_wait_usage.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/templates.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/templates_alt.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_include/tls_cli_options.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_static/custom.css +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_static/logo-dark-mode.png +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/_static/logo-light-mode.png +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/alternatives.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/api/client.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/api/cluster.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/api/data.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/api/index.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/api/server.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/api/submit.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/client.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/cluster.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/config.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/config_edit.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/config_get.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/config_set.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/config_which.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/initdb.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/server.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/submit.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/task_info.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/task_run.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/task_search.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/task_submit.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/task_update.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/cli/task_wait.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/conf.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/config.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/database.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/getting_started.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/index.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/install.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/logging.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/docs/templates.rst +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/share/bash_completion.d/hsx +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/client.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/cluster/__init__.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/cluster/launch.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/cluster/local.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/cluster/ssh.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/config.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/__init__.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/dispatch.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/exceptions.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/fsm.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/platform.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/pretty_print.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/queue.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/remote.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/resource.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/signal.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/sys.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/tag.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/template.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/thread.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/tls.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/types.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/core/uuid.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/data/__init__.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/data/core.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/data/timescale.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/data/upgrade.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/submit.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/src/hypershell/task.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/bench/bench_queue.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/cluster/build_archive.sh +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/cluster/compare.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/cluster/drive.sh +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/cluster/smoke.sh +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/conftest.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/fixtures/README.md +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/fixtures/hypershell-2.8.3.db +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/fixtures/make-2.8.3-db.sh +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/fixtures/make-legacy-postgres.sh +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_autoscale.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_cancel.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_card_info.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_card_integration.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_card_render.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_client.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_client_request.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_cluster.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_cluster_compare.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_cluster_launch.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_completions.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_data/__init__.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_data/test_core.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_data/test_model.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_data/test_upgrade.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_dispatch.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_dispatch_staged.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_dispatch_version.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_dispatch_workload.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_factory_fsm.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_group_order.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_groups.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_initdb.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_list.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_meta_status.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_queue.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_queue_address_family.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_queue_gc.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_queue_limits.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_queue_start.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_queue_tls.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_queue_workload.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_restart.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_retry_gate.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_server.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_server_fsm.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_signal.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_source.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_status_label.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_submit.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_submit_json.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_template.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_timescale.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_update.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_upgrade_postgres.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_writeback_postgres.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_writeback_statement.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_zone_dispatch.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_zone_display.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_zone_model.py +0 -0
- {hypershell-2.9.0a5 → hypershell-2.9.0a6}/tests/test_zone_workload.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: hypershell
|
|
3
|
-
Version: 2.9.
|
|
3
|
+
Version: 2.9.0a6
|
|
4
4
|
Summary: A cross-platform, high-throughput computing utility for processing shell commands over a distributed, asynchronous queue.
|
|
5
5
|
Project-URL: Homepage, https://hypershell.org
|
|
6
6
|
Project-URL: Documentation, https://hypershell.readthedocs.io
|
|
@@ -517,6 +517,172 @@
|
|
|
517
517
|
For a *dynamic* autoscaling policy, this sets an upper limit on the number of launched
|
|
518
518
|
clients. When this number is reached, scaling stops regardless of task pressure.
|
|
519
519
|
|
|
520
|
+
``[relay]``
|
|
521
|
+
Section for the `relay` workflow, which connects a site to an upstream *server*.
|
|
522
|
+
|
|
523
|
+
``.database``
|
|
524
|
+
Path to the relay database (default: <lib>/relay/<host>.db).
|
|
525
|
+
|
|
526
|
+
The relay database is always a private SQLite file, whatever ``[database]`` names; a relay
|
|
527
|
+
never opens the configured database. The default is named for the host, since a home
|
|
528
|
+
directory is often shared between hosts. A node-local disk is a good place for it.
|
|
529
|
+
|
|
530
|
+
See also ``--database`` command-line option.
|
|
531
|
+
|
|
532
|
+
``.bind``
|
|
533
|
+
Bind address of the relay-local *server* (default: `0.0.0.0`).
|
|
534
|
+
|
|
535
|
+
The *clients* at the site connect here. See also ``--bind`` command-line option.
|
|
536
|
+
|
|
537
|
+
``.port``
|
|
538
|
+
Port of the relay-local *server* (default: `50002`).
|
|
539
|
+
|
|
540
|
+
See also ``--port`` command-line option.
|
|
541
|
+
|
|
542
|
+
``.bundlesize``
|
|
543
|
+
Size of task bundle for the relay-local *server* and the *clients* at its site
|
|
544
|
+
(default: `1`).
|
|
545
|
+
|
|
546
|
+
It is never smaller than ``relay.num_threads``: a *client* asks for one bundle at a time,
|
|
547
|
+
so a smaller bundle would leave its executors idle between requests.
|
|
548
|
+
|
|
549
|
+
``.bundlewait``
|
|
550
|
+
Seconds the relay waits before returning finished tasks upstream regardless of
|
|
551
|
+
`bundlesize` (default: `5`).
|
|
552
|
+
|
|
553
|
+
``.poll``
|
|
554
|
+
Maximum polling interval of the relay-local scheduler in seconds (default: `0.1`).
|
|
555
|
+
|
|
556
|
+
Received tasks wait at most this long before the relay-local *server* hands them out.
|
|
557
|
+
|
|
558
|
+
``.retention``
|
|
559
|
+
Seconds a result is kept in the relay database after it has been returned upstream
|
|
560
|
+
(default: `300`). Results not yet returned are always kept.
|
|
561
|
+
|
|
562
|
+
``.zone``
|
|
563
|
+
Zone or zones the relay serves (default: none, the default zone).
|
|
564
|
+
|
|
565
|
+
One zone name, a list of names, or one table per zone, ``[relay.zone.NAME]``, which may
|
|
566
|
+
give that zone's own ``launcher``, ``launcher_args`` and ``size`` (each in place of the
|
|
567
|
+
relay's, for that zone's *clients* only); an empty table serves the zone with the relay's.
|
|
568
|
+
Upstream the relay is one *client* per zone, each with its own identity; at the site it
|
|
569
|
+
keeps one fleet of *clients* per zone, all served by the relay-local *server*. The first
|
|
570
|
+
zone's identity lists the site's *clients* upstream.
|
|
571
|
+
|
|
572
|
+
.. code-block:: toml
|
|
573
|
+
|
|
574
|
+
[relay.zone.cpu]
|
|
575
|
+
|
|
576
|
+
[relay.zone.gpu]
|
|
577
|
+
size = 2
|
|
578
|
+
launcher = "srun"
|
|
579
|
+
launcher_args = "--gres=gpu:1"
|
|
580
|
+
|
|
581
|
+
See also ``--zone`` command-line option, which names the zones in place of this one.
|
|
582
|
+
|
|
583
|
+
``.site``
|
|
584
|
+
Name of the relay's site (default: none, the relay's host name).
|
|
585
|
+
|
|
586
|
+
The upstream *server* records the relay, and the *clients* at its site, under this name.
|
|
587
|
+
|
|
588
|
+
``.size``
|
|
589
|
+
Number of *clients* the relay keeps launched at its site (default: `1`, at least `1`).
|
|
590
|
+
|
|
591
|
+
See also ``-N``, ``--size`` command-line option.
|
|
592
|
+
|
|
593
|
+
``.launcher``
|
|
594
|
+
Command prefix used to launch each *client* at the site (default: none).
|
|
595
|
+
|
|
596
|
+
An empty value launches clients directly as ``hs client ...``.
|
|
597
|
+
See also ``--launcher`` command-line option.
|
|
598
|
+
|
|
599
|
+
``.launcher_args``
|
|
600
|
+
Extra arguments for the launcher (default: none).
|
|
601
|
+
|
|
602
|
+
See also ``--launcher-args`` command-line option.
|
|
603
|
+
|
|
604
|
+
``.num_threads``
|
|
605
|
+
Executor threads for each *client* at the site (default: `1`).
|
|
606
|
+
|
|
607
|
+
``.template``
|
|
608
|
+
Command template for the *clients* at the site (default: `{}`).
|
|
609
|
+
|
|
610
|
+
``.timeout``
|
|
611
|
+
Seconds a *client* at the site waits for tasks before it exits (default: `0`, never).
|
|
612
|
+
|
|
613
|
+
``[upstream]``
|
|
614
|
+
Connection to the upstream *server*. These settings are never read from ``[server]``,
|
|
615
|
+
so the *clients* at the site keep using the relay's own ``[server.tls]``.
|
|
616
|
+
|
|
617
|
+
``.host``
|
|
618
|
+
Hostname of the upstream *server* (default: `localhost`).
|
|
619
|
+
|
|
620
|
+
See also ``--upstream-host`` command-line option.
|
|
621
|
+
|
|
622
|
+
``.port``
|
|
623
|
+
Port of the upstream *server* (default: `50001`).
|
|
624
|
+
|
|
625
|
+
See also ``--upstream-port`` command-line option.
|
|
626
|
+
|
|
627
|
+
``.auth``
|
|
628
|
+
Cryptographic key for the upstream *server*.
|
|
629
|
+
|
|
630
|
+
Use ``.auth_env`` or ``.auth_eval`` to keep it out of the file; whichever form is set
|
|
631
|
+
in the highest-precedence place is used (two forms in one place are refused). The
|
|
632
|
+
upstream key stays in the relay: the *clients* at the site use a key the relay mints for
|
|
633
|
+
each run.
|
|
634
|
+
|
|
635
|
+
``.bundlesize``
|
|
636
|
+
Bundle size the relay advertises upstream (default: `1000`).
|
|
637
|
+
|
|
638
|
+
The relay holds at most twice its connected *clients* times ``relay.bundlesize`` in
|
|
639
|
+
unfinished tasks. It asks for more only once half of that is left, and then for the
|
|
640
|
+
whole difference (never more than this size at once), so the site has a second round
|
|
641
|
+
of work ready while the first runs.
|
|
642
|
+
|
|
643
|
+
``.heartrate``
|
|
644
|
+
Seconds between heartbeats to the upstream *server* (default: `10`).
|
|
645
|
+
|
|
646
|
+
``.deadline``
|
|
647
|
+
Seconds a call to the upstream *server* may take before the relay takes the connection
|
|
648
|
+
as lost (default: `30`).
|
|
649
|
+
|
|
650
|
+
While the upstream *server* cannot be reached, the site keeps running and finished
|
|
651
|
+
tasks are kept in the relay database; the relay connects again, with backoff, and then
|
|
652
|
+
returns them before it asks for more work.
|
|
653
|
+
|
|
654
|
+
``.backoff``
|
|
655
|
+
Longest wait in seconds between attempts to reach the upstream *server* again
|
|
656
|
+
(default: `60`).
|
|
657
|
+
|
|
658
|
+
Each wait is drawn at random up to a bound that starts at one second and doubles with
|
|
659
|
+
each failed attempt, up to this value.
|
|
660
|
+
|
|
661
|
+
``.evict_hint``
|
|
662
|
+
Seconds of lost contact after which the relay takes the upstream *server* to have
|
|
663
|
+
evicted it (default: `600`, the *server*'s own default ``server.evict``).
|
|
664
|
+
|
|
665
|
+
Set it to the upstream ``server.evict``. Past it, the relay warns that the results it
|
|
666
|
+
holds will likely be refused as stale (the upstream *server* has put those tasks back
|
|
667
|
+
for other *clients*), and it does not repeat a confirmation the outage cut off. The
|
|
668
|
+
results are still returned when the connection comes back.
|
|
669
|
+
|
|
670
|
+
``[tls]``
|
|
671
|
+
``.enabled``
|
|
672
|
+
Use TLS on the upstream connection (default: `true`).
|
|
673
|
+
|
|
674
|
+
See also ``--no-tls`` command-line option.
|
|
675
|
+
|
|
676
|
+
``.cert``
|
|
677
|
+
Upstream server certificate (default: `<auto>`).
|
|
678
|
+
|
|
679
|
+
``.cafile``
|
|
680
|
+
Trust anchor for the upstream server (default: `<auto>`).
|
|
681
|
+
|
|
682
|
+
``.fingerprint``
|
|
683
|
+
Pin the upstream server certificate fingerprint, e.g. ``SHA256:AB:CD:...``
|
|
684
|
+
(default: none).
|
|
685
|
+
|
|
520
686
|
``[console]``
|
|
521
687
|
Rich text display and output parameters.
|
|
522
688
|
|
|
@@ -129,6 +129,35 @@ See also the :ref:`command-line interface <cli_initdb>` for ``hs initdb``.
|
|
|
129
129
|
|
|
130
130
|
-------------------
|
|
131
131
|
|
|
132
|
+
Relay Database
|
|
133
|
+
--------------
|
|
134
|
+
|
|
135
|
+
|
|
|
136
|
+
|
|
137
|
+
A relay (``hs relay``) keeps its own database, apart from the one configured here. It is always a
|
|
138
|
+
private SQLite file, whatever ``[database]`` names (PostgreSQL included), and the configured database
|
|
139
|
+
is never opened by a relay process. It holds the tasks the relay has received and not yet finished,
|
|
140
|
+
their upstream assignments, and the results the relay holds until it has handed them back
|
|
141
|
+
(and for ``relay.retention`` seconds after), so it stays about the same size however long the relay
|
|
142
|
+
runs.
|
|
143
|
+
|
|
144
|
+
The file is ``relay.database`` (``--database``), by default ``<lib>/relay/<host>.db``: named for the
|
|
145
|
+
host, since a home directory is often shared between hosts. One relay uses a file at a time; a
|
|
146
|
+
second relay on the same file refuses to start (a lock file beside it, ``<file>.lock``, guards it).
|
|
147
|
+
|
|
148
|
+
Every insert of received tasks is committed with ``synchronous = FULL`` before the relay confirms
|
|
149
|
+
them upstream, so the file sees a steady stream of small, durable writes. Put it on a **node-local
|
|
150
|
+
disk** where the relay runs, not on a network filesystem: SQLite's locking is unreliable on many
|
|
151
|
+
network filesystems, and their latency slows each commit. WAL journaling is not turned on, for the
|
|
152
|
+
same reason; a node-local file may use it through ``[database] pragmas`` if wanted. A relay
|
|
153
|
+
restarted on the same file picks up where its earlier run stopped: results it still held go back
|
|
154
|
+
upstream, and tasks it was running run again at the site.
|
|
155
|
+
|
|
156
|
+
A relay given a configuration file with relay settings in it writes a copy for its site beside the
|
|
157
|
+
relay database (``<file>.site.toml``, readable by its owner only), removed when the relay ends.
|
|
158
|
+
|
|
159
|
+
-------------------
|
|
160
|
+
|
|
132
161
|
TimescaleDB
|
|
133
162
|
-----------
|
|
134
163
|
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
Run relay for one site.
|
|
2
|
+
|
|
3
|
+
A *relay* connects a site to an upstream *server*. Upstream it is an ordinary *client*; at
|
|
4
|
+
the site it runs its own *server*, scheduling the tasks it receives to *clients* it launches
|
|
5
|
+
there, and returns their results upstream.
|
|
6
|
+
|
|
7
|
+
Upstream, the relay requests work for its zone under an identity of its own, derived from the
|
|
8
|
+
relay and the zone name and logged when it starts. It holds at most about two rounds of work for its
|
|
9
|
+
site (twice its connected *clients* times its bundle size, ``relay.bundlesize``, which is never
|
|
10
|
+
below a *client*'s executor threads), asks for more once half of that is left, and then for the
|
|
11
|
+
whole difference at once. It confirms the tasks it receives only once they are stored in the relay
|
|
12
|
+
database. The upstream key comes from
|
|
13
|
+
``relay.upstream.auth`` (or its ``_env`` and ``_eval`` forms), never from the command line.
|
|
14
|
+
The key never reaches the site: before its first *client* is launched, the relay removes from its
|
|
15
|
+
own environment, which the site's *clients* and their tasks inherit, every relay setting
|
|
16
|
+
(``HYPERSHELL_RELAY_*``) and any variable holding the key. When ``HYPERSHELL_CONFIG_FILE`` names a
|
|
17
|
+
file that holds relay settings or the key, the site is given a copy of it instead, without the
|
|
18
|
+
``[relay]`` section and without any value holding the key, readable by its owner only, and kept
|
|
19
|
+
beside the relay database; the site's *clients* keep the file's other settings, ``[server.tls]``
|
|
20
|
+
among them. (If the file cannot be read, the site gets none.) The copy is removed when the relay
|
|
21
|
+
exits, however it ends: when it finishes, when it fails, and on SIGINT or SIGTERM. Only a relay
|
|
22
|
+
killed outright leaves it behind (by SIGKILL, or by a second SIGTERM while it ends, which ends the
|
|
23
|
+
process at once), and the next relay on the same relay database to need a copy writes over it. The relay refuses to start if the *client* command line (launcher, launcher
|
|
24
|
+
arguments or template) or a variable exported to tasks (``[export]``) would carry the key.
|
|
25
|
+
|
|
26
|
+
At the site the relay runs its tasks on the *clients* it launches there, with a key it mints for
|
|
27
|
+
each run. Each *client* receives that key in its environment (``HYPERSHELL_SERVER_AUTH``), never on
|
|
28
|
+
its command line, and passes it to none of its tasks, so the launcher must pass the environment
|
|
29
|
+
through to the *client*. A site *client* that stops sending heartbeats is evicted by the relay
|
|
30
|
+
after ``server.evict`` seconds, and the tasks it held are run again at the site. The site never
|
|
31
|
+
retries a task: one that fails goes back upstream as it
|
|
32
|
+
ended, and the upstream *server* decides whether to run it again. Each result goes back attributed to the *client*
|
|
33
|
+
at the site that ran it, matched to the assignment the upstream *server* made. Results are kept in
|
|
34
|
+
the relay database until they have been handed over, and for a while after (``relay.retention``).
|
|
35
|
+
The relay's heartbeat names its site (``relay.site``, by default the relay's host name) and lists the
|
|
36
|
+
*clients* connected at the site, by id and host only. The upstream *server* records them as its own
|
|
37
|
+
*clients*, attributed to the site and the relay, and counts them (not the relay) as connected. They
|
|
38
|
+
never heartbeat upstream themselves: they disconnect there when they leave the site, and all at once
|
|
39
|
+
when the relay finishes or is evicted.
|
|
40
|
+
A relay may serve several zones (``--zone`` given more than once, or ``relay.zone`` as a list or as
|
|
41
|
+
one ``[relay.zone.NAME]`` table per zone). Upstream it is then one *client* per zone, each under its
|
|
42
|
+
own identity, all over the same connection: it takes the zones in turn, and asks for each only as
|
|
43
|
+
much as that zone's own *clients* at the site have room for. At the site it keeps one fleet of
|
|
44
|
+
*clients* per zone, launched alike but each serving its own zone, with that zone's own launcher,
|
|
45
|
+
launcher arguments and size if its table gives them; the one relay-local *server* serves them all.
|
|
46
|
+
The first zone's identity lists every *client* at the site upstream. Each identity sends its own
|
|
47
|
+
heartbeat, so if the relay fails, the upstream *server* evicts each one and puts back what each
|
|
48
|
+
held, in every zone.
|
|
49
|
+
When the upstream *server* shuts down, the relay finishes the tasks it holds, returns every result,
|
|
50
|
+
and ends its upstream registration. It hears of the shutdown in reply to a request for work, in any of
|
|
51
|
+
its zones; a zone with no *client* at the site and no task held then ends with the others. A relay
|
|
52
|
+
with no *client* at the site in any zone never asks, so it waits until it is drained or stopped.
|
|
53
|
+
SIGUSR1 or SIGUSR2, sent to the relay process, drain it the same way: the relay stops asking for work, its site finishes every task the relay holds (those not yet started
|
|
54
|
+
too), and the results go back before the registration ends. SIGINT and SIGTERM end the relay at
|
|
55
|
+
once, without draining: it ends the *clients* it launched and exits (on SIGTERM, by that signal; a
|
|
56
|
+
second SIGTERM ends the process at once). If
|
|
57
|
+
the relay fails (a part of its own *server* stops, say, or the upstream *server* refuses it), it ends
|
|
58
|
+
the *clients* it launched and exits with a non-zero status. Either way the upstream *server* puts
|
|
59
|
+
back the tasks the relay held when it evicts the relay.
|
|
60
|
+
|
|
61
|
+
A lost upstream connection is not a failure. While the upstream *server* cannot be reached (a call
|
|
62
|
+
gets no answer within ``relay.upstream.deadline``), the site keeps running the tasks the relay holds,
|
|
63
|
+
their results are kept in the relay database, and the relay connects again with backoff (at most
|
|
64
|
+
``relay.upstream.backoff`` seconds apart). It logs the outage when it begins, now and then while it
|
|
65
|
+
lasts, and when it ends. Once connected again it sends a heartbeat first (the upstream *server*
|
|
66
|
+
registers it again if it had evicted it), then returns the results it holds, and only then asks for
|
|
67
|
+
more work. An outage shorter than the upstream eviction period (``relay.upstream.evict_hint``)
|
|
68
|
+
costs nothing: the results land. After a longer one, or after the upstream *server* restarted, the
|
|
69
|
+
upstream *server* has put those tasks back for other *clients*, so their results are refused as
|
|
70
|
+
stale and the tasks run again. A relay that is started while its upstream *server* cannot be reached
|
|
71
|
+
waits for it before it starts its site, and a relay restarted on the same relay database returns the
|
|
72
|
+
results its earlier run still held.
|
|
73
|
+
|
|
74
|
+
The relay database is always a private SQLite file, whatever database is configured, and the
|
|
75
|
+
configured database is never opened. One relay runs per process, and a second relay refuses to
|
|
76
|
+
start on the same relay database.
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
Options
|
|
2
|
+
^^^^^^^
|
|
3
|
+
|
|
4
|
+
``-H``, ``--upstream-host`` *ADDR*
|
|
5
|
+
Hostname or IP address of the upstream *server* (default: localhost).
|
|
6
|
+
|
|
7
|
+
See also ``relay.upstream.host``.
|
|
8
|
+
|
|
9
|
+
``-p``, ``--upstream-port`` *NUM*
|
|
10
|
+
Port number of the upstream *server* (default: 50001).
|
|
11
|
+
|
|
12
|
+
See also ``relay.upstream.port``.
|
|
13
|
+
|
|
14
|
+
``--no-tls``
|
|
15
|
+
Disable TLS on the connection to the upstream *server* (not recommended).
|
|
16
|
+
|
|
17
|
+
This affects only the upstream connection; the relay-local *server* keeps ``[server.tls]``.
|
|
18
|
+
See also ``relay.upstream.tls.enabled``.
|
|
19
|
+
|
|
20
|
+
``--zone`` *NAME*
|
|
21
|
+
Zone this relay serves (default: the default zone). Give it more than once to serve several.
|
|
22
|
+
|
|
23
|
+
The relay asks upstream only for tasks of the zones it serves, and keeps one fleet of
|
|
24
|
+
*clients* at the site for each zone (``-N`` *clients* each, unless the zone gives its own
|
|
25
|
+
``size``). Zones named here take the place of ``relay.zone``; each still takes its own
|
|
26
|
+
settings from ``[relay.zone.NAME]``. See also ``relay.zone``.
|
|
27
|
+
|
|
28
|
+
``-N``, ``--size`` *NUM*
|
|
29
|
+
Number of *clients* the relay keeps launched at its site (default: 1).
|
|
30
|
+
|
|
31
|
+
A *client* that exits is launched again. The size must be at least 1: with no *client* at the
|
|
32
|
+
site the relay would never ask upstream for work. See also ``relay.size``.
|
|
33
|
+
|
|
34
|
+
``--launcher`` *CMD*
|
|
35
|
+
Command prefix used to launch each *client* at the site (default: none).
|
|
36
|
+
|
|
37
|
+
With none, *clients* run directly on the relay's host. Otherwise each is launched as
|
|
38
|
+
``CMD [ARGS...] hyper-shell client ...`` (e.g., ``srun``). The *clients* connect back to the
|
|
39
|
+
relay by its host name. The launcher must pass the environment through: each *client*
|
|
40
|
+
receives the site key there (``HYPERSHELL_SERVER_AUTH``), never on its command line.
|
|
41
|
+
See also ``relay.launcher``.
|
|
42
|
+
|
|
43
|
+
``--launcher-args`` *ARGS*
|
|
44
|
+
Extra arguments for the launcher, placed after it (quoted as one argument).
|
|
45
|
+
|
|
46
|
+
See also ``relay.launcher_args``.
|
|
47
|
+
|
|
48
|
+
``--bind`` *ADDR*
|
|
49
|
+
Bind address of the relay-local *server* (default: 0.0.0.0).
|
|
50
|
+
|
|
51
|
+
The *clients* at the site connect to the relay here, so it must be reachable from the
|
|
52
|
+
nodes they run on. See also ``relay.bind``.
|
|
53
|
+
|
|
54
|
+
``--port`` *NUM*
|
|
55
|
+
Port of the relay-local *server* (default: 50002).
|
|
56
|
+
|
|
57
|
+
The default differs from the *server* default (50001), so a relay can run beside a
|
|
58
|
+
*server* on the same host. See also ``relay.port``.
|
|
59
|
+
|
|
60
|
+
``--database`` *PATH*
|
|
61
|
+
Path to the relay database (default: <lib>/relay/<host>.db).
|
|
62
|
+
|
|
63
|
+
The default is named for the host, since a home directory is often shared between hosts.
|
|
64
|
+
A node-local disk is a good place for it. See also ``relay.database``.
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
.. _cli_relay:
|
|
2
|
+
|
|
3
|
+
Relay
|
|
4
|
+
=====
|
|
5
|
+
|
|
6
|
+
Usage
|
|
7
|
+
-----
|
|
8
|
+
|
|
9
|
+
.. include:: ../_include/relay_usage.rst
|
|
10
|
+
|
|
11
|
+
Description
|
|
12
|
+
-----------
|
|
13
|
+
|
|
14
|
+
.. include:: ../_include/relay_desc.rst
|
|
15
|
+
|
|
16
|
+
|
|
|
17
|
+
|
|
18
|
+
.. include:: ../_include/relay_help.rst
|
|
19
|
+
|
|
20
|
+
What a relay does not do
|
|
21
|
+
------------------------
|
|
22
|
+
|
|
23
|
+
A relay moves work across a wide-area hop to a site the upstream *server* cannot reach directly, and
|
|
24
|
+
keeps it running when that hop fails. It is not meant for, and does not provide:
|
|
25
|
+
|
|
26
|
+
- **More throughput.** A relay adds a hop. Tasks run no faster at its site than they would on
|
|
27
|
+
*clients* connected straight to the upstream *server*; it holds at most about two rounds of work
|
|
28
|
+
per site *client*, so it never takes more than its site can run soon.
|
|
29
|
+
- **Cancellation or output retrieval across sites.** ``hs update`` on the upstream *server* does not
|
|
30
|
+
reach a task the relay already holds, and ``hs info --stdout`` / ``--stderr`` reads captured output
|
|
31
|
+
from the host that ran the task, which upstream may have no route to.
|
|
32
|
+
- **Autoscaling by site topology.** Each served zone's fleet has a fixed size (``-N``, or the zone's
|
|
33
|
+
own ``size``); the relay launches another *client* only when one exits.
|
|
34
|
+
- **Tolerance of clock skew.** The upstream *server* ages a relay's heartbeats by the relay's own
|
|
35
|
+
clock, so a relay host whose clock is far off the upstream *server*'s is evicted while alive (and
|
|
36
|
+
its tasks put back). Keep every relay host's clock synchronised with the upstream *server*'s.
|
|
37
|
+
|
|
38
|
+
A task cut for the relay upstream but not yet confirmed when the relay dies (or when its connection
|
|
39
|
+
drops) stays assigned upstream with no *client*; this window exists for every *client*, and is larger
|
|
40
|
+
for a relay by its bundle size.
|
|
@@ -19,6 +19,10 @@ hs server [-h] FILE ...
|
|
|
19
19
|
hs client [-h] ...
|
|
20
20
|
Run stand-alone client.
|
|
21
21
|
|
|
22
|
+
hs relay [-h] [-H ADDR] [-p NUM] [--no-tls] [--zone NAME] [-N NUM] [--launcher CMD]
|
|
23
|
+
[--launcher-args ARGS] [--bind ADDR] [--port NUM] [--database PATH]
|
|
24
|
+
Run relay for one site.
|
|
25
|
+
|
|
22
26
|
hs submit [-h] [ARGS... | -f FILE] ...
|
|
23
27
|
Submit one or more tasks.
|
|
24
28
|
|
|
@@ -88,6 +92,16 @@ Client Usage
|
|
|
88
92
|
.. include:: _include/client_help.rst
|
|
89
93
|
|
|
90
94
|
|
|
95
|
+
Relay Usage
|
|
96
|
+
-----------
|
|
97
|
+
|
|
98
|
+
.. include:: _include/relay_usage.rst
|
|
99
|
+
|
|
100
|
+
.. include:: _include/relay_desc.rst
|
|
101
|
+
|
|
102
|
+
.. include:: _include/relay_help.rst
|
|
103
|
+
|
|
104
|
+
|
|
91
105
|
Submit Usage
|
|
92
106
|
------------
|
|
93
107
|
|
|
@@ -235,9 +235,12 @@ key generators used in the deployment guides below satisfy this policy.
|
|
|
235
235
|
``HYPERSHELL_EXPORT_HYPERSHELL_SERVER_AUTH`` variable) hands every task a key the
|
|
236
236
|
operator holds, such as the key of a hand-started ``hs server``. Its values are taken
|
|
237
237
|
literally, so it cannot carry the key an ``hs cluster`` run mints, which no one is shown.
|
|
238
|
-
* A ``{= =}`` lambda pattern is Python
|
|
239
|
-
so ``os.environ`` there is
|
|
240
|
-
|
|
238
|
+
* A ``{= =}`` lambda pattern is Python evaluated, with ``os`` exposed, in the process that
|
|
239
|
+
expands the template, so ``os.environ`` there is that process's own environment. For a
|
|
240
|
+
client that ``hs cluster`` starts as a process of its own (through a launcher, ``--mpi``,
|
|
241
|
+
``--ssh`` or autoscaling), that includes ``HYPERSHELL_SERVER_AUTH``; under the default
|
|
242
|
+
local mode it holds the variable only if the environment that started ``hs cluster`` set
|
|
243
|
+
it (see :ref:`templates <templates>`). A template that reads it does so on purpose.
|
|
241
244
|
|
|
242
245
|
A task that runs a nested ``hs cluster`` needs neither: that run mints its own key for
|
|
243
246
|
its own server and clients.
|
|
@@ -492,6 +495,57 @@ and audit ``authorized_keys`` for unexpected entries.
|
|
|
492
495
|
|
|
493
496
|
-------------------
|
|
494
497
|
|
|
498
|
+
Relays
|
|
499
|
+
------
|
|
500
|
+
|
|
501
|
+
|
|
|
502
|
+
|
|
503
|
+
A relay (``hs relay``, see :ref:`cli_relay`) joins a site to an upstream *server* across a wide-area
|
|
504
|
+
network. It is a *client* upstream and a *server* at its site, so it stands between two
|
|
505
|
+
authentication domains, and each keeps its own key.
|
|
506
|
+
|
|
507
|
+
* **Upstream.** The relay authenticates to the upstream *server* with the upstream key, read from
|
|
508
|
+
``[relay.upstream]`` (``auth``, or its ``auth_env`` and ``auth_eval`` forms), never from
|
|
509
|
+
``[server]`` and never from the relay's command line: there is no upstream ``-k`` option. The
|
|
510
|
+
connection uses TLS, configured by ``[relay.upstream.tls]`` alone, so the site keeps the relay's
|
|
511
|
+
own ``[server.tls]``. Across a wide-area hop, verify the upstream *server*: give
|
|
512
|
+
``relay.upstream.tls.cafile`` (a certificate authority, or the upstream *server*'s own
|
|
513
|
+
certificate) or pin its ``relay.upstream.tls.fingerprint``. ``--no-tls`` turns TLS off on this
|
|
514
|
+
hop only, with a warning; do not use it outside a trusted network.
|
|
515
|
+
|
|
516
|
+
* **At the site.** The relay-local *server* mints a fresh key for each run, as an autoscaling
|
|
517
|
+
``hs cluster`` does, and hands it to each site *client* in its environment
|
|
518
|
+
(``HYPERSHELL_SERVER_AUTH``), never on its command line, as described under
|
|
519
|
+
*How cluster launches hand the key to their clients* above. The launcher must pass the
|
|
520
|
+
environment through. A site *client* passes that key to none of its tasks.
|
|
521
|
+
|
|
522
|
+
* **The upstream key stays in the relay process.** Site *clients* inherit the relay's environment,
|
|
523
|
+
and tasks their *client*'s, so before the first site *client* starts the relay removes from its own
|
|
524
|
+
environment every relay setting (``HYPERSHELL_RELAY_*``) and every variable whose name or value
|
|
525
|
+
holds the upstream key. When ``HYPERSHELL_CONFIG_FILE`` names a file with relay settings or the key
|
|
526
|
+
in it, the site is given a copy without them (readable by its owner only, beside the relay
|
|
527
|
+
database, and removed when the relay ends; a relay ended by SIGKILL, or by a second SIGTERM while
|
|
528
|
+
it ends, leaves it behind, and the next relay on that database writes over it). The relay refuses
|
|
529
|
+
to start if a site *client*'s command line (launcher, launcher arguments or template), or a
|
|
530
|
+
variable exported to tasks (``[export]``), would carry the upstream key. This holds for every zone
|
|
531
|
+
a relay serves: each zone's *clients* are launched the same way.
|
|
532
|
+
|
|
533
|
+
* **What the fence cannot cover.** It governs what the relay hands on: command lines and
|
|
534
|
+
environments. A site *client* on a host that reads the same user or system configuration file as
|
|
535
|
+
the relay reads whatever ``[relay.upstream]`` holds there. Keep a literal upstream key out of a
|
|
536
|
+
shared configuration file: use ``auth_env`` or ``auth_eval``, or give the relay a configuration
|
|
537
|
+
file of its own through ``HYPERSHELL_CONFIG_FILE``.
|
|
538
|
+
|
|
539
|
+
* **The roster.** A relay lists its site *clients* upstream by id and host only. Upstream they are
|
|
540
|
+
attributed to the relay's site and the relay; a roster never claims a *client* of another relay.
|
|
541
|
+
|
|
542
|
+
A relay keeps its own SQLite database (see :ref:`database`); it holds the tasks the relay received
|
|
543
|
+
and their results until they are handed back, so protect it as you would the task database.
|
|
544
|
+
|
|
545
|
+
|
|
|
546
|
+
|
|
547
|
+
-------------------
|
|
548
|
+
|
|
495
549
|
Deployment Guides
|
|
496
550
|
-----------------
|
|
497
551
|
|
|
@@ -54,7 +54,7 @@ function _hs_complete_tags() {
|
|
|
54
54
|
function _hs() {
|
|
55
55
|
|
|
56
56
|
local current="${COMP_WORDS[COMP_CWORD]}"
|
|
57
|
-
local all_opts="cluster server client submit initdb info wait run list update config -h --help -v --version --citation"
|
|
57
|
+
local all_opts="cluster server client relay submit initdb info wait run list update config -h --help -v --version --citation"
|
|
58
58
|
|
|
59
59
|
local i=1 cmd=
|
|
60
60
|
while [[ "${i}" -lt "${COMP_CWORD}" ]]
|
|
@@ -83,6 +83,7 @@ function _hs() {
|
|
|
83
83
|
submit) _hs_submit ;;
|
|
84
84
|
server) _hs_server ;;
|
|
85
85
|
client) _hs_client ;;
|
|
86
|
+
relay) _hs_relay ;;
|
|
86
87
|
cluster) _hs_cluster ;;
|
|
87
88
|
info) _hs_task_info ;;
|
|
88
89
|
wait) _hs_task_wait ;;
|
|
@@ -605,6 +606,30 @@ function _hs_client() {
|
|
|
605
606
|
}
|
|
606
607
|
|
|
607
608
|
|
|
609
|
+
# ---------------------------------------------------------------------------
|
|
610
|
+
# relay
|
|
611
|
+
# ---------------------------------------------------------------------------
|
|
612
|
+
|
|
613
|
+
function _hs_relay() {
|
|
614
|
+
local current="${COMP_WORDS[COMP_CWORD]}"
|
|
615
|
+
local previous="${COMP_WORDS[COMP_CWORD - 1]}"
|
|
616
|
+
local all_opts="-h --help -H --upstream-host -p --upstream-port --no-tls --zone -N --size
|
|
617
|
+
--launcher --launcher-args --bind --port --database"
|
|
618
|
+
|
|
619
|
+
case "${previous}" in
|
|
620
|
+
--database) COMPREPLY=($(compgen -f -- "${current}")); return ;;
|
|
621
|
+
--launcher) COMPREPLY=($(compgen -c -- "${current}")); return ;;
|
|
622
|
+
--zone | -N | --size | --launcher-args) return ;;
|
|
623
|
+
--bind) COMPREPLY=($(compgen -W "0.0.0.0 localhost 127.0.0.1" -- "${current}")); return ;;
|
|
624
|
+
--port) COMPREPLY=($(compgen -W "$(hs config get relay.port --raw 2>/dev/null)" -- "${current}")); return ;;
|
|
625
|
+
-H | --upstream-host) COMPREPLY=($(compgen -W "$(_hs_known_hosts)" -- "${current}")); return ;;
|
|
626
|
+
-p | --upstream-port) COMPREPLY=($(compgen -W "$(hs config get relay.upstream.port --raw 2>/dev/null)" -- "${current}")); return ;;
|
|
627
|
+
esac
|
|
628
|
+
|
|
629
|
+
COMPREPLY=($(compgen -W "${all_opts}" -- "${current}"))
|
|
630
|
+
}
|
|
631
|
+
|
|
632
|
+
|
|
608
633
|
# ---------------------------------------------------------------------------
|
|
609
634
|
# server
|
|
610
635
|
# ---------------------------------------------------------------------------
|