mage-ai 0.9.47__py3-none-any.whl → 0.9.48__py3-none-any.whl
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.
Potentially problematic release.
This version of mage-ai might be problematic. Click here for more details.
- mage_ai/api/presenters/PipelinePresenter.py +1 -0
- mage_ai/data_preparation/executors/block_executor.py +21 -1
- mage_ai/data_preparation/executors/pipeline_executor.py +19 -4
- mage_ai/data_preparation/models/block/__init__.py +50 -20
- mage_ai/data_preparation/models/block/data_integration/mixins.py +6 -6
- mage_ai/data_preparation/models/block/data_integration/utils.py +2 -2
- mage_ai/data_preparation/models/block/sql/bigquery.py +2 -2
- mage_ai/data_preparation/models/block/sql/snowflake.py +2 -2
- mage_ai/data_preparation/models/block/sql/trino.py +2 -2
- mage_ai/data_preparation/models/block/sql/utils/shared.py +2 -2
- mage_ai/data_preparation/models/block/utils.py +25 -16
- mage_ai/data_preparation/models/pipeline.py +5 -0
- mage_ai/data_preparation/models/project/__init__.py +0 -2
- mage_ai/io/chroma.py +13 -4
- mage_ai/orchestration/db/models/schedules.py +71 -0
- mage_ai/orchestration/pipeline_scheduler.py +1 -70
- mage_ai/server/constants.py +1 -1
- mage_ai/server/frontend_dist/404.html +2 -2
- mage_ai/server/frontend_dist/_next/static/chunks/1952-0f9a12782f0aaae6.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/2717-14191a781cf2f286.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/3419-a7a52bcaaa687b07.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/3437-e81a62f33337ca06.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/3943-3cb1f765210dd7a4.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/4138-2c16e6d2f22246cd.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/{5499-76cf8f023c6b0985.js → 5499-c2853ef57d39fde8.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/6990-303bb87fc50f1755.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/{7858-d9df72e95e438284.js → 7858-26a5a5d04fa3c703.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/8264-9d6a7cea289e29ff.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/8487-608d62c0eef1f29a.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/{1845-5ce774d5ab81ed57.js → 8731-2f78ec7b7760be8f.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/90-93d18aaecef0685b.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/{9264-cc44b07f248707b0.js → 9264-727704fc34e74ae0.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/9624-48fba6b4e6966fb7.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/{_app-78c4a077a2f279c2.js → _app-8254de4f793643d0.js} +1 -1
- mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/block-layout-a24cb24b6f08bbc9.js → frontend_dist/_next/static/chunks/pages/block-layout-b926f6eb1ee9a53b.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/compute-a9402b51e9fe748e.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/{files-b37d221eb5ddc248.js → files-85cecae037fd7a70.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/global-data-products/{[...slug]-cfd68e760ae00958.js → [...slug]-c3c9523ea8072c11.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/{global-data-products-c3b79ef31007f95b.js → global-data-products-4d046f15202a1c8d.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/global-hooks/{[...slug]-7adc543fc490367a.js → [...slug]-286133386c97a2b6.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/global-hooks-3da370825153056c.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/manage/{files-fe6e73463a20d67c.js → files-39b73da5a15590f6.js} +1 -1
- mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/manage/settings-60845f0b59142f32.js → frontend_dist/_next/static/chunks/pages/manage/settings-666748ff5d101411.js} +1 -1
- mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/manage/users/[user]-9384c5f1efa2ac18.js → frontend_dist/_next/static/chunks/pages/manage/users/[user]-be27631e67dbe070.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/manage/users/{new-abd8571907664fdf.js → new-1932ce64823b372b.js} +1 -1
- mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/manage/users-28a930b148d99766.js → frontend_dist/_next/static/chunks/pages/manage/users-ed509c75cf23f0f5.js} +1 -1
- mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/manage-d8a38b5d1f50e798.js → frontend_dist/_next/static/chunks/pages/manage-1feebec1124123fc.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/{oauth-8bb62c4f6a511c43.js → oauth-e9b8f19c30381c28.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/{overview-f0c40645f385f23f.js → overview-7b2ba2d5405c05fe.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipeline-runs-70fc3351bd11025f.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-6ee3b88a5bb4ce94.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills-c9cf383bc13ce7b8.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/{dashboard-571c0962333b92f0.js → dashboard-7bca6f718b939934.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/edit-c119f630038b0685.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/logs-146051325c92d742.js +1 -0
- mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runs-ddddcddd2f74b4f6.js → frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runs-15d307e6ba934a56.js} +1 -1
- mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runtime-4a238307feddb522.js → frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runtime-f6196e563b960e5c.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/{monitors-6d1afeb4a84f50f7.js → monitors-25dbd73201d99e80.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-06e55db757959ef8.js +1 -0
- mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/runs-2d20b2cd08907afd.js → frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs-ec3c45cfa027db58.js} +1 -1
- mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/settings-11363aa58d51f4e1.js → frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/settings-495e877aa7ed709e.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/syncs-49adfeed5157d92b.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-6143e028225390f5.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers-0886f6320fef7131.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines-e82a763d742cc034.js +1 -0
- mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/settings/account/profile-3c8f062913c66f3e.js → frontend_dist/_next/static/chunks/pages/settings/account/profile-50d20fa715d454af.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/permissions/{[...slug]-b78b1be5b9ed84b9.js → [...slug]-2bbd63b7e93a8600.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/{permissions-37b78a436eeab258.js → permissions-4ea156c39608caab.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/preferences-f3c29ec53ee35795.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/roles/{[...slug]-db05a80d18c168e5.js → [...slug]-64ec8928d2542f3c.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/{roles-f55c77e4f46c8d33.js → roles-835e6ec2a48ec583.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/{sync-data-2a1f8737561fdd94.js → sync-data-0769149af025de30.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/users/{[...slug]-e3bf6e5d8bb250c4.js → [...slug]-612a65c42bcadef0.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/{users-20f0a050a42a015d.js → users-e3365b4029a8db33.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/{sign-in-99e2748e3c1d57a3.js → sign-in-f3a33e8f83abdb58.js} +1 -1
- mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/templates/[...slug]-f44ccd1499ffd23a.js → frontend_dist/_next/static/chunks/pages/templates/[...slug]-f264097bf8120f31.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/{templates-1bfaa1c50e844813.js → templates-406e13cc5c4caab4.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/{terminal-ed121e305169cf1c.js → terminal-ef8ad878e5e7bb2f.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/triggers-a90728798f964700.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/{version-control-dd4fb405695f74bf.js → version-control-0e0c2713a2922be7.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/xxcdnITr3IkTdETH5ghqw/_buildManifest.js +1 -0
- mage_ai/server/frontend_dist/block-layout.html +2 -2
- mage_ai/server/frontend_dist/compute.html +5 -5
- mage_ai/server/frontend_dist/files.html +5 -5
- mage_ai/server/frontend_dist/global-data-products/[...slug].html +5 -5
- mage_ai/server/frontend_dist/global-data-products.html +5 -5
- mage_ai/server/frontend_dist/global-hooks/[...slug].html +5 -5
- mage_ai/server/frontend_dist/global-hooks.html +5 -5
- mage_ai/server/frontend_dist/index.html +2 -2
- mage_ai/server/frontend_dist/manage/files.html +5 -5
- mage_ai/server/frontend_dist/manage/settings.html +5 -5
- mage_ai/server/frontend_dist/manage/users/[user].html +5 -5
- mage_ai/server/frontend_dist/manage/users/new.html +5 -5
- mage_ai/server/frontend_dist/manage/users.html +5 -5
- mage_ai/server/frontend_dist/manage.html +5 -5
- mage_ai/server/frontend_dist/oauth.html +3 -3
- mage_ai/server/frontend_dist/overview.html +5 -5
- mage_ai/server/frontend_dist/pipeline-runs.html +5 -5
- mage_ai/server/frontend_dist/pipelines/[pipeline]/backfills/[...slug].html +5 -5
- mage_ai/server/frontend_dist/pipelines/[pipeline]/backfills.html +5 -5
- mage_ai/server/frontend_dist/pipelines/[pipeline]/dashboard.html +5 -5
- mage_ai/server/frontend_dist/pipelines/[pipeline]/edit.html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/logs.html +5 -5
- mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors/block-runs.html +5 -5
- mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors/block-runtime.html +5 -5
- mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors.html +5 -5
- mage_ai/server/frontend_dist/pipelines/[pipeline]/runs/[run].html +5 -5
- mage_ai/server/frontend_dist/pipelines/[pipeline]/runs.html +5 -5
- mage_ai/server/frontend_dist/pipelines/[pipeline]/settings.html +5 -5
- mage_ai/server/frontend_dist/pipelines/[pipeline]/syncs.html +5 -5
- mage_ai/server/frontend_dist/pipelines/[pipeline]/triggers/[...slug].html +5 -5
- mage_ai/server/frontend_dist/pipelines/[pipeline]/triggers.html +5 -5
- mage_ai/server/frontend_dist/pipelines/[pipeline].html +2 -2
- mage_ai/server/frontend_dist/pipelines.html +5 -5
- mage_ai/server/frontend_dist/settings/account/profile.html +5 -5
- mage_ai/server/frontend_dist/settings/workspace/permissions/[...slug].html +5 -5
- mage_ai/server/frontend_dist/settings/workspace/permissions.html +5 -5
- mage_ai/server/frontend_dist/settings/workspace/preferences.html +5 -5
- mage_ai/server/frontend_dist/settings/workspace/roles/[...slug].html +5 -5
- mage_ai/server/frontend_dist/settings/workspace/roles.html +5 -5
- mage_ai/server/frontend_dist/settings/workspace/sync-data.html +5 -5
- mage_ai/server/frontend_dist/settings/workspace/users/[...slug].html +5 -5
- mage_ai/server/frontend_dist/settings/workspace/users.html +5 -5
- mage_ai/server/frontend_dist/settings.html +2 -2
- mage_ai/server/frontend_dist/sign-in.html +11 -11
- mage_ai/server/frontend_dist/templates/[...slug].html +5 -5
- mage_ai/server/frontend_dist/templates.html +5 -5
- mage_ai/server/frontend_dist/terminal.html +5 -5
- mage_ai/server/frontend_dist/test.html +4 -4
- mage_ai/server/frontend_dist/triggers.html +5 -5
- mage_ai/server/frontend_dist/version-control.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/404.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/1952-0f9a12782f0aaae6.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/2717-14191a781cf2f286.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3419-a7a52bcaaa687b07.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3437-e81a62f33337ca06.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3943-3cb1f765210dd7a4.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/4138-2c16e6d2f22246cd.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/{5499-76cf8f023c6b0985.js → 5499-c2853ef57d39fde8.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/6990-303bb87fc50f1755.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/{7858-d9df72e95e438284.js → 7858-26a5a5d04fa3c703.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/8264-9d6a7cea289e29ff.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/8487-608d62c0eef1f29a.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/{1845-5ce774d5ab81ed57.js → 8731-2f78ec7b7760be8f.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/90-93d18aaecef0685b.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/{9264-cc44b07f248707b0.js → 9264-727704fc34e74ae0.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/9624-48fba6b4e6966fb7.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/{_app-78c4a077a2f279c2.js → _app-8254de4f793643d0.js} +1 -1
- mage_ai/server/{frontend_dist/_next/static/chunks/pages/block-layout-a24cb24b6f08bbc9.js → frontend_dist_base_path_template/_next/static/chunks/pages/block-layout-b926f6eb1ee9a53b.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/compute-a9402b51e9fe748e.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/{files-b37d221eb5ddc248.js → files-85cecae037fd7a70.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/global-data-products/{[...slug]-cfd68e760ae00958.js → [...slug]-c3c9523ea8072c11.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/{global-data-products-c3b79ef31007f95b.js → global-data-products-4d046f15202a1c8d.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/global-hooks/{[...slug]-7adc543fc490367a.js → [...slug]-286133386c97a2b6.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/global-hooks-3da370825153056c.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/manage/{files-fe6e73463a20d67c.js → files-39b73da5a15590f6.js} +1 -1
- mage_ai/server/{frontend_dist/_next/static/chunks/pages/manage/settings-60845f0b59142f32.js → frontend_dist_base_path_template/_next/static/chunks/pages/manage/settings-666748ff5d101411.js} +1 -1
- mage_ai/server/{frontend_dist/_next/static/chunks/pages/manage/users/[user]-9384c5f1efa2ac18.js → frontend_dist_base_path_template/_next/static/chunks/pages/manage/users/[user]-be27631e67dbe070.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/manage/users/{new-abd8571907664fdf.js → new-1932ce64823b372b.js} +1 -1
- mage_ai/server/{frontend_dist/_next/static/chunks/pages/manage/users-28a930b148d99766.js → frontend_dist_base_path_template/_next/static/chunks/pages/manage/users-ed509c75cf23f0f5.js} +1 -1
- mage_ai/server/{frontend_dist/_next/static/chunks/pages/manage-d8a38b5d1f50e798.js → frontend_dist_base_path_template/_next/static/chunks/pages/manage-1feebec1124123fc.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/{oauth-8bb62c4f6a511c43.js → oauth-e9b8f19c30381c28.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/{overview-f0c40645f385f23f.js → overview-7b2ba2d5405c05fe.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipeline-runs-70fc3351bd11025f.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-6ee3b88a5bb4ce94.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills-c9cf383bc13ce7b8.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/{dashboard-571c0962333b92f0.js → dashboard-7bca6f718b939934.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/edit-c119f630038b0685.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/logs-146051325c92d742.js +1 -0
- mage_ai/server/{frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runs-ddddcddd2f74b4f6.js → frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runs-15d307e6ba934a56.js} +1 -1
- mage_ai/server/{frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runtime-4a238307feddb522.js → frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runtime-f6196e563b960e5c.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/{monitors-6d1afeb4a84f50f7.js → monitors-25dbd73201d99e80.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-06e55db757959ef8.js +1 -0
- mage_ai/server/{frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs-2d20b2cd08907afd.js → frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/runs-ec3c45cfa027db58.js} +1 -1
- mage_ai/server/{frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/settings-11363aa58d51f4e1.js → frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/settings-495e877aa7ed709e.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/syncs-49adfeed5157d92b.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-6143e028225390f5.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers-0886f6320fef7131.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines-e82a763d742cc034.js +1 -0
- mage_ai/server/{frontend_dist/_next/static/chunks/pages/settings/account/profile-3c8f062913c66f3e.js → frontend_dist_base_path_template/_next/static/chunks/pages/settings/account/profile-50d20fa715d454af.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/permissions/{[...slug]-b78b1be5b9ed84b9.js → [...slug]-2bbd63b7e93a8600.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/{permissions-37b78a436eeab258.js → permissions-4ea156c39608caab.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/preferences-f3c29ec53ee35795.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/roles/{[...slug]-db05a80d18c168e5.js → [...slug]-64ec8928d2542f3c.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/{roles-f55c77e4f46c8d33.js → roles-835e6ec2a48ec583.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/{sync-data-2a1f8737561fdd94.js → sync-data-0769149af025de30.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/users/{[...slug]-e3bf6e5d8bb250c4.js → [...slug]-612a65c42bcadef0.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/{users-20f0a050a42a015d.js → users-e3365b4029a8db33.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/{sign-in-99e2748e3c1d57a3.js → sign-in-f3a33e8f83abdb58.js} +1 -1
- mage_ai/server/{frontend_dist/_next/static/chunks/pages/templates/[...slug]-f44ccd1499ffd23a.js → frontend_dist_base_path_template/_next/static/chunks/pages/templates/[...slug]-f264097bf8120f31.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/{templates-1bfaa1c50e844813.js → templates-406e13cc5c4caab4.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/{terminal-ed121e305169cf1c.js → terminal-ef8ad878e5e7bb2f.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/triggers-a90728798f964700.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/{version-control-dd4fb405695f74bf.js → version-control-0e0c2713a2922be7.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/gDn6inKdLyj35NvURBSCV/_buildManifest.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/block-layout.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/compute.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/files.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/global-data-products/[...slug].html +5 -5
- mage_ai/server/frontend_dist_base_path_template/global-data-products.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/global-hooks/[...slug].html +5 -5
- mage_ai/server/frontend_dist_base_path_template/global-hooks.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/index.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/manage/files.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/manage/settings.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/manage/users/[user].html +5 -5
- mage_ai/server/frontend_dist_base_path_template/manage/users/new.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/manage/users.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/manage.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/oauth.html +3 -3
- mage_ai/server/frontend_dist_base_path_template/overview.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipeline-runs.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/backfills/[...slug].html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/backfills.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/dashboard.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/edit.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/logs.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/monitors/block-runs.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/monitors/block-runtime.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/monitors.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/runs/[run].html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/runs.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/settings.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/syncs.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/triggers/[...slug].html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/triggers.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline].html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/settings/account/profile.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/permissions/[...slug].html +5 -5
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/permissions.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/preferences.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/roles/[...slug].html +5 -5
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/roles.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/sync-data.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/users/[...slug].html +5 -5
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/users.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/settings.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/sign-in.html +10 -10
- mage_ai/server/frontend_dist_base_path_template/templates/[...slug].html +5 -5
- mage_ai/server/frontend_dist_base_path_template/templates.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/terminal.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/test.html +4 -4
- mage_ai/server/frontend_dist_base_path_template/triggers.html +5 -5
- mage_ai/server/frontend_dist_base_path_template/version-control.html +5 -5
- mage_ai/server/server.py +2 -0
- mage_ai/streaming/sources/nats_js.py +12 -1
- mage_ai/tests/data_preparation/executors/test_block_executor.py +2 -0
- mage_ai/tests/data_preparation/models/test_pipeline.py +5 -0
- {mage_ai-0.9.47.dist-info → mage_ai-0.9.48.dist-info}/METADATA +3 -3
- {mage_ai-0.9.47.dist-info → mage_ai-0.9.48.dist-info}/RECORD +257 -257
- mage_ai/server/frontend_dist/_next/static/N3FS4bHv0jpYeeg672uYK/_buildManifest.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/1952-57858e7445d24413.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/2717-92cdffd87b6f6e05.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/3419-715ca383fa15a5ef.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/3437-b4d6a037cf5781f8.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/3943-c9fb980f03df6450.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/600-705fe234320ec5de.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/722-900f786d24f91b2e.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/8264-0d582a6ca33c3dfa.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/8487-8e1c09546dff4dbf.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/90-a7308bae028d7001.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/9624-334e7db5c84cb4ea.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/compute-419775ca1293b354.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/global-hooks-51d366993f6dd449.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipeline-runs-b35d37bfba8fbccc.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-9adc2974aada27ba.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills-51b1311dff2a974e.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/edit-2333e524d34b474a.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/logs-ef680455ae54ccbe.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-1ff9bb8e22ca1e75.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/syncs-b75bf17498e87354.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-779c3ef0676a12ac.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers-bbea9a088657404a.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines-3737f2b0afc2ede3.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/preferences-c1f4ed17d501ccca.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/triggers-8bdd858240d5dbf6.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/aoO6jYZLVlUGCCdY-wmy8/_buildManifest.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/1952-57858e7445d24413.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/2717-92cdffd87b6f6e05.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3419-715ca383fa15a5ef.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3437-b4d6a037cf5781f8.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3943-c9fb980f03df6450.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/600-705fe234320ec5de.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/722-900f786d24f91b2e.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/8264-0d582a6ca33c3dfa.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/8487-8e1c09546dff4dbf.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/90-a7308bae028d7001.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/9624-334e7db5c84cb4ea.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/compute-419775ca1293b354.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/global-hooks-51d366993f6dd449.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipeline-runs-b35d37bfba8fbccc.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-9adc2974aada27ba.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills-51b1311dff2a974e.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/edit-2333e524d34b474a.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/logs-ef680455ae54ccbe.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-1ff9bb8e22ca1e75.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/syncs-b75bf17498e87354.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-779c3ef0676a12ac.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers-bbea9a088657404a.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines-3737f2b0afc2ede3.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/preferences-c1f4ed17d501ccca.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/triggers-8bdd858240d5dbf6.js +0 -1
- /mage_ai/server/frontend_dist/_next/static/{N3FS4bHv0jpYeeg672uYK → xxcdnITr3IkTdETH5ghqw}/_ssgManifest.js +0 -0
- /mage_ai/server/frontend_dist_base_path_template/_next/static/{aoO6jYZLVlUGCCdY-wmy8 → gDn6inKdLyj35NvURBSCV}/_ssgManifest.js +0 -0
- {mage_ai-0.9.47.dist-info → mage_ai-0.9.48.dist-info}/LICENSE +0 -0
- {mage_ai-0.9.47.dist-info → mage_ai-0.9.48.dist-info}/WHEEL +0 -0
- {mage_ai-0.9.47.dist-info → mage_ai-0.9.48.dist-info}/entry_points.txt +0 -0
- {mage_ai-0.9.47.dist-info → mage_ai-0.9.48.dist-info}/top_level.txt +0 -0
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4913],{78688:function(e,n,t){"use strict";var r=t(82394),i=t(82684),l=t(15338),o=t(77456),c=t(97618),s=t(55485),u=t(85854),a=t(65956),d=t(38276),p=t(30160),f=t(72473),v=t(70515),m=t(74778),h=t(74260),j=t(81728),x=t(28598);function g(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function Z(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?g(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):g(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}n.Z=function(e){var n=e.contained,t=void 0===n||n,r=e.onClickStep,g=e.setupSteps,b=e.small,P=(0,i.useCallback)((function(e,n,i,g){var y=e.name,_=e.description,k=e.group,O=e.error,C=e.required,I=e.status_calculated,S=e.steps,E=e.tab,w=e.uuid,T=(null===S||void 0===S?void 0:S.length)||0,D=g||{completedGroup:!1,level:0,numberEl:null},M=D.completedGroup,A=D.level,R=D.numberEl,B=0===A?2*v.iI:1.5*v.iI;if(k){var N=(0,x.jsxs)(x.Fragment,{children:[(0,x.jsx)(d.Z,{p:v.cd,children:(0,x.jsx)(s.ZP,{children:(0,x.jsxs)(c.Z,{flex:1,flexDirection:"column",children:[(0,x.jsxs)(s.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,x.jsx)(u.Z,{level:b?5:4,children:y}),(0,x.jsx)(d.Z,{mr:v.cd}),h.br.COMPLETED===I&&(0,x.jsx)(f.Jr,{size:B,success:!0})]}),_&&(0,x.jsx)(d.Z,{mt:1,children:(0,x.jsx)(p.ZP,{default:!0,small:b,children:_})})]})})}),(0,x.jsx)(l.Z,{light:!0}),null===S||void 0===S?void 0:S.map((function(e,n){return P(e,n,T,{completedGroup:h.br.COMPLETED===I,level:0})}))]});return(0,x.jsxs)(d.Z,{mb:b?0:v.cd,children:[t&&(0,x.jsx)(a.Z,{noPadding:!0,children:N}),!t&&N]},w)}var F=h.br.COMPLETED===I,z=0===A?String(n+1):(0,j.bH)()[n].toLowerCase();var H=!!E&&r,L=(0,x.jsx)(d.Z,{pl:0===A?v.cd:0,children:(0,x.jsxs)(p.ZP,{large:!b,monospace:!0,muted:!0,children:[z,"."]})}),W={muted:F||M,strikethrough:F||M};return(0,x.jsx)(m.aw,{clickable:!!H,onClick:H?function(){return null===r||void 0===r?void 0:r(E)}:null,children:(0,x.jsxs)(d.Z,{py:0!==A||b?1:v.cd,children:[(0,x.jsxs)(s.ZP,{children:[R&&(0,x.jsxs)(x.Fragment,{children:[(0,x.jsx)("div",{style:{opacity:0},children:R}),(0,x.jsx)(d.Z,{mr:1})]}),L,(0,x.jsx)(d.Z,{mr:1}),(0,x.jsx)(c.Z,{flex:1,flexDirection:"column",children:(0,x.jsxs)(s.ZP,{flexDirection:"column",children:[(0,x.jsxs)(s.ZP,{alignItems:"center",children:[(0,x.jsxs)(c.Z,{flex:1,children:[0===A&&!b&&(0,x.jsx)(u.Z,Z(Z({level:5},W),{},{children:y})),0===A&&b&&(0,x.jsx)(p.ZP,Z(Z({bold:!0,large:!0},W),{},{children:y})),A>=1&&(0,x.jsx)(p.ZP,Z(Z({bold:!0,large:!b},W),{},{children:y})),!C&&(0,x.jsxs)(x.Fragment,{children:[(0,x.jsx)(d.Z,{mr:1}),(0,x.jsx)(p.ZP,{muted:!0,uppercase:!0,xsmall:!0,children:"optional"})]})]}),(0,x.jsx)(d.Z,{mr:v.cd}),F&&(0,x.jsx)(f.Jr,{size:B,success:!0}),h.br.INCOMPLETE===I&&(0,x.jsx)(f.uy,{muted:!0,size:B}),h.br.ERROR===I&&(0,x.jsx)(f.uy,{danger:!0,size:B}),(0,x.jsx)(d.Z,{pr:v.cd*(I?1:2)})]}),_&&(0,x.jsx)(d.Z,{mt:1,pr:3*v.cd,children:(0,x.jsx)(p.ZP,Z(Z({default:!0},W),{},{small:b,children:_}))}),O&&(0,x.jsx)(o.Z,{error:O,small:!0,warning:!0})]})})]}),T>=1&&(0,x.jsx)(d.Z,{mt:1,children:null===S||void 0===S?void 0:S.map((function(e,n){return P(e,n,T,{completedGroup:M,level:1,numberEl:L})}))})]})},w)}),[t,r,b]),y=[],_=(null===g||void 0===g?void 0:g.length)||0;return null===g||void 0===g||g.forEach((function(e,n){e.status;y.push(P(e,n,_))})),t?(0,x.jsx)(d.Z,{p:v.cd,children:y}):(0,x.jsx)(x.Fragment,{children:y})}},89308:function(e,n,t){"use strict";var r=t(82394),i=t(75582),l=t(82684),o=t(69864),c=t(71180),s=t(26032),u=t(74260),a=t(15338),d=t(97618),p=t(55485),f=t(85854),v=t(65956),m=t(78688),h=t(38276),j=t(30160),x=t(35686),g=t(70515),Z=t(72473),b=t(81728),P=t(10332),y=t(72619),_=t(23780),k=t(28598);function O(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function C(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?O(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):O(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}n.Z=function(e){var n=e.actionsOnly,t=e.computeService,r=e.computeConnections,O=e.contained,I=void 0===O||O,S=e.fetchAll,E=e.hideDetails,w=e.onClickStep,T=e.small,D=(0,_.VI)(null,{},[],{uuid:"ConnectionSettings"}),M=(0,i.Z)(D,1)[0],A=(0,l.useState)(null),R=A[0],B=A[1],N=(0,l.useState)(null),F=N[0],z=N[1],H=(0,o.Db)((function(e){var n=e.action,r=e.uuid;return x.ZP.compute_connections.compute_services.useUpdate(null===t||void 0===t?void 0:t.uuid,r)({compute_connection:{action:n}})}),{onSuccess:function(e){return(0,y.wD)(e,{callback:function(e){var n=e.compute_connection;null===S||void 0===S||S(),z(C(C({},R),{},{computeConnection:n}))},onErrorCallback:function(e,n){return M({errors:n,response:e})}})}}),L=(0,i.Z)(H,2),W=L[0],U=L[1].isLoading;return(0,l.useEffect)((function(){if(F){var e,n=null===r||void 0===r?void 0:r.find((function(e){var n,t=e.uuid;return(null===F||void 0===F||null===(n=F.computeConnection)||void 0===n?void 0:n.uuid)===t}));(null===n||void 0===n?void 0:n.state)!==(null===F||void 0===F||null===(e=F.computeConnection)||void 0===e?void 0:e.state)&&z(null)}}),[r,F,z]),(0,k.jsx)(h.Z,{py:I?g.cd:0,children:null===r||void 0===r?void 0:r.map((function(e,t){var r,l,o,x,y=e.actions,_=e.attributes,O=e.connection,C=e.description,S=e.name,D=e.required,M=e.status_calculated,A=e.steps,N=e.uuid;!E&&!n&&_&&(null===(r=Object.keys(_||{}))||void 0===r?void 0:r.length)>=1&&(o=(0,P.s)(Object.entries(_||{}).map((function(e){var n=(0,i.Z)(e,2),t=n[0],r=n[1];return[(0,b.vg)(t),r]})))),!E&&!n&&O&&(null===(l=Object.keys(O||{}))||void 0===l?void 0:l.length)>=1&&(x=(0,P.s)(Object.entries(O||{}).map((function(e){var n=(0,i.Z)(e,2),t=n[0],r=n[1];return[(0,b.vg)(t),r]}))));var H=(0,k.jsxs)(k.Fragment,{children:[!n&&(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(h.Z,{p:g.cd,children:(0,k.jsx)(p.ZP,{children:(0,k.jsxs)(d.Z,{flex:1,flexDirection:"column",children:[(0,k.jsxs)(p.ZP,{alignItems:"center",children:[(0,k.jsx)(d.Z,{flex:1,children:(0,k.jsx)(f.Z,{level:T?5:4,children:S})}),(0,k.jsx)(h.Z,{mr:g.cd}),(0,k.jsx)(Z.Fs,{danger:u.br.ERROR===M,muted:D&&u.br.INCOMPLETE===M,size:2*g.iI,success:!D||u.br.COMPLETED===M})]}),C&&(0,k.jsx)(h.Z,{mt:1,children:(0,k.jsx)(j.ZP,{default:!0,small:T,children:C})})]})})}),(null===A||void 0===A?void 0:A.length)>=1&&(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(a.Z,{light:!0}),(0,k.jsx)(m.Z,{contained:!1,onClickStep:w,setupSteps:A,small:T})]})]}),(o||x)&&(0,k.jsx)(h.Z,{p:g.cd,children:(0,k.jsxs)(p.ZP,{children:[o&&(0,k.jsx)(v.Z,{noPadding:!0,children:(0,k.jsxs)(p.ZP,{flexDirection:"column",children:[(0,k.jsx)(h.Z,{p:g.cd,children:(0,k.jsx)(j.ZP,{bold:!0,large:!0,children:"Attributes"})}),(0,k.jsx)(a.Z,{light:!0}),o,(0,k.jsx)(h.Z,{mb:g.cd})]})}),o&&x&&(0,k.jsx)(h.Z,{pr:g.cd}),x&&(0,k.jsx)(v.Z,{noPadding:!0,children:(0,k.jsxs)(p.ZP,{flexDirection:"column",children:[(0,k.jsx)(h.Z,{p:g.cd,children:(0,k.jsx)(j.ZP,{bold:!0,large:!0,children:"Connection"})}),(0,k.jsx)(a.Z,{light:!0}),x,(0,k.jsx)(h.Z,{mb:g.cd})]})})]})}),(null===y||void 0===y?void 0:y.length)>=1&&(0,k.jsxs)(k.Fragment,{children:[!n&&(0,k.jsx)(h.Z,{p:g.cd,children:(0,k.jsx)(p.ZP,{children:(0,k.jsx)(d.Z,{flex:1,flexDirection:"column",children:(0,k.jsx)(p.ZP,{alignItems:"center",children:(0,k.jsx)(d.Z,{flex:1,children:(0,k.jsx)(f.Z,{level:T?5:4,children:"Actions"})})})})})}),null===y||void 0===y?void 0:y.map((function(e,t){var r,i=e.description,l=e.name,o=e.uuid,u=U&&(null===R||void 0===R?void 0:R.uuid)===N&&(null===R||void 0===R?void 0:R.actionUUID)===o||s.i.PENDING===(null===F||void 0===F||null===(r=F.computeConnection)||void 0===r?void 0:r.state);return(0,k.jsxs)("div",{children:[(!n||t>=1)&&(0,k.jsx)(a.Z,{light:!0}),(0,k.jsx)(h.Z,{p:g.cd,children:(0,k.jsx)(p.ZP,{alignItems:"center",justifyContent:"space-between",children:(0,k.jsxs)(d.Z,{flex:1,flexDirection:"column",children:[(0,k.jsx)(j.ZP,{default:!0,large:!T,children:i}),(0,k.jsx)(h.Z,{mt:g.cd,children:(0,k.jsx)(c.ZP,{compact:T,danger:[s._.DELETE].includes(o),loading:u,onClick:function(){B({actionUUID:o,uuid:N}),z(null),W({action:o,uuid:N})},primary:[s._.CREATE,s._.UPDATE].includes(o),secondary:[s._.DESELECT].includes(o),small:T,children:l})})]})})})]},o)}))]})]});return(0,k.jsxs)(h.Z,{mt:t>=1?g.cd:0,px:I?g.cd:0,children:[I&&(0,k.jsx)(v.Z,{noPadding:!0,children:H}),!I&&H]},N)}))})}},77456:function(e,n,t){"use strict";var r=t(82394),i=t(75582),l=t(43695),o=t(30160),c=t(28598);function s(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function u(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?s(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):s(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}n.Z=function(e){var n=e.danger,t=e.error,r=e.large,s=e.small,a=e.warning,d=t.message,p=t.variables,f=d;return p&&Object.entries(p||{}).forEach((function(e){var t=(0,i.Z)(e,2),d=t[0],p=t[1];f=f.replace("{{".concat(d,"}}"),(0,l.Dq)((0,c.jsx)(o.ZP,u(u({danger:n,inline:!0,large:r,muted:!n&&!a,small:s,warning:a},p||{}),{},{children:d}))))})),(0,c.jsx)(o.ZP,{danger:n,dangerouslySetInnerHTML:{__html:f},muted:!n&&!a,large:r,small:s,warning:a})}},74778:function(e,n,t){"use strict";t.d(n,{UE:function(){return s},aw:function(){return u},bC:function(){return a}});var r=t(38626),i=t(44897),l=t(42631),o=t(70515),c=t(91437),s=r.default.div.withConfig({displayName:"indexstyle__CardStyle",componentId:"sc-1b5e7g-0"})([""," border-radius:","px;padding:","px;"," ",""],(0,c.eR)(),l.D7,2.5*o.iI,(function(e){return"\n background-color: ".concat((e.theme.background||i.Z.background).panel,";\n border: 1px solid ").concat((e.theme.borders||i.Z.borders).darkLight,";\n box-shadow: ").concat((e.theme.shadow||i.Z.shadow).frame,";\n ")}),(function(e){return!e.inline&&"\n height: ".concat(28*o.iI,"px;\n width: ").concat(40*o.iI,"px;\n margin: ").concat(o.cd/2*o.iI,"px;\n ")})),u=r.default.div.withConfig({displayName:"indexstyle__SetupStepRowStyle",componentId:"sc-1b5e7g-1"})([""," ",""],(0,c.eR)(),(function(e){return e.clickable&&"\n &:hover {\n background-color: ".concat((e.theme.interactive||i.Z.interactive).hoverOverlay,";\n cursor: pointer;\n }\n ")})),a=r.default.div.withConfig({displayName:"indexstyle__NavigationStyle",componentId:"sc-1b5e7g-2"})([""," height:","px;padding-left:","px;padding-right:","px;"," ",""],(0,c.eR)(),7*o.iI,o.cd*o.iI,o.cd*o.iI,(function(e){return!e.selected&&"\n &:hover {\n background-color: ".concat((e.theme.interactive||i.Z.interactive).rowHoverBackground,";\n }\n ")}),(function(e){return e.selected&&"\n background-color: ".concat((e.theme.background||i.Z.background).codeTextarea,";\n ")}))},94629:function(e,n,t){"use strict";t.d(n,{Z:function(){return O}});var r=t(82394),i=t(21831),l=t(82684),o=t(50724),c=t(82555),s=t(97618),u=t(70613),a=t(68487),d=t(68899),p=t(28598);function f(e,n){var t=e.children,r=e.noPadding;return(0,p.jsx)(d.HS,{noPadding:r,ref:n,children:t})}var v=l.forwardRef(f),m=t(62547),h=t(82571),j=t(35686),x=t(98464),g=t(46684),Z=t(70515),b=t(53808),P=t(19183);function y(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function _(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?y(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):y(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function k(e,n){var t,r=e.addProjectBreadcrumbToCustomBreadcrumbs,f=e.after,y=e.afterHeader,k=e.afterHidden,O=e.afterWidth,C=e.afterWidthOverride,I=e.appendBreadcrumbs,S=e.before,E=e.beforeWidth,w=e.breadcrumbs,T=e.children,D=e.errors,M=e.headerMenuItems,A=e.headerOffset,R=e.hideAfterCompletely,B=e.mainContainerHeader,N=e.navigationItems,F=e.setAfterHidden,z=e.setErrors,H=e.subheaderChildren,L=e.subheaderNoPadding,W=e.title,U=e.uuid,V=(0,P.i)().width,G="dashboard_after_width_".concat(U),X="dashboard_before_width_".concat(U),q=(0,l.useRef)(null),J=(0,l.useState)(C?O:(0,b.U2)(G,O)),K=J[0],Y=J[1],Q=(0,l.useState)(!1),$=Q[0],ee=Q[1],ne=(0,l.useState)(S?Math.max((0,b.U2)(X,E),13*Z.iI):null),te=ne[0],re=ne[1],ie=(0,l.useState)(!1),le=ie[0],oe=ie[1],ce=(0,l.useState)(null)[1],se=j.ZP.projects.list({},{revalidateOnFocus:!1}).data,ue=null===se||void 0===se?void 0:se.projects,ae={label:function(){var e;return null===ue||void 0===ue||null===(e=ue[0])||void 0===e?void 0:e.name},linkProps:{href:"/"}},de=[];w&&(r&&de.push(ae),de.push.apply(de,(0,i.Z)(w))),(null===w||void 0===w||!w.length||I)&&(null===ue||void 0===ue?void 0:ue.length)>=1&&(null!==w&&void 0!==w&&w.length||de.unshift({bold:!I,label:function(){return W}}),de.unshift(ae)),(0,l.useEffect)((function(){null===q||void 0===q||!q.current||$||le||null===ce||void 0===ce||ce(q.current.getBoundingClientRect().width)}),[$,K,le,te,q,ce,V]),(0,l.useEffect)((function(){$||(0,b.t8)(G,K)}),[k,$,K,G]),(0,l.useEffect)((function(){le||(0,b.t8)(X,te)}),[le,te,X]);var pe=(0,x.Z)(O);return(0,l.useEffect)((function(){C&&pe!==O&&Y(O)}),[C,O,pe]),(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)(u.Z,{title:W}),(0,p.jsx)(a.Z,{breadcrumbs:de,menuItems:M,project:null===ue||void 0===ue?void 0:ue[0],version:null===ue||void 0===ue||null===(t=ue[0])||void 0===t?void 0:t.version}),(0,p.jsxs)(d.Nk,{ref:n,children:[0!==(null===N||void 0===N?void 0:N.length)&&(0,p.jsx)(d.lm,{showMore:!0,children:(0,p.jsx)(h.Z,{navigationItems:N,showMore:!0})}),(0,p.jsx)(s.Z,{flex:1,flexDirection:"column",children:(0,p.jsxs)(m.Z,{after:f,afterHeader:y,afterHeightOffset:g.Mz,afterHidden:k,afterMousedownActive:$,afterWidth:K,before:S,beforeHeightOffset:g.Mz,beforeMousedownActive:le,beforeWidth:d.k1+(S?te:0),headerOffset:A,hideAfterCompletely:!F||R,leftOffset:S?d.k1:null,mainContainerHeader:B,mainContainerRef:q,setAfterHidden:F,setAfterMousedownActive:ee,setAfterWidth:Y,setBeforeMousedownActive:oe,setBeforeWidth:re,children:[H&&(0,p.jsx)(v,{noPadding:L,children:H}),T]})})]}),D&&(0,p.jsx)(o.Z,{disableClickOutside:!0,isOpen:!0,onClickOutside:function(){return null===z||void 0===z?void 0:z(null)},children:(0,p.jsx)(c.Z,_(_({},D),{},{onClose:function(){return null===z||void 0===z?void 0:z(null)}}))})]})}var O=l.forwardRef(k)},8193:function(e,n,t){"use strict";t.d(n,{N:function(){return s},Z:function(){return c}});var r=t(38626),i=t(44897),l=t(42631),o=t(70515),c=2*o.iI,s=r.default.div.withConfig({displayName:"indexstyle__ContainerStyle",componentId:"sc-1ck7mzt-0"})(["border-radius:","px;padding:","px;",""],l.n_,o.cd*o.iI,(function(e){return"\n background-color: ".concat((e.theme.background||i.Z.background).codeArea,";\n ")}))},28071:function(e,n,t){"use strict";var r;t.d(n,{X:function(){return r}}),function(e){e.BOOTSTRAPPING="BOOTSTRAPPING",e.RUNNING="RUNNING",e.STARTING="STARTING",e.TERMINATED="TERMINATED",e.TERMINATED_WITH_ERRORS="TERMINATED_WITH_ERRORS",e.TERMINATING="TERMINATING",e.WAITING="WAITING"}(r||(r={}))},26032:function(e,n,t){"use strict";var r,i;t.d(n,{_:function(){return r},i:function(){return i}}),function(e){e.CREATE="CREATE",e.DELETE="DELETE",e.DESELECT="DESELECT",e.UPDATE="UPDATE"}(r||(r={})),function(e){e.ACTIVE="ACTIVE",e.INACTIVE="INACTIVE",e.PENDING="PENDING"}(i||(i={}))},4910:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return qe}});var r=t(77837),i=t(38860),l=t.n(i),o=t(82684),c=t(82394),s=t(75582),u=t(69864),a=t(71180),d=t(92083),p=t.n(d),f=t(21764),v=t(28071),m=t(15338),h=t(55485),j=t(85854),x=t(97618),g=t(38276),Z=t(30160),b=t(70515),P=t(28598);function y(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function _(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?y(Object(t),!0).forEach((function(n){(0,c.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):y(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var k=function(e){var n=e.rows;return(0,P.jsx)(P.Fragment,{children:null===n||void 0===n?void 0:n.map((function(e){var n=e.key,t=e.textProps,r=e.value;return(0,P.jsxs)("div",{children:[(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsx)(h.ZP,{flexDirection:"column",children:(0,P.jsx)(Z.ZP,{default:!0,large:!0,children:n})}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,justifyContent:"flex-end",children:(0,P.jsx)(Z.ZP,_(_({default:!0,large:!0},t),{},{children:r}))})]})})]},n)}))})},O=t(65956),C=t(4190),I=t(75499),S=t(69650),E=t(35686),w=t(72473),T=t(3917),D=t(38626),M=t(44897),A=D.default.div.withConfig({displayName:"indexstyle__SubheaderStyle",componentId:"sc-169asq7-0"})(["position:sticky;top:0;z-index:1;",""],(function(e){return"\n background-color: ".concat((e.theme.background||M.Z.background).codeArea,";\n ")})),R=t(81728);function B(e){var n;if(null===e||void 0===e||!e.length)return null;var t=null===e||void 0===e?void 0:e[0],r=null===(n=Object.keys(t||{}))||void 0===n?void 0:n.map((function(e){return{uuid:(0,R.vg)(e)}}));return(0,P.jsx)(I.Z,{columnFlex:null===r||void 0===r?void 0:r.map((function(e,n){return 0===n?null:1})),columns:r,rows:null===e||void 0===e?void 0:e.map((function(e){return Object.entries(e||{}).map((function(e){var n=(0,s.Z)(e,2),t=n[0],r=n[1];return[(0,P.jsx)(Z.ZP,{default:!0,monospace:!0,children:r},t)]}))}))})}var N=t(72619),F=t(3314),z=t(42122),H=t(70320),L=t(23780);function W(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function U(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?W(Object(t),!0).forEach((function(n){(0,c.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):W(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var V=2*b.iI,G={default:!0,monospace:!0};var X=function(e){var n=e.clusters,t=e.computeService,r=e.fetchAll,i=e.includeAllStates,l=e.loading,c=e.setIncludeAllStates,d=(0,o.useMemo)((function(){return"".concat(null===t||void 0===t?void 0:t.uuid,"/clusters")}),[t]),x=(0,H.q)(),y=(0,o.useState)(null),_=y[0],D=y[1],M=(0,L.VI)(null,{},[],{uuid:d}),W=(0,s.Z)(M,1)[0],X=(0,u.Db)(E.ZP.compute_clusters.compute_services.useCreate(null===t||void 0===t?void 0:t.uuid),{onSuccess:function(e){return(0,N.wD)(e,{callback:function(){r().then((function(){return D(0)}))},onErrorCallback:function(e,n){return W({errors:n,response:e})}})}}),q=(0,s.Z)(X,2),J=q[0],K=q[1].isLoading,Y=(0,u.Db)((function(e){return E.ZP.compute_clusters.compute_services.useDelete(null===t||void 0===t?void 0:t.uuid,null===e||void 0===e?void 0:e.id)()}),{onSuccess:function(e){return(0,N.wD)(e,{callback:function(){r().then((function(){return D(null)}))},onErrorCallback:function(e){var n=e.error,t=n.errors,r=n.exception,i=n.message,l=n.type;f.Am.error((null===t||void 0===t?void 0:t.error)||r||i,{position:f.Am.POSITION.BOTTOM_RIGHT,toastId:l})}})}}),Q=(0,s.Z)(Y,2),$=Q[0],ee=Q[1].isLoading,ne=(0,u.Db)((function(e){return E.ZP.compute_clusters.compute_services.useUpdate(null===t||void 0===t?void 0:t.uuid,null===e||void 0===e?void 0:e.id)({compute_cluster:(0,z.GL)(e,["active"])})}),{onSuccess:function(e){return(0,N.wD)(e,{callback:function(){r()},onErrorCallback:function(e){var n=e.error,t=n.errors,r=n.exception,i=n.message,l=n.type;f.Am.error((null===t||void 0===t?void 0:t.error)||r||i,{position:f.Am.POSITION.BOTTOM_RIGHT,toastId:l})}})}}),te=(0,s.Z)(ne,2),re=te[0],ie=te[1].isLoading,le=(0,o.useMemo)((function(){return(null===n||void 0===n?void 0:n.length)||0}),[n]),oe=(0,o.useMemo)((function(){return(0,P.jsx)(a.ZP,{beforeIcon:(0,P.jsx)(w.NO,{size:V}),compact:le>=1,loading:K,onClick:function(){return J()},primary:!0,small:le>=1,children:"Launch new cluster"})}),[le,J,K]);return(0,P.jsxs)(P.Fragment,{children:[(0,P.jsxs)(A,{children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,P.jsxs)(h.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,P.jsx)(j.Z,{level:4,children:(0,R._6)("cluster",le,!0)}),c&&(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(S.Z,{checked:i,compact:!0,onCheck:function(e){return c(e(i))}}),(0,P.jsx)(g.Z,{mr:1}),(0,P.jsx)(Z.ZP,{default:i,muted:!i,small:!0,children:"Include terminated clusters"})]})]}),(0,P.jsx)(g.Z,{mr:b.cd}),le>=1&&oe]})}),(0,P.jsx)(m.Z,{light:!0})]}),(0,P.jsx)(I.Z,{apiForFetchingAfterAction:E.ZP.compute_clusters.compute_services.detail,buildApiOptionsFromObject:function(e){return[null===t||void 0===t?void 0:t.uuid,null===e||void 0===e?void 0:e.id,{},{refreshInterval:3e3,revalidateOnFocus:!0}]},columnFlex:[null,null,null,null,null],columns:[{uuid:"Cluster ID"},{uuid:"Cluster Name"},{uuid:"Status"},{uuid:"Created"},{center:!0,uuid:"Hours"},{label:function(){return""},rightAligned:!0,uuid:"Active"}],onClickRow:function(e,n){D((function(n){return n===e?null:e}))},renderExpandedRowWithObject:function(e,n){var t,r,i,l,o=null===n||void 0===n||null===(t=n.compute_cluster)||void 0===t?void 0:t.cluster;if(!o)return(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsx)(C.Z,{inverted:!0})});var c=o.active,s=o.applications,u=o.ec2_instance_attributes,d=o.name,f=o.status,y=o.tags,_=null===f||void 0===f?void 0:f.state,I=[v.X.TERMINATED,v.X.TERMINATED_WITH_ERRORS,v.X.TERMINATING].includes(_),S=[v.X.RUNNING,v.X.WAITING].includes(_),E=null===f||void 0===f||null===(r=f.timeline)||void 0===r?void 0:r.creation_date_time;return(0,P.jsxs)(g.Z,{p:b.cd,children:[!I&&(0,P.jsxs)(P.Fragment,{children:[(0,P.jsxs)(O.Z,{noPadding:!0,children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsx)(j.Z,{level:4,children:"Actions"})}),(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{children:[S&&(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(a.ZP,{beforeIcon:(0,P.jsx)(w.Fs,{size:V,success:c}),loading:ie,notClickable:c,onClick:c?null:function(){return re(U(U({},o),{},{active:!0}))},primary:!c,children:c?"Activated":"Activate cluster for compute"}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(a.ZP,{loading:ee,onClick:function(){window.confirm("Are you sure you want to terminate this cluster?")&&$(o)},secondary:!0,children:"Terminate cluster"})]}),!S&&(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsx)(C.Z,{inverted:!0,small:!0}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(Z.ZP,{default:!0,large:!0,children:(null===f||void 0===f||null===(i=f.state_change_reason)||void 0===i?void 0:i.message)||"Cluster is still launching."})]})]})})]}),(0,P.jsx)(g.Z,{mb:b.cd})]}),(0,P.jsxs)(O.Z,{noPadding:!0,children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsx)(j.Z,{level:4,children:"Details"})}),(0,P.jsx)(k,{rows:[{key:"ID",textProps:{monospace:!0},value:null===o||void 0===o?void 0:o.id},{key:"Name",value:d},{key:"Master public DNS name",value:(null===o||void 0===o?void 0:o.master_public_dns_name)||"Available after cluster starts."},{key:"Created at",textProps:{monospace:!0},value:E?(0,T.XG)(p()(E).format(T.BL),x):"-"},{key:"Status message",value:(null===f||void 0===f||null===(l=f.state_change_reason)||void 0===l?void 0:l.message)||"None"},{key:"Release label",textProps:{monospace:!0},value:null===o||void 0===o?void 0:o.release_label},{key:"Service role",textProps:{monospace:!0},value:null===o||void 0===o?void 0:o.service_role},{key:"Scale down behavior",value:null!==o&&void 0!==o&&o.scale_down_behavior?(0,R.vg)(null===o||void 0===o?void 0:o.scale_down_behavior):null===o||void 0===o?void 0:o.scale_down_behavior},{key:"Auto terminate",value:null!==o&&void 0!==o&&o.auto_terminate?(0,P.jsx)(w.Jr,{size:V,success:!0}):(0,P.jsx)(w.x8,{danger:!0,size:V})},{key:"Termination protected",value:null!==o&&void 0!==o&&o.termination_protected?(0,P.jsx)(w.Jr,{size:V,success:!0}):(0,P.jsx)(w.x8,{danger:!0,size:V})},{key:"Visible to all users",value:null!==o&&void 0!==o&&o.visible_to_all_users?(0,P.jsx)(w.Jr,{size:V,success:!0}):(0,P.jsx)(w.x8,{danger:!0,size:V})},{key:"EBS root volume size",textProps:{monospace:!0},value:null===o||void 0===o?void 0:o.ebs_root_volume_size},{key:"Normalized instance hours",textProps:{monospace:!0},value:null===o||void 0===o?void 0:o.normalized_instance_hours},{key:"Step concurrency level",textProps:{monospace:!0},value:null===o||void 0===o?void 0:o.step_concurrency_level}]})]}),(0,P.jsx)(g.Z,{mb:b.cd}),(0,P.jsxs)(O.Z,{noPadding:!0,children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsx)(j.Z,{level:4,children:"EC2 instance attributes"})}),(0,P.jsx)(k,{rows:[{key:"Availability zone",textProps:{monospace:!0},value:null===u||void 0===u?void 0:u.ec2_availability_zone},{key:"Master security group",textProps:{monospace:!0},value:null===u||void 0===u?void 0:u.emr_managed_master_security_group},{key:"Slave security group",textProps:{monospace:!0},value:null===u||void 0===u?void 0:u.emr_managed_slave_security_group},{key:"IAM profile",textProps:{monospace:!0},value:null===u||void 0===u?void 0:u.iam_instance_profile}]})]}),(0,P.jsx)(g.Z,{mb:b.cd}),(0,P.jsxs)(h.ZP,{children:[(0,P.jsxs)(O.Z,{noPadding:!0,children:[(0,P.jsx)(g.Z,{px:b.cd,py:b.cd,children:(0,P.jsx)(j.Z,{level:4,children:"Applications"})}),(0,P.jsx)(m.Z,{light:!0,short:!0}),B(s||[])]}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsxs)(O.Z,{noPadding:!0,children:[(0,P.jsx)(g.Z,{px:b.cd,py:b.cd,children:(0,P.jsx)(j.Z,{level:4,children:"Tags"})}),(0,P.jsx)(m.Z,{light:!0,short:!0}),B(y||[])]})]})]})},getObjectAtRowIndex:function(e){return null===n||void 0===n?void 0:n[e]},rows:null===n||void 0===n?void 0:n.map((function(e){var n,t,r=e.active,i=e.id,l=e.name,c=e.normalized_instance_hours,s=e.status,u=null===s||void 0===s||null===(n=s.timeline)||void 0===n?void 0:n.creation_date_time,d=null===s||void 0===s?void 0:s.state,f=null===s||void 0===s||null===(t=s.state_change_reason)||void 0===t?void 0:t.message,m=[v.X.BOOTSTRAPPING,v.X.STARTING].includes(d),j=[v.X.TERMINATING].includes(d);return[(0,o.createElement)(Z.ZP,U(U({},G),{},{key:"id",success:r}),i),(0,o.createElement)(Z.ZP,U(U({},G),{},{key:"name",monospace:!1,preWrap:!0}),l),(0,P.jsxs)("div",{children:[(0,P.jsx)(Z.ZP,U(U({},G),{},{danger:[v.X.TERMINATED_WITH_ERRORS].includes(d),default:[v.X.STARTING].includes(d),muted:[v.X.TERMINATED].includes(d),success:[v.X.RUNNING,v.X.WAITING].includes(d),warning:[v.X.TERMINATING].includes(d),children:null!==s&&void 0!==s&&s.state?(0,R.vg)(null===s||void 0===s?void 0:s.state):null===s||void 0===s?void 0:s.state})),f&&(0,P.jsx)(Z.ZP,{muted:!0,preWrap:!0,small:!0,children:f})]},"state"),(0,o.createElement)(Z.ZP,U(U({},G),{},{key:"created",preWrap:!0}),u?(0,T.XG)(p()(u).format(T.BL),x):"-"),(0,o.createElement)(Z.ZP,U(U({},G),{},{center:!0,key:"normalizedInstanceHours"}),c||0),(0,P.jsx)(h.ZP,{justifyContent:"flex-end",children:m||j?(0,P.jsx)(C.Z,{inverted:m,small:!0}):(0,P.jsx)(a.ZP,{iconOnly:!0,loading:ie,noBackground:!0,noBorder:!0,noPadding:!0,notClickable:r,onClick:r?null:function(n){(0,F.j)(n),re(U(U({},e),{},{active:!0}))},children:(0,P.jsx)(w.Fs,{muted:!r,size:V,success:r})})},"active")]})),selectedRowIndexInternal:_,uuid:d}),l&&(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsx)(C.Z,{inverted:!0})}),!l&&!le&&(0,P.jsx)(g.Z,{p:b.cd,children:oe})]})},q=t(48670),J=t(90299),K=t(89308),Y=t(74521),Q=t(93004),$=t(8970);function ee(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function ne(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?ee(Object(t),!0).forEach((function(n){(0,c.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):ee(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var te="Applications",re="Connections",ie="Jobs",le="SQLs";var oe=function(e){var n,t=e.applications,r=e.computeConnections,i=e.computeService,l=e.connectionsLoading,c=e.fetchAll,s=e.jobs,u=e.loadingApplications,a=e.loadingJobs,d=(e.objectAttributes,e.refButtonTabs),p=(e.selectedComputeService,e.setSelectedSql),f=e.setSelectedTab,v=(0,o.useContext)(D.ThemeContext),h=(0,o.useState)(),j=h[0],x=h[1],y=(0,o.useCallback)((function(e){p((function(){return null})),x(e)}),[p,x]),_=(0,H.q)(),k=E.ZP.spark_stages.list({details:!0,_format:"with_details"}).data,O=(0,o.useMemo)((function(){return((null===k||void 0===k?void 0:k.spark_stages)||[]).reduce((function(e,n){var t=null===n||void 0===n?void 0:n.application;return(null===t||void 0===t?void 0:t.calculated_id)in e||(e[null===t||void 0===t?void 0:t.calculated_id]={}),e[null===t||void 0===t?void 0:t.calculated_id][null===n||void 0===n?void 0:n.stage_id]=n,e}),{})}),[k]),C=(0,o.useMemo)((function(){return(0,P.jsx)(K.Z,{computeService:i,computeConnections:r,fetchAll:c,onClickStep:function(e){return f((function(){return{main:e}}))}})}),[r,i,c,f]),S=(0,o.useMemo)((function(){return(0,P.jsx)(I.Z,{columnFlex:[null,null,null,null,null,null,null],columns:[{uuid:"ID"},{uuid:"URL"},{uuid:"Name"},{uuid:"Version"},{uuid:"Spark user"},{uuid:"Started at"},{rightAligned:!0,uuid:"Last updated"}],rows:null===t||void 0===t?void 0:t.map((function(e){var n=e.attempts,t=e.id,r=e.name,i=e.spark_ui_url,l=(null===n||void 0===n?void 0:n[0])||{},c=l.app_spark_version,s=l.last_updated_epoch,u=l.start_time_epoch,a=l.spark_user,d=u&&(0,T.JX)(u/1e3,{withSeconds:!0}),p=d&&(0,T.XG)(d,_);return[(0,o.createElement)(Z.ZP,ne(ne({},$.eB),{},{key:"id"}),t),(0,o.createElement)(Z.ZP,ne(ne({},$.eB),{},{key:"sparkUIURL"}),i),(0,o.createElement)(Z.ZP,ne(ne({},$.eB),{},{key:"name"}),r),(0,o.createElement)(Z.ZP,ne(ne({},$.eB),{},{key:"version"}),c),(0,o.createElement)(Z.ZP,ne(ne({},$.eB),{},{key:"sparkUser"}),a),(0,o.createElement)(Z.ZP,ne(ne({},$.eB),{},{key:"startTime"}),p||"-"),(0,o.createElement)(Z.ZP,ne(ne({},$.eB),{},{key:"lastUpdated",rightAligned:!0}),s?(0,T.XG)((0,T.JX)(s/1e3,{withSeconds:!0}),_):"-")]})),uuid:"applications"})}),[t,_]),w=(0,o.useMemo)((function(){var e={};return null===s||void 0===s||s.forEach((function(n){var t,r,i=null===n||void 0===n?void 0:n.application;(null===i||void 0===i?void 0:i.calculated_id)in e||(e[null===i||void 0===i?void 0:i.calculated_id]={application:i,jobs:[]}),null===(t=e[null===i||void 0===i?void 0:i.calculated_id])||void 0===t||null===(r=t.jobs)||void 0===r||r.push(n)})),Object.values(e).map((function(e){var n=e.application,t=e.jobs;return(0,P.jsxs)("div",{children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(Z.ZP,{default:!0,bold:!0,children:["Application ",null===n||void 0===n?void 0:n.calculated_id]})}),(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(Y.Z,{jobs:t,stagesMapping:O})]},null===n||void 0===n?void 0:n.calculated_id)}))}),[s,O]),M=(0,o.useMemo)((function(){return(0,P.jsx)(Q.Z,{setSelectedSql:p,stagesMapping:O})}),[p,O]),A=(0,o.useMemo)((function(){var e=[{label:function(){return(0,P.jsxs)(P.Fragment,{children:[te,"\xa0\xa0\xa0",u?"":(null===t||void 0===t?void 0:t.length)||0]})},uuid:te},{label:function(){return(0,P.jsxs)(P.Fragment,{children:[ie,"\xa0\xa0\xa0",a?"":(null===s||void 0===s?void 0:s.length)||0]})},uuid:ie},{label:function(){return le},uuid:le}];return(null===r||void 0===r?void 0:r.length)>=1&&e.unshift({label:function(){return re},uuid:re}),e}),[r,c]);return(0,o.useEffect)((function(){j||l||((null===r||void 0===r?void 0:r.length)>=1?y(re):y(te))}),[r,l,j,y]),(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(g.Z,{px:b.cd,children:(0,P.jsx)(J.Z,{noPadding:!0,onClickTab:function(e){var n=e.uuid;return y(n)},ref:d,regularSizeText:!0,selectedTabUUID:j,tabs:A,underlineColor:null===v||void 0===v||null===(n=v.accent)||void 0===n?void 0:n.blue,underlineStyle:!0})}),(0,P.jsx)(m.Z,{light:!0}),re===j&&C,te===j&&S,ie===j&&w,le===j&&M]})},ce=t(17488),se=t(8193);function ue(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function ae(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?ue(Object(t),!0).forEach((function(n){(0,c.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):ue(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var de=function(e){var n=e.addButtonText,t=e.addTextInputPlaceholder,r=e.alreadyExistsMessage,i=e.configurationValuePlaceholder,l=e.configurations,u=e.createButtonText,d=e.description,p=e.emptyState,f=e.setConfigurations,v=e.title,y=(0,o.useRef)(null),_=(0,o.useState)(!1),k=_[0],C=_[1],I=(0,o.useState)(null),S=I[0],E=I[1],T=(0,o.useMemo)((function(){var e;return(null===(e=Object.keys(l||{}))||void 0===e?void 0:e.length)>=1}),[l]),D=(0,o.useMemo)((function(){return S in(l||{})}),[l,S]),M=(0,o.useMemo)((function(){return(0,P.jsxs)(h.ZP,{alignItems:"center",children:[!k&&(0,P.jsx)(a.ZP,{beforeIcon:(0,P.jsx)(w.mm,{}),compact:!0,onClick:function(e){(0,F.j)(e),C(!0),setTimeout((function(){var e;return null===y||void 0===y||null===(e=y.current)||void 0===e?void 0:e.focus()}),1)},secondary:!T,small:!0,children:n||"Add configuration"}),k&&(0,P.jsxs)(P.Fragment,{children:[D&&(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(Z.ZP,{danger:!0,small:!0,children:r||"Already exists"}),(0,P.jsx)(g.Z,{mr:1})]}),(0,P.jsx)(ce.Z,{autoComplete:"off",compact:!0,meta:{touched:!!D,error:""},monospace:!0,onClick:function(e){return(0,F.j)(e)},paddingVertical:b.iI/2-2,placeholder:t,onChange:function(e){(0,F.j)(e),E(e.target.value)},ref:y,small:!0,value:S||""}),(0,P.jsx)(g.Z,{mr:1}),(0,P.jsx)(a.ZP,{disabled:D,compact:!0,onClick:function(e){(0,F.j)(e),D||(f(ae(ae({},l),{},(0,c.Z)({},S,""))),C(!1),E(null))},primary:!0,small:!0,children:u||"Create configuration"}),(0,P.jsx)(g.Z,{mr:1}),(0,P.jsx)(a.ZP,{compact:!0,onClick:function(e){(0,F.j)(e),C(!1),E(null)},secondary:!0,small:!0,children:"Cancel"})]})]})}),[n,D,l,T,k,S,y,C,E]),A=(0,o.useMemo)((function(){return Object.entries(l||{}).map((function(e){var n=(0,s.Z)(e,2),t=n[0],r=n[1];return(0,P.jsxs)("div",{children:[(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsx)(a.ZP,{iconOnly:!0,noBackground:!0,noBorder:!0,noPadding:!0,onClick:function(){var e=ae({},l);null===e||void 0===e||delete e[t],f(e)},children:(0,P.jsx)(w.rF,{default:!0,size:se.Z})}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(Z.ZP,{default:!0,large:!0,monospace:!0,children:t}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,children:(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,fullWidth:!0,large:!0,monospace:!0,noBackground:!0,noBorder:!0,onChange:function(e){return f(ae(ae({},l),{},(0,c.Z)({},t,e.target.value)))},paddingHorizontal:0,paddingVertical:0,placeholder:i,value:r||""})})]})})]},t)}))}),[l,f]);return(0,P.jsxs)(O.Z,{noPadding:!0,children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,P.jsxs)(x.Z,{flex:1,flexDirection:"column",children:[(0,P.jsx)(j.Z,{level:4,children:v}),d&&(0,P.jsx)(g.Z,{mt:1,children:d})]}),(0,P.jsx)(g.Z,{mr:b.cd}),T&&(0,P.jsx)(h.ZP,{alignItems:"center",children:M})]})}),!T&&(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(m.Z,{light:!0}),(0,P.jsxs)(g.Z,{p:b.cd,children:[p&&(0,P.jsx)(g.Z,{mb:b.cd,children:(0,P.jsx)(Z.ZP,{default:!0,children:p})}),(0,P.jsx)(h.ZP,{alignItems:"center",children:M})]})]}),T&&A]})},pe=t(74260);function fe(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function ve(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?fe(Object(t),!0).forEach((function(n){(0,c.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):fe(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var me=function(e){var n,t=e.attributesTouched,r=e.isLoading,i=e.mutateObject,l=e.objectAttributes,c=e.onCancel,s=e.selectedComputeService,u=e.setObjectAttributes,d=(0,o.useCallback)((function(e){return u({emr_config:ve(ve({},null===l||void 0===l?void 0:l.emr_config),e)})}),[l,u]),p=(0,o.useCallback)((function(e){return u({spark_config:ve(ve({},null===l||void 0===l?void 0:l.spark_config),e)})}),[l,u]),f=(0,o.useMemo)((function(){return(null===l||void 0===l?void 0:l.emr_config)||{}}),[l]),v=(0,o.useMemo)((function(){return(null===l||void 0===l?void 0:l.spark_config)||{}}),[l]);return(0,P.jsxs)(se.N,{children:[(0,P.jsx)(de,{addButtonText:"Add Spark configuration",addTextInputPlaceholder:"e.g. spark.driver.cores",alreadyExistsMessage:"Spark configuration exists",configurationValuePlaceholder:"e.g. 4g",configurations:null===v||void 0===v?void 0:v.others,createButtonText:"Create Spark configuration",description:(0,P.jsxs)(P.Fragment,{children:[(0,P.jsxs)(Z.ZP,{muted:!0,children:["List of key-value pairs to be set in ",(0,P.jsx)(Z.ZP,{inline:!0,monospace:!0,muted:!0,children:"SparkConf"}),", e.g. ",(0,P.jsx)(Z.ZP,{inline:!0,monospace:!0,muted:!0,children:"spark.executor.memory=4g"}),"."]}),(0,P.jsxs)(Z.ZP,{muted:!0,children:["For a list of all configurations, see the ",(0,P.jsx)(q.Z,{href:"https://spark.apache.org/docs/latest/configuration.html",inline:!0,openNewWindow:!0,children:"Spark configuration documentation"}),"."]})]}),emptyState:"There are currently no executor Spark configurations.",setConfigurations:function(e){return p({others:e})},title:"Spark configurations"}),(0,P.jsx)(g.Z,{mb:b.HN}),pe.GO.AWS_EMR===s&&(0,P.jsxs)(P.Fragment,{children:[(0,P.jsxs)(O.Z,{noPadding:!0,children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsx)(h.ZP,{alignItems:"center",justifyContent:"space-between",children:(0,P.jsxs)(x.Z,{flex:1,flexDirection:"column",children:[(0,P.jsx)(j.Z,{level:4,warning:!(null!==f&&void 0!==f&&f.ec2_key_name)||!(null!==f&&void 0!==f&&f.ec2_key_path),children:"Spark observability"}),(!(null!==f&&void 0!==f&&f.ec2_key_name)||!(null!==f&&void 0!==f&&f.ec2_key_path))&&"ec2_key_name"in((null===t||void 0===t?void 0:t.emr_config)||{})&&"ec2_key_path"in((null===t||void 0===t?void 0:t.emr_config)||{})&&(0,P.jsx)(P.Fragment,{children:(0,P.jsx)(g.Z,{mt:1,children:(0,P.jsxs)(Z.ZP,{warning:!0,children:["Without all the fields in this section present and valid, Mage won\u2019t automatically create the SSH tunnel.",(0,P.jsx)("br",{}),"You must manually create the SSH tunnel in order for Mage to retrieve and display the Spark jobs, statuses, metrics, and system information."]})})}),(0,P.jsx)(g.Z,{mt:1,children:(0,P.jsxs)(Z.ZP,{muted:!0,children:["In order to see the Spark jobs, statuses, metrics, and system information, an SSH tunnel to the AWS EMR Master Node must be created.",(0,P.jsx)("br",{}),"Mage can automatically create the SSH tunnel for you if every field in this section is present and valid."]})}),(0,P.jsx)(g.Z,{mt:1,children:(0,P.jsx)(Z.ZP,{muted:!0})})]})})}),(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsxs)(h.ZP,{flexDirection:"column",children:[(0,P.jsx)(Z.ZP,{default:!0,large:!0,children:"EC2 key name"}),(0,P.jsxs)(Z.ZP,{muted:!0,small:!0,children:["SSH tunnel into the EMR cluster using a key pair created from the ",(0,P.jsx)(q.Z,{href:"https://console.aws.amazon.com/ec2/home#KeyPairs",inline:!0,openNewWindow:!0,small:!0,children:"AWS guide"}),"."]})]}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,children:(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,autoComplete:"off",large:!0,noBackground:!0,noBorder:!0,fullWidth:!0,onChange:function(e){return d({ec2_key_name:e.target.value})},paddingHorizontal:0,paddingVertical:0,placeholder:"e.g. ec2_key_pair_name",value:(null===f||void 0===f?void 0:f.ec2_key_name)||""})})]})}),(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsxs)(h.ZP,{flexDirection:"column",children:[(0,P.jsx)(Z.ZP,{default:!0,large:!0,children:"EC2 key path"}),(0,P.jsx)(Z.ZP,{muted:!0,small:!0,children:"The absolute file path to the EC2 public key that was used when creating a cluster."})]}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,children:(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,autoComplete:"off",large:!0,monospace:!0,noBackground:!0,noBorder:!0,fullWidth:!0,onChange:function(e){return d({ec2_key_path:e.target.value})},paddingHorizontal:0,paddingVertical:0,placeholder:"e.g. ec2_key_pair_name",value:(null===f||void 0===f?void 0:f.ec2_key_path)||""})})]})})]}),(0,P.jsx)(g.Z,{mb:b.HN}),(0,P.jsxs)(O.Z,{noPadding:!0,children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsx)(h.ZP,{alignItems:"center",justifyContent:"space-between",children:(0,P.jsxs)(x.Z,{flex:1,flexDirection:"column",children:[(0,P.jsx)(j.Z,{level:4,children:"EMR instance types"}),(0,P.jsx)(g.Z,{mt:1,children:(0,P.jsxs)(Z.ZP,{muted:!0,children:["Refer to the ",(0,P.jsx)(q.Z,{href:"https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-supported-instance-types.html",openNewWindow:!0,children:"AWS EMR"})," documentation for all supported EMR instance types."]})})]})})}),(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsx)(h.ZP,{flexDirection:"column",children:(0,P.jsx)(Z.ZP,{default:!0,large:!0,children:"Master instance type"})}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,children:(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,autoComplete:"off",large:!0,noBackground:!0,noBorder:!0,fullWidth:!0,onChange:function(e){return d({master_instance_type:e.target.value})},paddingHorizontal:0,paddingVertical:0,placeholder:"e.g. r5.4xlarge",value:(null===f||void 0===f?void 0:f.master_instance_type)||""})})]})}),(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsx)(h.ZP,{flexDirection:"column",children:(0,P.jsx)(Z.ZP,{default:!0,large:!0,children:"Slave instance type"})}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,children:(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,autoComplete:"off",large:!0,noBackground:!0,noBorder:!0,fullWidth:!0,onChange:function(e){return d({slave_instance_type:e.target.value})},paddingHorizontal:0,paddingVertical:0,placeholder:"e.g. r5.2xlarge",value:(null===f||void 0===f?void 0:f.slave_instance_type)||""})})]})}),(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsx)(h.ZP,{flexDirection:"column",children:(0,P.jsx)(Z.ZP,{default:!0,large:!0,children:"Number of slave instances"})}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,children:(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,autoComplete:"off",large:!0,noBackground:!0,noBorder:!0,fullWidth:!0,onChange:function(e){var n=e.target.value||"";(""===n||/^\d+$/.exec(n))&&d({slave_instance_count:n})},paddingHorizontal:0,paddingVertical:0,placeholder:"e.g. 2",value:(null===f||void 0===f?void 0:f.slave_instance_count)||""})})]})})]}),(0,P.jsx)(g.Z,{mb:b.HN}),(0,P.jsx)(de,{addButtonText:"Add Spark configuration",addTextInputPlaceholder:"e.g. spark.driver.cores",alreadyExistsMessage:"Spark configuration exists",configurationValuePlaceholder:"e.g. 4g",configurations:null===f||void 0===f?void 0:f.master_spark_properties,createButtonText:"Create Spark configuration",description:(0,P.jsxs)(P.Fragment,{children:[(0,P.jsxs)(Z.ZP,{muted:!0,children:["List of key-value pairs to be set in ",(0,P.jsx)(Z.ZP,{inline:!0,monospace:!0,muted:!0,children:"SparkConf"})," for the master instance."]}),(0,P.jsxs)(Z.ZP,{muted:!0,children:["For a list of all configurations, see the ",(0,P.jsx)(q.Z,{href:"https://spark.apache.org/docs/latest/configuration.html",inline:!0,openNewWindow:!0,children:"Spark configuration documentation"}),"."]})]}),emptyState:"There are currently no Spark configurations for the master instance.",setConfigurations:function(e){return d({master_spark_properties:e})},title:"Master Spark configurations"}),(0,P.jsx)(g.Z,{mb:b.HN}),(0,P.jsx)(de,{addButtonText:"Add Spark configuration",addTextInputPlaceholder:"e.g. spark.driver.cores",alreadyExistsMessage:"Spark configuration exists",configurationValuePlaceholder:"e.g. 4g",configurations:null===f||void 0===f?void 0:f.slave_spark_properties,createButtonText:"Create Spark configuration",description:(0,P.jsxs)(P.Fragment,{children:[(0,P.jsxs)(Z.ZP,{muted:!0,children:["List of key-value pairs to be set in ",(0,P.jsx)(Z.ZP,{inline:!0,monospace:!0,muted:!0,children:"SparkConf"})," for the slave instance."]}),(0,P.jsxs)(Z.ZP,{muted:!0,children:["For a list of all configurations, see the ",(0,P.jsx)(q.Z,{href:"https://spark.apache.org/docs/latest/configuration.html",inline:!0,openNewWindow:!0,children:"Spark configuration documentation"}),"."]})]}),emptyState:"There are currently no Spark configurations for the slave instance.",setConfigurations:function(e){return d({slave_spark_properties:e})},title:"Slave Spark configurations"}),(0,P.jsx)(g.Z,{mb:b.HN}),(0,P.jsxs)(O.Z,{noPadding:!0,children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsx)(h.ZP,{alignItems:"center",justifyContent:"space-between",children:(0,P.jsxs)(x.Z,{flex:1,flexDirection:"column",children:[(0,P.jsx)(j.Z,{level:4,children:"Security"}),(0,P.jsx)(g.Z,{mt:1,children:(0,P.jsx)(Z.ZP,{muted:!0,children:"Configure security groups for EMR cluster instances."})})]})})}),(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsxs)(h.ZP,{flexDirection:"column",children:[(0,P.jsx)(Z.ZP,{default:!0,large:!0,children:"Master security group"}),(0,P.jsxs)(Z.ZP,{muted:!0,small:!0,children:["The default managed security group is ",(0,P.jsx)(Z.ZP,{inline:!0,monospace:!0,muted:!0,small:!0,children:"ElasticMapReduce-master"}),"."]})]}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,children:(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,autoComplete:"off",large:!0,noBackground:!0,noBorder:!0,fullWidth:!0,onChange:function(e){return d({master_security_group:e.target.value})},paddingHorizontal:0,paddingVertical:0,placeholder:"e.g. sg-xxxxxxxxxxxx",value:(null===f||void 0===f?void 0:f.master_security_group)||""})})]})}),(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsxs)(h.ZP,{flexDirection:"column",children:[(0,P.jsx)(Z.ZP,{default:!0,large:!0,children:"Slave security group"}),(0,P.jsxs)(Z.ZP,{muted:!0,small:!0,children:["The default managed security group is ",(0,P.jsx)(Z.ZP,{inline:!0,monospace:!0,muted:!0,small:!0,children:"ElasticMapReduce-slave"}),"."]})]}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,children:(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,autoComplete:"off",large:!0,noBackground:!0,noBorder:!0,fullWidth:!0,onChange:function(e){return d({slave_security_group:e.target.value})},paddingHorizontal:0,paddingVertical:0,placeholder:"e.g. sg-yyyyyyyyyyyy",value:(null===f||void 0===f?void 0:f.slave_security_group)||""})})]})})]}),(0,P.jsx)(g.Z,{mb:b.HN})]}),(0,P.jsxs)(h.ZP,{children:[(0,P.jsx)(a.ZP,{beforeIcon:(0,P.jsx)(w.vc,{}),disabled:!t||!(null!==(n=Object.keys(t))&&void 0!==n&&n.length),loading:r,onClick:function(){return i()},primary:!0,children:"Save changes"}),c&&(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(a.ZP,{onClick:function(){return null===c||void 0===c?void 0:c()},secondary:!0,children:"Cancel and go back"})]})]})]})},he=t(21831),je=t(77456),xe=t(86735);function ge(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function Ze(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?ge(Object(t),!0).forEach((function(n){(0,c.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):ge(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var be=function(e){var n,t,r=e.attributesTouched,i=e.computeService,l=e.isLoading,c=e.mutateObject,s=e.objectAttributes,u=e.onCancel,d=e.selectedComputeService,p=e.setObjectAttributes,f=(0,o.useCallback)((function(e){return p({emr_config:Ze(Ze({},null===s||void 0===s?void 0:s.emr_config),e)})}),[s,p]),v=(0,o.useCallback)((function(e){return p({spark_config:Ze(Ze({},null===s||void 0===s?void 0:s.spark_config),e)})}),[s,p]),y=(0,o.useMemo)((function(){return(null===s||void 0===s?void 0:s.emr_config)||{}}),[s]),_=(0,o.useMemo)((function(){return(null===s||void 0===s?void 0:s.spark_config)||{}}),[s]),k=(0,o.useRef)(null),C=((0,o.useRef)(null),(0,o.useState)(!1)),I=C[0],E=C[1],T=(0,o.useState)(null),D=T[0],M=T[1],A=(0,o.useMemo)((function(){return(null===_||void 0===_?void 0:_.spark_jars)||[]}),[_]),R=(0,o.useMemo)((function(){return(null===A||void 0===A?void 0:A.length)>=1}),[A]),B=(0,o.useMemo)((function(){return(A||[]).includes(D)}),[A,D]),N=(0,o.useMemo)((function(){return(0,P.jsxs)(h.ZP,{alignItems:"center",children:[!I&&(0,P.jsx)(a.ZP,{beforeIcon:(0,P.jsx)(w.mm,{}),compact:!0,onClick:function(e){(0,F.j)(e),E(!0),setTimeout((function(){var e;return null===k||void 0===k||null===(e=k.current)||void 0===e?void 0:e.focus()}),1)},secondary:!R,small:!0,children:"Add JAR file"}),I&&(0,P.jsxs)(P.Fragment,{children:[B&&(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(Z.ZP,{danger:!0,small:!0,children:"JAR file exists"}),(0,P.jsx)(g.Z,{mr:1})]}),(0,P.jsx)(ce.Z,{autoComplete:"off",compact:!0,meta:{touched:!!B,error:""},monospace:!0,onClick:function(e){return(0,F.j)(e)},paddingVertical:b.iI/2-2,onChange:function(e){(0,F.j)(e),M(e.target.value)},ref:k,small:!0,value:D||""}),(0,P.jsx)(g.Z,{mr:1}),(0,P.jsx)(a.ZP,{disabled:B,compact:!0,onClick:function(e){(0,F.j)(e),B||(v({spark_jars:A.concat(D)}),E(!1),M(null))},primary:!0,small:!0,children:"Add JAR file"}),(0,P.jsx)(g.Z,{mr:1}),(0,P.jsx)(a.ZP,{compact:!0,onClick:function(e){(0,F.j)(e),E(!1),M(null)},secondary:!0,small:!0,children:"Cancel"})]})]})}),[B,A,R,I,D,k,E,M]),z=(0,o.useMemo)((function(){return null===A||void 0===A?void 0:A.map((function(e,n){return(0,P.jsxs)("div",{children:[(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsx)(a.ZP,{iconOnly:!0,noBackground:!0,noBorder:!0,noPadding:!0,onClick:function(){var e=(0,he.Z)(A);v({spark_jars:(0,xe.oM)(e,n)})},children:(0,P.jsx)(w.rF,{default:!0,size:se.Z})}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsxs)(Z.ZP,{default:!0,large:!0,monospace:!0,children:["File ",n+1]}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,children:(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,fullWidth:!0,large:!0,monospace:!0,noBackground:!0,noBorder:!0,onChange:function(e){var t=(0,he.Z)(A);t[n]=e.target.value,v({spark_jars:t})},paddingHorizontal:0,paddingVertical:0,placeholder:"e.g. /home/path/example1.jar",value:e||""})})]})})]},e)}))}),[A,v]),H=(0,o.useMemo)((function(){var e="remote_variables_dir",n=null===i||void 0===i?void 0:i.setup_steps,t=null===n||void 0===n?void 0:n.find((function(n){return n.uuid===e}));return(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"flex-start",children:[(0,P.jsxs)(h.ZP,{flexDirection:"column",children:[(0,P.jsxs)(Z.ZP,{danger:!(null!==s&&void 0!==s&&s.remote_variables_dir)||!(null===t||void 0===t||!t.error),default:!0,large:!0,children:["Remote variables directory ",!(null!==s&&void 0!==s&&s.remote_variables_dir)&&(0,P.jsx)(Z.ZP,{danger:!0,inline:!0,large:!0,children:"is required"})]}),(0,P.jsx)(Z.ZP,{muted:!0,small:!0,children:"This S3 bucket will be used by Spark."})]}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsxs)(x.Z,{flex:1,flexDirection:"column",children:[(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,large:!0,monospace:!0,noBackground:!0,noBorder:!0,fullWidth:!0,onChange:function(e){return p({remote_variables_dir:e.target.value})},paddingHorizontal:0,paddingVertical:0,placeholder:"e.g. s3://magically-powerful-bucket",value:(null===s||void 0===s?void 0:s.remote_variables_dir)||""}),(null===t||void 0===t?void 0:t.error)&&(0,P.jsx)(h.ZP,{justifyContent:"flex-end",children:(0,P.jsx)(g.Z,{mt:1,children:(0,P.jsx)(je.Z,{error:null===t||void 0===t?void 0:t.error})})})]})]})})]})}),[i,s,p]);return(0,P.jsxs)(se.N,{children:[(0,P.jsxs)(O.Z,{noPadding:!0,children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsx)(j.Z,{level:4,children:"Setup"})}),(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsxs)(Z.ZP,{danger:"app_name"in r&&!(null!==_&&void 0!==_&&_.app_name),default:!0,large:!0,children:["Application name ","app_name"in r&&!(null!==_&&void 0!==_&&_.app_name)&&(0,P.jsx)(Z.ZP,{danger:!0,inline:!0,large:!0,children:"is required"})]}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,children:(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,autoComplete:"off",large:!0,noBackground:!0,noBorder:!0,fullWidth:!0,onChange:function(e){return v({app_name:e.target.value})},paddingHorizontal:0,paddingVertical:0,placeholder:"e.g. Sparkmage",value:(null===_||void 0===_?void 0:_.app_name)||""})})]})}),(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"flex-start",children:[(0,P.jsxs)(h.ZP,{flexDirection:"column",children:[(0,P.jsxs)(Z.ZP,{danger:"spark_master"in r&&!(null!==_&&void 0!==_&&_.spark_master),default:!0,large:!0,children:["Master URL ","spark_master"in r&&!(null!==_&&void 0!==_&&_.spark_master)&&(0,P.jsx)(Z.ZP,{danger:!0,inline:!0,large:!0,children:"is required"})]}),(0,P.jsx)(Z.ZP,{muted:!0,small:!0,children:"The URL for connecting to the master."})]}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,children:(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,large:!0,noBackground:!0,noBorder:!0,fullWidth:!0,onChange:function(e){return v({spark_master:e.target.value})},paddingHorizontal:0,paddingVertical:0,placeholder:"e.g. local, yarn, spark://host:port",value:(null===_||void 0===_?void 0:_.spark_master)||""})})]})}),(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"flex-start",children:[(0,P.jsxs)(h.ZP,{flexDirection:"column",children:[(0,P.jsx)(Z.ZP,{default:!0,large:!0,children:"Spark home directory"}),(0,P.jsx)(Z.ZP,{muted:!0,small:!0,children:"Path where Spark is installed on worker nodes."})]}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,children:(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,large:!0,monospace:!0,noBackground:!0,noBorder:!0,fullWidth:!0,onChange:function(e){return v({spark_home:e.target.value})},paddingHorizontal:0,paddingVertical:0,placeholder:"e.g. /usr/lib/spark",value:(null===_||void 0===_?void 0:_.spark_home)||""})})]})}),pe.GO.AWS_EMR===d&&H]}),(0,P.jsx)(g.Z,{mb:b.HN}),(null===i||void 0===i?void 0:i.connection_credentials)&&(0,P.jsxs)(P.Fragment,{children:[(0,P.jsxs)(O.Z,{noPadding:!0,children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsx)(j.Z,{level:4,children:"Credentials"})}),null===i||void 0===i||null===(n=i.connection_credentials)||void 0===n?void 0:n.map((function(e){var n=e.description,t=e.error,r=e.name,i=e.required,l=e.uuid,o=e.valid,c=e.value;return(0,P.jsxs)("div",{children:[(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsxs)(h.ZP,{flexDirection:"column",children:[(0,P.jsxs)(Z.ZP,{danger:!o,default:!0,large:!0,monospace:!r,children:[r||l," ",!o&&(0,P.jsx)(Z.ZP,{danger:!0,inline:!0,large:!0,children:"is invalid"})]}),n&&(0,P.jsx)(Z.ZP,{muted:!0,small:!0,children:n})]}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsxs)(x.Z,{flex:1,justifyContent:"flex-end",children:[!o&&(0,P.jsxs)(P.Fragment,{children:[!t&&i&&(0,P.jsx)(Z.ZP,{muted:!0,large:!0,children:"Required but missing"}),!t&&!i&&(0,P.jsx)(Z.ZP,{muted:!0,large:!0,children:"Invalid"}),t&&(0,P.jsx)(je.Z,{error:t,large:!0})]}),o&&c&&(0,P.jsx)(Z.ZP,{default:!0,large:!0,children:c})]})]})})]},l)}))]}),(0,P.jsx)(g.Z,{mb:b.HN})]}),(0,P.jsxs)(O.Z,{noPadding:!0,children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsx)(j.Z,{level:4,children:"Customizations"})}),(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"flex-start",children:[(0,P.jsxs)(h.ZP,{flexDirection:"column",children:[(0,P.jsx)(Z.ZP,{default:!0,large:!0,children:"Use custom session"}),(0,P.jsxs)(Z.ZP,{muted:!0,small:!0,children:["Whether to create custom SparkSession via",(0,P.jsx)("br",{}),"code and set it in ",(0,P.jsx)(Z.ZP,{inline:!0,monospace:!0,muted:!0,small:!0,children:"kwargs['context']"}),"."]})]}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,justifyContent:"flex-end",children:(0,P.jsx)(S.Z,{checked:null===_||void 0===_?void 0:_.use_custom_session,compact:!0,onCheck:function(e){return v({use_custom_session:e(null===_||void 0===_?void 0:_.use_custom_session)})}})})]})}),(null===_||void 0===_?void 0:_.use_custom_session)&&(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(m.Z,{light:!0}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"flex-start",children:[(0,P.jsxs)(h.ZP,{flexDirection:"column",children:[(0,P.jsx)(Z.ZP,{default:!0,large:!0,children:"Custom session variable"}),(0,P.jsxs)(Z.ZP,{muted:!0,small:!0,children:["The variable name to set in ",(0,P.jsx)(Z.ZP,{inline:!0,monospace:!0,muted:!0,small:!0,children:"kwargs['context']"}),",",(0,P.jsx)("br",{}),"e.g. If variable name is ",(0,P.jsx)(Z.ZP,{inline:!0,monospace:!0,muted:!0,small:!0,children:"spark"})," then the Spark session",(0,P.jsx)("br",{}),"is accessed using ",(0,P.jsx)(Z.ZP,{inline:!0,monospace:!0,muted:!0,small:!0,children:"kwargs['context']['spark']"}),"."]})]}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,children:(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,large:!0,monospace:!0,noBackground:!0,noBorder:!0,fullWidth:!0,onChange:function(e){return v({custom_session_var_name:e.target.value})},paddingHorizontal:0,paddingVertical:0,placeholder:"e.g. spark",value:(null===_||void 0===_?void 0:_.custom_session_var_name)||""})})]})})]}),pe.GO.AWS_EMR===d&&(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsxs)(h.ZP,{flexDirection:"column",children:[(0,P.jsx)(Z.ZP,{default:!0,large:!0,children:"Bootstrap script path"}),(0,P.jsx)(Z.ZP,{muted:!0,small:!0,children:"Use a custom script to bootstrap the EMR cluster."})]}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(x.Z,{flex:1,children:(0,P.jsx)(ce.Z,{afterIcon:(0,P.jsx)(w.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:se.Z,alignRight:!0,autoComplete:"off",large:!0,noBackground:!0,noBorder:!0,fullWidth:!0,onChange:function(e){return f({bootstrap_script_path:e.target.value})},paddingHorizontal:0,paddingVertical:0,placeholder:"e.g. /path/to/emr_bootstrap.sh",value:(null===y||void 0===y?void 0:y.bootstrap_script_path)||""})})]})})]}),(0,P.jsx)(g.Z,{mb:b.HN}),(0,P.jsx)(de,{addButtonText:"Add environment variable",addTextInputPlaceholder:"e.g. PYTHONPATH",alreadyExistsMessage:"Environment variable exists",configurationValuePlaceholder:"e.g. /home/path",configurations:null===_||void 0===_?void 0:_.executor_env,createButtonText:"Create environment variable",description:(0,P.jsx)(Z.ZP,{muted:!0,children:"Environment variables for the executor."}),emptyState:"There are currently no executor environment variables.",setConfigurations:function(e){return v({executor_env:e})},title:"Environment variables"}),(0,P.jsx)(g.Z,{mb:b.HN}),(0,P.jsxs)(O.Z,{noPadding:!0,children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"flex-start",justifyContent:"space-between",children:[(0,P.jsxs)(x.Z,{flex:1,flexDirection:"column",children:[(0,P.jsx)(j.Z,{level:4,children:"JAR files"}),(0,P.jsx)(g.Z,{mt:1,children:(0,P.jsxs)(Z.ZP,{muted:!0,children:["These files will be to be uploaded to the cluster and added to the ",(0,P.jsx)(Z.ZP,{inline:!0,monospace:!0,muted:!0,children:"classpath"}),"."]})})]}),(0,P.jsx)(g.Z,{mr:b.cd}),R&&(0,P.jsx)(h.ZP,{alignItems:"center",children:N})]})}),!R&&(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(m.Z,{light:!0}),(0,P.jsxs)(g.Z,{p:b.cd,children:[(0,P.jsx)(g.Z,{mb:b.cd,children:(0,P.jsx)(Z.ZP,{default:!0,children:"There are currently no JAR files."})}),(0,P.jsx)(h.ZP,{alignItems:"center",children:N})]})]}),R&&z]}),(0,P.jsx)(g.Z,{mb:b.HN}),(0,P.jsxs)(h.ZP,{children:[(0,P.jsx)(a.ZP,{beforeIcon:(0,P.jsx)(w.vc,{}),disabled:!r||!(null!==(t=Object.keys(r))&&void 0!==t&&t.length),loading:l,onClick:function(){return c()},primary:!0,children:"Save changes"}),u&&(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(a.ZP,{onClick:function(){return null===u||void 0===u?void 0:u()},secondary:!0,children:"Cancel and go back"})]})]})]})},Pe=t(35185);var ye=function(e){var n=e.computeService,t=e.onClick,r=(0,o.useMemo)((function(){var e,t=[],r=0;return null===n||void 0===n||null===(e=n.setup_steps)||void 0===e||e.forEach((function(e){var n=e.group,i=e.required,l=e.status_calculated,o=e.steps;n?null===o||void 0===o||o.forEach((function(e){t.push(e);var n=e.required,i=e.status_calculated;n&&pe.br.COMPLETED!==i||(r+=1)})):(t.push(e),i&&pe.br.COMPLETED!==l||(r+=1))})),{steps:t,stepsCompleted:r}}),[n]),i=r.steps,l=r.stepsCompleted,c=(0,o.useMemo)((function(){return(null===i||void 0===i?void 0:i.length)||1}),[i]),s=(0,o.useMemo)((function(){return l/c}),[l,c]);return(0,P.jsxs)(q.Z,{block:!0,noHoverUnderline:!0,noOutline:!0,onClick:t?function(){return null===t||void 0===t?void 0:t()}:null,preventDefault:!0,children:[(0,P.jsx)(m.Z,{light:!0}),(0,P.jsxs)(g.Z,{p:b.cd,children:[(0,P.jsx)(g.Z,{mb:1,children:(0,P.jsxs)(Z.ZP,{monospace:!0,muted:!0,children:[(0,P.jsx)(Z.ZP,{default:!0,inline:!0,children:l})," / ",(0,P.jsx)(Z.ZP,{default:!0,inline:!0,children:c})," ",(0,R._6)("step",c,!1,!0)," completed"]})}),(0,P.jsx)(Pe.Z,{progress:100*s})]}),(0,P.jsx)(m.Z,{light:!0})]})},_e=t(78688),ke=t(72748),Oe=t(32013),Ce=t(98777);function Ie(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function Se(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?Ie(Object(t),!0).forEach((function(n){(0,c.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):Ie(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var Ee="Environment",we="Executors";var Te=function(e){e.objectAttributes;var n,t=(0,o.useContext)(D.ThemeContext),r=(0,o.useState)(Ee),i=r[0],l=r[1],c=E.ZP.spark_executors.list().data,u=(0,o.useMemo)((function(){return null===c||void 0===c?void 0:c.spark_executors}),[c]),a=E.ZP.spark_environments.detail("0").data,d=(0,o.useMemo)((function(){return null===a||void 0===a?void 0:a.spark_environment}),[a]),p=(0,o.useMemo)((function(){var e,n,t,r,i,l,c;return(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(g.Z,{px:b.cd,children:(0,P.jsxs)(Oe.Z,{noBoxShadow:!0,children:[(0,P.jsxs)(Ce.Z,{noPaddingContent:!0,title:"Runtime",children:[(0,P.jsx)(I.Z,{columnFlex:[null,null],columns:[{uuid:"Property"},{uuid:"Value"}],rows:null===(e=Object.entries((null===d||void 0===d?void 0:d.runtime)||{}))||void 0===e?void 0:e.map((function(e){return[(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"property"}),e[0]),(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"value"}),e[1])]}))}),(0,P.jsx)(g.Z,{p:1})]}),(0,P.jsxs)(Ce.Z,{noPaddingContent:!0,title:"Hadoop properties",children:[(0,P.jsx)(I.Z,{columnFlex:[null,null],columns:[{uuid:"Property"},{uuid:"Value"}],rows:null===d||void 0===d||null===(n=d.hadoop_properties)||void 0===n?void 0:n.map((function(e){return[(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"property"}),e[0]),(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"value"}),e[1])]}))}),(0,P.jsx)(g.Z,{p:1})]}),(0,P.jsxs)(Ce.Z,{noPaddingContent:!0,title:"Metrics properties",children:[(0,P.jsx)(I.Z,{columnFlex:[null,null],columns:[{uuid:"Property"},{uuid:"Value"}],rows:null===d||void 0===d||null===(t=d.metrics_properties)||void 0===t?void 0:t.map((function(e){return[(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"property"}),e[0]),(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"value"}),e[1])]}))}),(0,P.jsx)(g.Z,{p:1})]}),(0,P.jsxs)(Ce.Z,{noPaddingContent:!0,title:"Spark properties",children:[(0,P.jsx)(I.Z,{columnFlex:[1,4],columns:[{uuid:"Property"},{uuid:"Value"}],rows:null===d||void 0===d||null===(r=d.spark_properties)||void 0===r?void 0:r.map((function(e){return[(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"property"}),e[0]),(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"value"}),e[1])]}))}),(0,P.jsx)(g.Z,{p:1})]}),(0,P.jsxs)(Ce.Z,{noPaddingContent:!0,title:"System properties",children:[(0,P.jsx)(I.Z,{columnFlex:[null,null],columns:[{uuid:"Property"},{uuid:"Value"}],rows:null===d||void 0===d||null===(i=d.system_properties)||void 0===i?void 0:i.map((function(e){return[(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"property"}),e[0]),(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"value"}),e[1])]}))}),(0,P.jsx)(g.Z,{p:1})]}),(0,P.jsxs)(Ce.Z,{noPaddingContent:!0,title:"Classpath entries",children:[(0,P.jsx)(I.Z,{columnFlex:[null,null],columns:[{uuid:"Type"},{uuid:"Value"}],rows:null===d||void 0===d||null===(l=d.classpath_entries)||void 0===l?void 0:l.map((function(e){return[(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"type"}),e[1]),(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"value"}),e[0])]}))}),(0,P.jsx)(g.Z,{p:1})]})]})}),null===d||void 0===d||null===(c=d.resource_profiles)||void 0===c?void 0:c.map((function(e){var n=e.executor_resources,t=e.id,r=e.task_resources;return(0,P.jsxs)("div",{children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(j.Z,{level:4,children:["Executor resources ID ",t]})}),(0,P.jsx)(g.Z,{px:b.cd,children:(0,P.jsx)(Oe.Z,{noBoxShadow:!0,children:Object.entries(n||{}).map((function(e){var n,t=(0,s.Z)(e,2),r=t[0],i=t[1];return(0,P.jsxs)(Ce.Z,{noPaddingContent:!0,title:(0,R.vg)(r),children:[(0,P.jsx)(I.Z,{columnFlex:[1,2],columns:[{uuid:"Property"},{uuid:"Value"}],rows:null===(n=Object.entries(i))||void 0===n?void 0:n.map((function(e){return[(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"property"}),(0,R.vg)(e[0])),(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"value"}),e[1]||"-")]}))}),(0,P.jsx)(g.Z,{p:1})]},r)}))})}),(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(j.Z,{level:4,children:["Task resources ID ",t]})}),(0,P.jsx)(g.Z,{px:b.cd,children:(0,P.jsx)(Oe.Z,{noBoxShadow:!0,children:Object.entries(r||{}).map((function(e){var n,t=(0,s.Z)(e,2),r=t[0],i=t[1];return(0,P.jsxs)(Ce.Z,{noPaddingContent:!0,title:(0,R.vg)(r),children:[(0,P.jsx)(I.Z,{columnFlex:[1,2],columns:[{uuid:"Property"},{uuid:"Value"}],rows:null===(n=Object.entries(i))||void 0===n?void 0:n.map((function(e){return[(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"property"}),(0,R.vg)(e[0])),(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"value"}),e[1]||"-")]}))}),(0,P.jsx)(g.Z,{p:1})]},r)}))})})]},t)}))]})}),[d]),f=(0,o.useMemo)((function(){return null===u||void 0===u?void 0:u.map((function(e){return(0,P.jsxs)("div",{children:[(0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(j.Z,{level:4,children:["Executor ",null===e||void 0===e?void 0:e.id]})}),(0,P.jsx)(g.Z,{px:b.cd,children:(0,P.jsxs)(Oe.Z,{noBoxShadow:!0,children:[(0,P.jsxs)(Ce.Z,{noPaddingContent:!0,title:"Metrics",children:[(0,P.jsx)(I.Z,{columnFlex:[1,2],columns:[{uuid:"Metric"},{uuid:"Value"}],rows:["active_tasks","add_time","completed_tasks","disk_used","failed_tasks","host_port","is_active","is_blacklisted","is_excluded","max_memory","max_tasks","memory_used","rdd_blocks","resource_profile_id","total_cores","total_duration","total_gc_time","total_input_bytes","total_shuffle_read","total_shuffle_write","total_tasks"].map((function(n){var t=null===e||void 0===e?void 0:e[n];return[(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"property"}),(0,R.vg)(n)),(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"value"}),"undefined"===typeof t?"-":"boolean"===typeof t?String(t):t)]}))}),(0,P.jsx)(g.Z,{p:1})]}),(0,P.jsxs)(Ce.Z,{noPaddingContent:!0,title:"Memory metrics",children:[(0,P.jsx)(I.Z,{columnFlex:[1,2],columns:[{uuid:"Metric"},{uuid:"Value"}],rows:Object.entries((null===e||void 0===e?void 0:e.memory_metrics)||{}).map((function(e){var n=(0,s.Z)(e,2),t=n[0],r=n[1];return[(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"property"}),(0,R.vg)(t)),(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"value"}),"undefined"===typeof r?"-":"boolean"===typeof r?String(r):r)]}))}),(0,P.jsx)(g.Z,{p:1})]}),(0,P.jsxs)(Ce.Z,{noPaddingContent:!0,title:"Peak memory metrics",children:[(0,P.jsx)(I.Z,{columnFlex:[1,2],columns:[{uuid:"Metric"},{uuid:"Value"}],rows:Object.entries((null===e||void 0===e?void 0:e.peak_memory_metrics)||{}).map((function(e){var n=(0,s.Z)(e,2),t=n[0],r=n[1];return[(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"property"}),(0,R.vg)(t)),(0,o.createElement)(Z.ZP,Se(Se({},$.eB),{},{key:"value"}),"undefined"===typeof r?"-":"boolean"===typeof r?String(r):r)]}))}),(0,P.jsx)(g.Z,{p:1})]})]})})]},null===e||void 0===e?void 0:e.id)}))}),[u]);return(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(g.Z,{px:b.cd,children:(0,P.jsx)(J.Z,{noPadding:!0,onClickTab:function(e){var n=e.uuid;return l(n)},regularSizeText:!0,selectedTabUUID:i,tabs:[{label:function(){return Ee},uuid:Ee},{label:function(){return we},uuid:we}],underlineColor:null===t||void 0===t||null===(n=t.accent)||void 0===n?void 0:n.blue,underlineStyle:!0})}),(0,P.jsx)(g.Z,{mb:b.cd,children:(0,P.jsx)(m.Z,{light:!0})}),Ee===i&&p,we===i&&f]})},De=t(62547),Me=t(23657),Ae=t(74778),Re=t(46684),Be=t(53808),Ne=t(10332),Fe=t(15610),ze=t(69419),He=t(19183);function Le(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function We(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?Le(Object(t),!0).forEach((function(n){(0,c.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):Le(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var Ue=function(e){var n,t=e.contained,r=e.heightOffset,i=e.mainContainerRef,l=(0,He.i)(),d=l.height,p=(l.width,(0,o.useMemo)((function(){return"ComputeManagement/".concat(t?"contained":"open")}),[t])),f=(0,L.VI)(null,{},[],{uuid:p}),v=(0,s.Z)(f,1)[0],m=((0,o.useRef)(null),(0,o.useRef)(null),(0,o.useRef)(null),(0,o.useRef)(null)),y=(0,o.useMemo)((function(){return d-(r||0)}),[r,d]),_=(0,o.useState)(!1),k=_[0],O=_[1],C=(0,o.useState)(null),I=C[0],S=C[1],T=(0,Me.Z)({clustersRefreshInterval:1e4,includeAllStates:k}),D=T.activeCluster,M=T.clusters,A=T.clustersLoading,R=T.computeService,B=T.connections,F=T.connectionsLoading,H=T.fetchAll,W=T.setupComplete,U=(0,o.useState)(null),V=U[0],G=U[1];(0,o.useEffect)((function(){var e;G(null===m||void 0===m||null===(e=m.current)||void 0===e?void 0:e.getBoundingClientRect())}),[d,m]);var J=(0,o.useMemo)((function(){return"compute_management_after_width_".concat(p)}),[p]),K=(0,o.useMemo)((function(){return"compute_management_before_width_".concat(p)}),[p]),Y=(0,o.useState)((0,Be.U2)(J,60*b.iI)),Q=Y[0],ee=Y[1],ne=(0,o.useCallback)((function(e){ee(e),(0,Be.t8)(J,Math.max(e,60*b.iI))}),[J,ee]),te=(0,o.useState)(!1),re=te[0],ie=te[1],le=(0,o.useState)(Math.max((0,Be.U2)(K),20*b.iI)),ce=le[0],se=le[1],ue=(0,o.useCallback)((function(e){se(e||20*b.iI),(0,Be.t8)(K,e||20*b.iI)}),[K,se]),ae=(0,o.useState)(!1),de=ae[0],pe=ae[1],fe=(0,o.useState)(!0),ve=fe[0],he=fe[1],je=(0,o.useState)(null),xe=je[0],ge=je[1],Ze=(0,o.useCallback)((function(e){ge((function(n){var t=e(n);return t&&ve?he(!1):t||ve||!W||he(!0),t}))}),[ve,he,ge,W]),Pe=(0,o.useState)(null),Oe=Pe[0],Ce=Pe[1],Ie=(0,o.useCallback)((function(e){var n;(0,Fe.u7)((0,c.Z)({},"tab",null===(n="function"===typeof e?null===e||void 0===e?void 0:e():e)||void 0===n?void 0:n.main)),Ze((function(){return null}))}),[Ze]),Se=(0,ze.iV)();(0,o.useEffect)((function(){var e=null===Se||void 0===Se?void 0:Se.tab;(null===Oe||void 0===Oe?void 0:Oe.main)!==e&&Ce(e?{main:e}:null)}),[Oe,Se]);var Ee=(0,o.useState)(null),we=Ee[0],Le=Ee[1],Ue=(0,o.useState)({}),Ve=Ue[0],Ge=Ue[1],Xe=(0,o.useCallback)((function(e){Ge((function(n){return We(We({},n),e)})),Le((function(n){return We(We({},n),e)}))}),[Ge,Le]),qe=((0,o.useCallback)((function(e){return Xe({spark_config:We(We({},null===we||void 0===we?void 0:we.spark_config),e)})}),[we,Xe]),E.ZP.projects.list({},{revalidateOnFocus:!1}).data),Je=(0,o.useMemo)((function(){var e;return null===qe||void 0===qe||null===(e=qe.projects)||void 0===e?void 0:e[0]}),[qe]),Ke=(0,o.useMemo)((function(){return null===Je||void 0===Je?void 0:Je.name}),[Je]),Ye=E.ZP.spark_applications.list().data,Qe=(0,o.useMemo)((function(){return null===Ye||void 0===Ye?void 0:Ye.spark_applications}),[Ye]),$e=E.ZP.spark_jobs.list().data,en=(0,o.useMemo)((function(){return null===$e||void 0===$e?void 0:$e.spark_jobs}),[$e]);(0,o.useEffect)((function(){he(W)}),[W]),(0,o.useEffect)((function(){Je&&(Le(Je),S((0,Ne.d)(Je)))}),[Je,Le,S,Ie]),(0,o.useEffect)((function(){!Oe&&I&&Ie({main:$.uK.SETUP})}),[I,Oe,Ie]);var nn=(0,u.Db)(E.ZP.projects.useUpdate(Ke),{onSuccess:function(e){return(0,N.wD)(e,{callback:function(e){var n=e.project;Ge({}),Le(n),H()},onErrorCallback:function(e,n){return v({errors:n,response:e})}})}}),tn=(0,s.Z)(nn,2),rn=tn[0],ln=tn[1].isLoading,on=(0,o.useCallback)((function(e){return rn({project:(0,z.GL)(We(We({},we),e),["emr_config","remote_variables_dir","spark_config"])})}),[we,rn]),cn=(0,o.useMemo)((function(){var e=(0,$.kI)(R).map((function(e){var n,t=e.Icon,r=e.renderStatus,i=e.uuid;return r&&(n=null===r||void 0===r?void 0:r({applications:Qe,applicationsLoading:!Ye,clusters:M,clustersLoading:A,computeConnections:B,computeService:R,jobs:en,jobsLoading:!$e})),(0,P.jsx)(q.Z,{block:!0,disabled:!I,noHoverUnderline:!0,noOutline:!0,onClick:function(){return Ie((function(){return{main:i}}))},preventDefault:!0,children:(0,P.jsx)(Ae.bC,{selected:(null===Oe||void 0===Oe?void 0:Oe.main)===i,children:(0,P.jsxs)(h.ZP,{alignItems:"center",fullHeight:!0,justifyContent:"space-between",children:[(0,P.jsxs)(x.Z,{alignItems:"center",flex:1,children:[(0,P.jsx)(t,{size:2*b.iI}),(0,P.jsx)(g.Z,{mr:2}),(0,P.jsx)(Z.ZP,{bold:!0,large:!0,children:$.TD[i]})]}),n&&(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(g.Z,{mr:b.cd}),n]})]})})},i)}));if(I){var n=String(I),t=$.l[n],r=$.Eb[n],i=$.LF[n];if(t&&r&&i){var l,o;null!==R&&void 0!==R&&R.setup_steps&&(o=W?D?null!==D&&void 0!==D&&D.ready?"Cluster is ready, commence coding.":"Cluster activated and initializing.":"Setup complete but no clusters activated.":"All setup steps have not been completed yet.");var c=[];null!==R&&void 0!==R&&R.setup_steps&&c.push((0,P.jsx)(g.Z,{py:1,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[W&&(0,P.jsx)(w.Fs,{muted:!(null!==D&&void 0!==D&&D.ready),size:1.5*b.iI,success:null===D||void 0===D?void 0:D.ready}),!W&&(0,P.jsx)(w.uy,{danger:!0,size:1.5*b.iI}),(0,P.jsx)(g.Z,{mr:1}),(0,P.jsxs)(x.Z,{flex:1,flexDirection:"column",children:[(0,P.jsx)(Z.ZP,{default:!W||!D,small:!0,children:W&&D?"Compute service connected":"Compute service unconnected"}),o&&(0,P.jsx)(Z.ZP,{muted:!0,xsmall:!0,children:o})]})]})},"compute-service-setup-steps")),(null===R||void 0===R||null===(l=R.setup_steps)||void 0===l?void 0:l.length)>=1&&!W&&e.unshift((0,P.jsx)(ye,{computeService:R,onClick:function(){return he(!1)}},"setupProgress")),e.unshift((0,P.jsx)(g.Z,{p:b.cd,children:(0,P.jsxs)(Ae.UE,{inline:!0,children:[(0,P.jsxs)(h.ZP,{alignItems:"flex-start",children:[(0,P.jsx)(x.Z,{flex:1,children:i()}),(0,P.jsx)(a.ZP,{compact:!0,onClick:function(){S(null),Ie(null)},secondary:!0,small:!0,children:"Change"})]}),(0,P.jsx)(g.Z,{mt:b.cd,children:(0,P.jsx)(h.ZP,{alignItems:"flex-end",children:(0,P.jsxs)(x.Z,{flex:1,flexDirection:"column",children:[(0,P.jsx)(Z.ZP,{default:!0,monospace:!0,children:r}),(0,P.jsx)(j.Z,{level:5,children:t})]})})}),(null===c||void 0===c?void 0:c.length)>=1&&(0,P.jsx)(g.Z,{mt:b.cd,children:c})]})},"".concat(t,"-").concat(r)))}}return e}),[D,Qe,M,A,R,B,Ye,$e,en,I,Oe,he,Ie,W]),sn=(0,o.useMemo)((function(){var e;return xe?(0,P.jsx)(ke.Z,{height:y-(((null===V||void 0===V?void 0:V.height)||0)+Re.Mz+1),model:xe}):(null===R||void 0===R||null===(e=R.setup_steps)||void 0===e?void 0:e.length)>=1?(0,P.jsx)(_e.Z,{onClickStep:function(e){return Ie((function(){return{main:e}}))},setupSteps:null===R||void 0===R?void 0:R.setup_steps}):void 0}),[R,y,xe,W]),un=(0,o.useMemo)((function(){return(0,P.jsx)(be,{attributesTouched:Ve||{},computeService:R,isLoading:ln,mutateObject:on,objectAttributes:we,selectedComputeService:I,setObjectAttributes:Xe})}),[Ve,R,ln,we,I,Xe,on]),an=(0,o.useMemo)((function(){return(0,P.jsx)(me,{attributesTouched:Ve||{},isLoading:ln,mutateObject:on,objectAttributes:we,selectedComputeService:I,setObjectAttributes:Xe})}),[Ve,ln,we,I,Xe,on]),dn=(0,o.useMemo)((function(){if([$.B2.AWS_EMR,$.B2.STANDALONE_CLUSTER].includes(I))return(0,P.jsx)(oe,{applications:Qe,computeConnections:B,computeService:R,connectionsLoading:F,fetchAll:H,jobs:en,loadingApplications:!Ye,loadingJobs:!$e,objectAttributes:we,refButtonTabs:m,selectedComputeService:I,setSelectedSql:Ze,setSelectedTab:Ie})}),[Qe,R,B,F,H,Ye,$e,en,we,m,I,Ze,Ie]),pn=(0,o.useMemo)((function(){if([$.B2.AWS_EMR,$.B2.STANDALONE_CLUSTER].includes(I))return(0,P.jsx)(Te,{objectAttributes:we})}),[we,I]),fn=(0,o.useMemo)((function(){return(0,P.jsxs)(g.Z,{mx:1,py:b.cd,children:[(0,P.jsx)(g.Z,{mb:b.cd,px:b.cd,children:(0,P.jsx)(j.Z,{children:"Select a compute service"})}),(0,P.jsx)(h.ZP,{alignItems:"center",flexWrap:"wrap",children:$.sY.map((function(e){var n=e.buildPayload,t=e.displayName,r=e.documentationHref,i=e.kicker,l=e.renderIcon,o=e.uuid;return(0,P.jsxs)(Ae.UE,{children:[l(),(0,P.jsxs)(g.Z,{mt:b.cd,children:[(0,P.jsx)(Z.ZP,{default:!0,monospace:!0,children:i}),(0,P.jsx)(j.Z,{level:4,children:t})]}),(0,P.jsx)(g.Z,{mt:b.cd,children:(0,P.jsxs)(h.ZP,{alignItems:"center",children:[(0,P.jsx)(a.ZP,{loading:ln&&o===I,onClick:function(){S(o),on(n(we))},primary:!0,children:"Enable"}),(0,P.jsx)(g.Z,{mr:b.cd}),(0,P.jsx)(q.Z,{href:r,default:!0,openNewWindow:!0,children:"View setup documentation"})]})})]},o)}))})]})}),[ln,we,I,S,on]),vn=(0,o.useMemo)((function(){return(0,P.jsx)(X,{clusters:M,computeService:R,fetchAll:H,includeAllStates:k,loading:A,setIncludeAllStates:O})}),[M,A,R,H,k,O]),mn=(0,o.useMemo)((function(){if(!I&&we)return fn;if(I&&Je&&null!==Oe&&void 0!==Oe&&Oe.main){var e=null===Oe||void 0===Oe?void 0:Oe.main;if($.uK.SETUP===e)return un;if($.uK.RESOURCES===e)return an;if($.uK.MONITORING===e)return dn;if($.uK.SYSTEM===e)return pn;if($.uK.CLUSTERS===e)return vn}}),[vn,fn,dn,we,Je,an,I,Oe,un,pn]);return(0,P.jsx)(De.Z,{after:sn,afterDividerContrast:!0,afterHeightOffset:Re.Mz,afterHidden:ve&&!xe,afterMousedownActive:re,afterWidth:Q,before:cn,beforeDividerContrast:!0,beforeHeightOffset:0,beforeHidden:!I,beforeMousedownActive:de,beforeWidth:ce,contained:!0,height:y,hideAfterCompletely:!(null!==R&&void 0!==R&&null!==(n=R.setup_steps)&&void 0!==n&&n.length),hideBeforeCompletely:!I,inline:!0,mainContainerRef:i,setAfterHidden:he,setAfterMousedownActive:ie,setAfterWidth:ne,setBeforeMousedownActive:pe,setBeforeWidth:ue,uuid:p,children:mn})},Ve=t(94629),Ge=t(93808);function Xe(){var e=(0,o.useRef)(null);return(0,P.jsx)(Ve.Z,{title:"Compute management",uuid:"Compute management/index",children:(0,P.jsx)("div",{ref:e,children:(0,P.jsx)(Ue,{heightOffset:Re.Mz,mainContainerRef:e})})})}Xe.getInitialProps=(0,r.Z)(l().mark((function e(){return l().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",{});case 1:case"end":return e.stop()}}),e)})));var qe=(0,Ge.Z)(Xe)},23657:function(e,n,t){"use strict";var r=t(82394),i=t(75582),l=t(82684),o=t(74260),c=t(35686),s=t(77417);function u(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function a(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?u(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):u(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}n.Z=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.clustersRefreshInterval,t=e.computeServiceRefreshInterval,u=e.connectionsRefreshInterval,d=e.includeAllStates,p=(0,s.Z)(),f=p.sparkEnabled,v=c.ZP.compute_services.detail("compute-service",{},{refreshInterval:t},{pauseFetch:!f}),m=v.data,h=v.mutate,j=(0,l.useMemo)((function(){return null===m||void 0===m?void 0:m.compute_service}),[m]),x={};d&&(x.include_all_states=!0);var g=c.ZP.compute_clusters.compute_services.list(null===j||void 0===j?void 0:j.uuid,x,{refreshInterval:n},{pauseFetch:!f}),Z=g.data,b=g.mutate,P=(0,l.useMemo)((function(){return(null===Z||void 0===Z?void 0:Z.compute_clusters)||[]}),[Z]),y=(0,l.useMemo)((function(){return null===P||void 0===P?void 0:P.map((function(e){return e.cluster}))}),[P]),_=(0,l.useMemo)((function(){var e,n;return null!==j&&void 0!==j&&null!==(e=j.setup_steps)&&void 0!==e&&e.length?null===j||void 0===j||null===(n=j.setup_steps)||void 0===n?void 0:n.every((function(e){var n=e.required,t=e.status_calculated;return!n||!t||o.br.COMPLETED===t})):null}),[j]),k=((0,l.useMemo)((function(){return null===y||void 0===y?void 0:y.find((function(e){return e.active}))}),[y]),c.ZP.compute_connections.compute_services.list(null===j||void 0===j?void 0:j.uuid,{},{refreshInterval:u},{pauseFetch:!f})),O=k.data,C=k.mutate,I=(0,l.useMemo)((function(){return(null===O||void 0===O?void 0:O.compute_connections)||[]}),[O]),S=(0,l.useCallback)((function(){return new Promise((function(){null===b||void 0===b||b(),null===C||void 0===C||C(),null===h||void 0===h||h()}))}),[b,C,h]);return{activeCluster:null===y||void 0===y?void 0:y.find((function(e){return e.active})),clusters:y,clustersLoading:!Z,computeService:j,computeServiceUUIDs:Object.entries(o.GO).reduce((function(e,n){var t=(0,i.Z)(n,2),l=t[0],o=t[1];return a(a({},e),{},(0,r.Z)({},l,o))}),{}),connections:I,connectionsLoading:!O,fetchAll:S,fetchComputeClusters:b,fetchComputeConnections:C,fetchComputeService:h,setupComplete:_}}},42278:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/compute",function(){return t(4910)}])}},function(e){e.O(0,[9774,2678,1154,844,5820,4267,600,8487,8264,7858,5499,4366,722,90,2888,179],(function(){return n=42278,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3009],{92656:function(e,n,o){"use strict";o.r(n),o.d(n,{default:function(){return G}});var i=o(77837),t=o(38860),l=o.n(t),u=o(82684),r=o(71180),d=o(94629),s=o(8569),c=o(82394),a=o(12691),p=o.n(a),v=o(38626),h=o(34376),f=o(55485),b=o(48670),m=o(75499),k=o(30160),j=o(35686),_=o(72473),g=o(8193),y={default:!0,monospace:!0},w=o(81728),x=o(3917),P=o(55283),O=o(86735),Z=o(70320),E=o(28598);function C(e,n){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),o.push.apply(o,i)}return o}function N(e){for(var n=1;n<arguments.length;n++){var o=null!=arguments[n]?arguments[n]:{};n%2?C(Object(o),!0).forEach((function(n){(0,c.Z)(e,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):C(Object(o)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(o,n))}))}return e}var T=function(){var e=(0,Z.q)(),n=(0,u.useContext)(v.ThemeContext),o=(0,h.useRouter)(),i=(0,u.useState)(null),t=i[0],l=(i[1],j.ZP.global_hooks.list({_format:"with_pipeline_details",include_snapshot_validation:1}).data),r=(0,u.useMemo)((function(){return(null===l||void 0===l?void 0:l.global_hooks)||[]}),[l]);return(0,E.jsx)(E.Fragment,{children:(0,E.jsx)(m.Z,{columnFlex:[null,null,null,null,1,null,null],columns:[{uuid:"UUID"},{uuid:"Resource"},{uuid:"Operation"},{uuid:"Pipeline"},{uuid:"Outputs"},{center:!0,uuid:"Valid"},{rightAligned:!0,uuid:"Snapshotted at"}],onClickRow:function(e,n){var i=null===r||void 0===r?void 0:r[e],t=i.operation_type,l=i.resource_type,u=i.uuid;o.push("/global-hooks/".concat(u,"?operation_type=").concat(t,"&resource_type=").concat(l))},getObjectAtRowIndex:function(e){return null===r||void 0===r?void 0:r[e]},rows:null===r||void 0===r?void 0:r.map((function(o){var i,t=o.metadata,l=o.operation_type,r=o.outputs,d=o.pipeline,s=o.pipeline_details,c=o.resource_type,a=o.uuid,v=null===d||void 0===d?void 0:d.uuid,h=v?(0,E.jsx)(p(),{as:"/pipelines/".concat(v,"/edit"),href:"/pipelines/[pipeline]/edit",passHref:!0,children:(0,E.jsx)(b.Z,N(N({},y),{},{openNewWindow:!0,children:v}))},"pipeline"):(0,u.createElement)(k.ZP,N(N({},y),{},{key:"pipeline",muted:!0}),"-"),m=[];if((null===r||void 0===r?void 0:r.length)>=1&&(null===s||void 0===s||null===(i=s.blocks)||void 0===i?void 0:i.length)>=1){var j=(0,O.HK)((null===s||void 0===s?void 0:s.blocks)||[],(function(e){return e.uuid}));null===r||void 0===r||r.forEach((function(e,o){var i;if(null!==e&&void 0!==e&&null!==(i=e.block)&&void 0!==i&&i.uuid){var t,l=null===j||void 0===j?void 0:j[null===e||void 0===e||null===(t=e.block)||void 0===t?void 0:t.uuid];l&&(o>=1&&m.push((0,u.createElement)(k.ZP,N(N({},y),{},{inline:!0,key:"".concat(null===l||void 0===l?void 0:l.uuid,"-").concat(o,"-comma"),muted:!0}),",\xa0")),m.push((0,E.jsx)(p(),{as:"/pipelines/".concat(v,"/edit?block_uuid=").concat(null===l||void 0===l?void 0:l.uuid),href:"/pipelines/[pipeline]/edit",passHref:!0,children:(0,E.jsx)(b.Z,N(N({},y),{},{inline:!0,openNewWindow:!0,sameColorAsText:!0,children:(0,E.jsx)(k.ZP,N(N({},y),{},{color:(0,P.qn)(null===l||void 0===l?void 0:l.type,{blockColor:null===l||void 0===l?void 0:l.color,theme:n}).accent,inline:!0,children:null===l||void 0===l?void 0:l.uuid}))}))},"".concat(null===l||void 0===l?void 0:l.uuid,"-").concat(o,"-link"))))}}))}return[(0,u.createElement)(k.ZP,N(N({},y),{},{key:"uuid"}),a),(0,u.createElement)(k.ZP,N(N({},y),{},{key:"resourceType",monospace:!1}),c?(0,w.j3)(c):"-"),(0,u.createElement)(k.ZP,N(N({},y),{},{key:"operationType",monospace:!1}),l?(0,w.vg)(l):"-"),h,(0,E.jsxs)("div",{children:[(null===m||void 0===m?void 0:m.length)>=1&&m,!(null!==m&&void 0!==m&&m.length)&&(0,E.jsx)(k.ZP,N(N({},y),{},{muted:!0,children:"-"}))]},"outputs"),(0,E.jsx)(f.ZP,{justifyContent:"center",children:null!==t&&void 0!==t&&t.snapshot_valid?(0,E.jsx)(_.Jr,{size:g.Z,success:!0}):(0,E.jsx)(_.uy,{danger:!0,size:g.Z})},"valid"),(0,u.createElement)(k.ZP,N(N({},y),{},{key:"snapshottedAt",rightAligned:!0}),null!==t&&void 0!==t&&t.snapshotted_at?(0,x.XG)(null===t||void 0===t?void 0:t.snapshotted_at,e):"-")]})),selectedRowIndexInternal:t,uuid:"GlobalHooks/Table"})})},A=o(93808),I=o(70515),H=o(69419);function D(){var e=(0,u.useState)(!1),n=e[0],o=e[1],i=(0,H.iV)();return(0,u.useEffect)((function(){var e=i.new;o(!!e)}),[i]),(0,E.jsxs)(d.Z,{addProjectBreadcrumbToCustomBreadcrumbs:n,breadcrumbs:n?[{label:function(){return"Global hooks"},linkProps:{href:"/global-hooks"}},{bold:!0,label:function(){return"New"}}]:null,subheaderChildren:!n&&(0,E.jsx)(E.Fragment,{children:(0,E.jsx)(r.ZP,{beforeIcon:(0,E.jsx)(_.mm,{size:2.5*I.iI}),inline:!0,linkProps:{as:"/global-hooks?new=1",href:"/global-hooks"},noHoverUnderline:!0,primary:!0,sameColorAsText:!0,children:"Add new global hook"})}),title:"Global hooks",uuid:"GlobalHooks/index",children:[n&&(0,E.jsx)(s.Z,{isNew:n}),!n&&(0,E.jsx)(T,{})]})}D.getInitialProps=(0,i.Z)(l().mark((function e(){return l().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",{});case 1:case"end":return e.stop()}}),e)})));var G=(0,A.Z)(D)},95140:function(e,n,o){(window.__NEXT_P=window.__NEXT_P||[]).push(["/global-hooks",function(){return o(92656)}])}},function(e){e.O(0,[2678,1154,844,4267,600,8487,8264,7858,5499,3437,9774,2888,179],(function(){return n=95140,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1009],{94629:function(e,n,t){"use strict";t.d(n,{Z:function(){return k}});var r=t(82394),i=t(21831),o=t(82684),u=t(50724),c=t(82555),l=t(97618),a=t(70613),s=t(68487),d=t(68899),f=t(28598);function p(e,n){var t=e.children,r=e.noPadding;return(0,f.jsx)(d.HS,{noPadding:r,ref:n,children:t})}var b=o.forwardRef(p),h=t(62547),v=t(82571),g=t(35686),j=t(98464),O=t(46684),m=t(70515),P=t(53808),y=t(19183);function x(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function Z(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?x(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):x(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function w(e,n){var t,r=e.addProjectBreadcrumbToCustomBreadcrumbs,p=e.after,x=e.afterHeader,w=e.afterHidden,k=e.afterWidth,_=e.afterWidthOverride,C=e.appendBreadcrumbs,E=e.before,I=e.beforeWidth,M=e.breadcrumbs,D=e.children,S=e.errors,A=e.headerMenuItems,B=e.headerOffset,H=e.hideAfterCompletely,N=e.mainContainerHeader,R=e.navigationItems,T=e.setAfterHidden,z=e.setErrors,F=e.subheaderChildren,L=e.subheaderNoPadding,U=e.title,W=e.uuid,V=(0,y.i)().width,q="dashboard_after_width_".concat(W),Q="dashboard_before_width_".concat(W),K=(0,o.useRef)(null),G=(0,o.useState)(_?k:(0,P.U2)(q,k)),X=G[0],Y=G[1],$=(0,o.useState)(!1),J=$[0],ee=$[1],ne=(0,o.useState)(E?Math.max((0,P.U2)(Q,I),13*m.iI):null),te=ne[0],re=ne[1],ie=(0,o.useState)(!1),oe=ie[0],ue=ie[1],ce=(0,o.useState)(null)[1],le=g.ZP.projects.list({},{revalidateOnFocus:!1}).data,ae=null===le||void 0===le?void 0:le.projects,se={label:function(){var e;return null===ae||void 0===ae||null===(e=ae[0])||void 0===e?void 0:e.name},linkProps:{href:"/"}},de=[];M&&(r&&de.push(se),de.push.apply(de,(0,i.Z)(M))),(null===M||void 0===M||!M.length||C)&&(null===ae||void 0===ae?void 0:ae.length)>=1&&(null!==M&&void 0!==M&&M.length||de.unshift({bold:!C,label:function(){return U}}),de.unshift(se)),(0,o.useEffect)((function(){null===K||void 0===K||!K.current||J||oe||null===ce||void 0===ce||ce(K.current.getBoundingClientRect().width)}),[J,X,oe,te,K,ce,V]),(0,o.useEffect)((function(){J||(0,P.t8)(q,X)}),[w,J,X,q]),(0,o.useEffect)((function(){oe||(0,P.t8)(Q,te)}),[oe,te,Q]);var fe=(0,j.Z)(k);return(0,o.useEffect)((function(){_&&fe!==k&&Y(k)}),[_,k,fe]),(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(a.Z,{title:U}),(0,f.jsx)(s.Z,{breadcrumbs:de,menuItems:A,project:null===ae||void 0===ae?void 0:ae[0],version:null===ae||void 0===ae||null===(t=ae[0])||void 0===t?void 0:t.version}),(0,f.jsxs)(d.Nk,{ref:n,children:[0!==(null===R||void 0===R?void 0:R.length)&&(0,f.jsx)(d.lm,{showMore:!0,children:(0,f.jsx)(v.Z,{navigationItems:R,showMore:!0})}),(0,f.jsx)(l.Z,{flex:1,flexDirection:"column",children:(0,f.jsxs)(h.Z,{after:p,afterHeader:x,afterHeightOffset:O.Mz,afterHidden:w,afterMousedownActive:J,afterWidth:X,before:E,beforeHeightOffset:O.Mz,beforeMousedownActive:oe,beforeWidth:d.k1+(E?te:0),headerOffset:B,hideAfterCompletely:!T||H,leftOffset:E?d.k1:null,mainContainerHeader:N,mainContainerRef:K,setAfterHidden:T,setAfterMousedownActive:ee,setAfterWidth:Y,setBeforeMousedownActive:ue,setBeforeWidth:re,children:[F&&(0,f.jsx)(b,{noPadding:L,children:F}),D]})})]}),S&&(0,f.jsx)(u.Z,{disableClickOutside:!0,isOpen:!0,onClickOutside:function(){return null===z||void 0===z?void 0:z(null)},children:(0,f.jsx)(c.Z,Z(Z({},S),{},{onClose:function(){return null===z||void 0===z?void 0:z(null)}}))})]})}var k=o.forwardRef(w)},70320:function(e,n,t){"use strict";t.d(n,{h:function(){return u},q:function(){return o}});var r=t(78419),i=t(53808);function o(){return(0,i.U2)(r.am,null)||!1}function u(e){return"undefined"!==typeof e&&(0,i.t8)(r.am,e),e}},55072:function(e,n,t){"use strict";t.d(n,{Et:function(){return f},Q:function(){return d}});t(82684);var r=t(71180),i=t(55485),o=t(38276),u=t(31748),c=t(72473),l=t(79633),a=t(70515),s=t(28598),d=30,f=9;n.ZP=function(e){var n=e.page,t=e.maxPages,d=e.onUpdate,f=e.totalPages,p=[],b=t;if(b>f)p=Array.from({length:f},(function(e,n){return n}));else{var h=Math.floor(b/2),v=n-h;n+h>=f?(v=f-b+2,b-=2):n-h<=0?(v=0,b-=2):(b-=4,v=n-Math.floor(b/2)),p=Array.from({length:b},(function(e,n){return n+v}))}return(0,s.jsx)(s.Fragment,{children:f>0&&(0,s.jsxs)(i.ZP,{alignItems:"center",children:[(0,s.jsx)(r.ZP,{disabled:0===n,onClick:function(){return d(n-1)},children:(0,s.jsx)(c.Hd,{size:1.5*a.iI,stroke:u.Av})}),!p.includes(0)&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.ZP,{borderLess:!0,noBackground:!0,onClick:function(){return d(0)},children:1})},0),!p.includes(1)&&(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.ZP,{noBackground:!0,noPadding:!0,notClickable:!0,children:"..."})},0)]}),p.map((function(e){return(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.ZP,{backgroundColor:e===n&&l.a$,borderLess:!0,noBackground:!0,notClickable:e===n,onClick:function(){e!==n&&d(e)},children:e+1})},e)})),!p.includes(f-1)&&(0,s.jsxs)(s.Fragment,{children:[!p.includes(f-2)&&(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.ZP,{noBackground:!0,noPadding:!0,notClickable:!0,children:"..."})},0),(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.ZP,{borderLess:!0,noBackground:!0,onClick:function(){return d(f-1)},children:f})},f-1)]}),(0,s.jsx)(o.Z,{ml:1}),(0,s.jsx)(r.ZP,{disabled:n===f-1,onClick:function(){return d(n+1)},children:(0,s.jsx)(c.Kw,{size:1.5*a.iI,stroke:u.Av})})]})})}},79757:function(e,n,t){"use strict";var r=t(82394),i=t(26304),o=(t(82684),t(38626)),u=t(44897),c=t(42631),l=t(95363),a=t(70515),s=t(61896),d=t(28598),f=["children"];function p(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function b(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?p(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):p(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var h=o.default.p.withConfig({displayName:"Badge__BadgeStyle",componentId:"sc-tfqsp0-0"})(["border-radius:","px;display:inline;font-family:",";margin:0;white-space:nowrap;",";"," "," ",";",";"," "," "," "," "," "," "," ",""],c.BG,l.ry,s.iD,(function(e){return e.small&&"\n ".concat(s.HC,";\n ")}),(function(e){return e.xxsmall&&"\n font-size: ".concat(s.VK,"px;\n line-height: ").concat(s.VK,"px;\n ")}),(function(e){return!e.regular&&"\n padding: 2px 4px;\n "}),(function(e){return e.regular&&"\n padding: ".concat(1*a.iI,"px ").concat(1.25*a.iI,"px;\n ")}),(function(e){return e.noVerticalPadding&&"\n padding-bottom: 0;\n padding-top: 0;\n "}),(function(e){return!e.disabled&&!e.inverted&&"\n background-color: ".concat((e.theme||u.Z).background.row,";\n color: ").concat((e.theme||u.Z).content.default,";\n ")}),(function(e){return!e.disabled&&e.inverted&&"\n background-color: ".concat((e.theme||u.Z).background.dark,";\n color: ").concat((e.theme||u.Z).content.inverted,";\n ")}),(function(e){return e.cyan&&"\n background-color: ".concat((e.theme||u.Z).accent.cyan,";\n color: ").concat((e.theme||u.Z).monotone.black,";\n ")}),(function(e){return e.disabled&&"\n background-color: ".concat((e.theme||u.Z).feature.disabled,";\n color: ").concat((e.theme||u.Z).content.disabled,";\n ")}),(function(e){return e.color&&"\n background-color: ".concat(e.color," !important;\n color: ").concat((e.theme||u.Z).content.active,";\n ")}),(function(e){return e.quantifier&&"\n border-radius: 34px;\n line-height: 10px;\n padding: 4px 6px;\n "}),(function(e){return e.monospace&&"\n font-family: ".concat(l.Vp,";\n word-break: break-all;\n ")}));n.Z=function(e){var n=e.children,t=(0,i.Z)(e,f);return(0,d.jsx)(h,b(b({},t),{},{children:n}))}},46732:function(e,n,t){"use strict";var r=t(82394),i=t(26304),o=(t(82684),t(50724)),u=t(70374),c=t(28598),l=["children","items","open","onClickCallback","onClickOutside","parentRef","uuid","zIndex"];function a(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function s(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?a(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):a(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}n.Z=function(e){var n=e.children,t=e.items,r=e.open,a=e.onClickCallback,d=e.onClickOutside,f=e.parentRef,p=e.uuid,b=e.zIndex,h=(0,i.Z)(e,l),v=(0,c.jsxs)("div",{style:{position:"relative",zIndex:(d?3:2)+(b||0)},children:[(0,c.jsx)("div",{ref:f,children:n}),(0,c.jsx)(u.Z,s(s({},h),{},{items:t,onClickCallback:a,open:r,parentRef:f,uuid:p}))]});return d?(0,c.jsx)(o.Z,{onClickOutside:d,open:!0,children:v}):v}},72191:function(e,n,t){"use strict";t.d(n,{_k:function(){return o},bL:function(){return i},l2:function(){return u},nz:function(){return c}});var r=t(70515),i=(r.iI,2*r.iI),o=2.5*r.iI,u=3*r.iI,c=3.5*r.iI},78234:function(e,n,t){"use strict";t.r(n);var r=t(77837),i=t(82394),o=t(38860),u=t.n(o),c=t(82684),l=t(34376),a=t(94629),s=t(55072),d=t(53943),f=t(93808),p=t(82359),b=t(38276),h=t(4190),v=t(85544),g=t(35686),j=t(44265),O=t(70515),m=t(69419),P=t(86735),y=t(70320),x=t(28598);function Z(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function w(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?Z(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):Z(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function k(){var e=(0,l.useRouter)(),n=(0,c.useState)(null),t=n[0],r=n[1],o=(0,m.iV)(),u=null!==o&&void 0!==o&&o.page?o.page:0,f=(0,m.DQ)(o,[j.P0.PIPELINE_UUID,j.P0.STATUS,j.P0.TAG]),Z=g.ZP.projects.list().data,k=(0,c.useMemo)((function(){var e;return null===Z||void 0===Z||null===(e=Z.projects)||void 0===e?void 0:e[0]}),[Z]),_=((0,c.useMemo)((function(){var e;return(0,y.h)(null===k||void 0===k||null===(e=k.features)||void 0===e?void 0:e[p.d.LOCAL_TIMEZONE])}),[null===k||void 0===k?void 0:k.features]),w(w({},f),{},{_limit:s.Q,_offset:u*s.Q,disable_retries_grouping:!0,include_pipeline_tags:!0,include_pipeline_uuids:!0}));null!==o&&void 0!==o&&o.status&&(_.status=o.status);var C=g.ZP.pipeline_runs.list(_,{refreshInterval:3e3,revalidateOnFocus:!0}),E=C.data,I=C.mutate,M=g.ZP.tags.list().data,D=(0,c.useMemo)((function(){return(0,P.YC)((null===M||void 0===M?void 0:M.tags)||[],(function(e){return e.uuid}))}),[M]),S=(0,c.useMemo)((function(){return(null===E||void 0===E?void 0:E.pipeline_runs)||[]}),[E]),A=(0,c.useMemo)((function(){var e;return(null===E||void 0===E||null===(e=E.metadata)||void 0===e?void 0:e.count)||[]}),[E]),B=(0,c.useMemo)((function(){var e;return(null===E||void 0===E||null===(e=E.metadata)||void 0===e?void 0:e.pipeline_uuids)||[]}),[E]),H=(0,c.useMemo)((function(){return(0,x.jsx)(v.Z,{filterOptions:{pipeline_uuid:B,pipeline_tag:D.map((function(e){return e.uuid})),status:j.IK},filterValueLabelMapping:{pipeline_tag:D.reduce((function(e,n){var t=n.uuid;return w(w({},e),{},(0,i.Z)({},t,t))}),{}),status:j.Do},onClickFilterDefaults:function(){e.push("/pipeline-runs")},query:f,resetPageOnFilterApply:!0})}),[B,f,e,D]);return(0,x.jsx)(a.Z,{errors:t,setErrors:r,subheaderChildren:H,title:"Pipeline runs",uuid:"pipeline_runs/index",children:E?(0,x.jsxs)(x.Fragment,{children:[(0,x.jsx)(d.Z,{fetchPipelineRuns:I,includePipelineTags:!0,pipelineRuns:S,setErrors:r}),(0,x.jsx)(b.Z,{p:2,children:(0,x.jsx)(s.ZP,{maxPages:s.Et,onUpdate:function(n){var t=Number(n),r=w(w({},o),{},{page:t>=0?t:0});e.push("/pipeline-runs","/pipeline-runs?".concat((0,m.uM)(r)))},page:Number(u),totalPages:Math.ceil(A/s.Q)})})]}):(0,x.jsx)(b.Z,{p:O.Mq,children:(0,x.jsx)(h.Z,{inverted:!0,large:!0})})})}k.getInitialProps=(0,r.Z)(u().mark((function e(){return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",{});case 1:case"end":return e.stop()}}),e)}))),n.default=(0,f.Z)(k)},60710:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/pipeline-runs",function(){return t(78234)}])},80022:function(e,n,t){"use strict";function r(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}t.d(n,{Z:function(){return r}})},15544:function(e,n,t){"use strict";function r(e){return r=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},r(e)}t.d(n,{Z:function(){return r}})},13692:function(e,n,t){"use strict";t.d(n,{Z:function(){return i}});var r=t(61049);function i(e,n){if("function"!==typeof n&&null!==n)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),n&&(0,r.Z)(e,n)}},93189:function(e,n,t){"use strict";t.d(n,{Z:function(){return o}});var r=t(12539),i=t(80022);function o(e,n){if(n&&("object"===r(n)||"function"===typeof n))return n;if(void 0!==n)throw new TypeError("Derived constructors may only return object or undefined");return(0,i.Z)(e)}},61049:function(e,n,t){"use strict";function r(e,n){return r=Object.setPrototypeOf||function(e,n){return e.__proto__=n,e},r(e,n)}t.d(n,{Z:function(){return r}})}},function(e){e.O(0,[2678,1154,844,4267,600,8487,8264,7858,5499,3943,5544,9774,2888,179],(function(){return n=60710,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6780],{74395:function(e,n,t){"use strict";t.d(n,{M:function(){return s},W:function(){return r}});var i=t(38626),l=t(46684),r=34*t(70515).iI,s=i.default.div.withConfig({displayName:"indexstyle__BeforeStyle",componentId:"sc-12ee2ib-0"})(["min-height:calc(100vh - ","px);"],l.Mz)},8955:function(e,n,t){"use strict";t.d(n,{G7:function(){return P},ZP:function(){return _},u$:function(){return x}});var i=t(75582),l=t(82394),r=t(26304),s=t(90299),a=t(9134),c=t(24138),u=t(38276),o=t(30160),d=t(75499),p=t(70515),f=t(16488),v=t(42122),b=t(28598),h=["height","heightOffset","pipeline","selectedRun","selectedTab","setSelectedTab"];function m(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function j(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?m(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):m(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var x=44,Z={uuid:"Run details"},g={uuid:"Dependency tree"},P=[g,Z];function _(e){var n=e.height,t=e.heightOffset,l=e.pipeline,m=e.selectedRun,_=e.selectedTab,k=e.setSelectedTab,y=j({},(0,r.Z)(e,h));m?y.blockStatus=(0,f.IJ)(null===m||void 0===m?void 0:m.block_runs):y.noStatus=!0;var O=(0,v.Kn)(null===m||void 0===m?void 0:m.variables)?j({},null===m||void 0===m?void 0:m.variables):(null===m||void 0===m?void 0:m.variables)||{},I=null===m||void 0===m?void 0:m.event_variables;if(I&&(0,v.Kn)(I)&&!(0,v.Qr)(I))if((0,v.Kn)(O)&&O.hasOwnProperty("event")){var w=(0,v.Kn)(O.event)?O.event:{};O.event=j(j({},w),I)}else O.event=j({},I);var E=[];O&&JSON.stringify(O,null,2).split("\n").forEach((function(e){E.push(" ".concat(e))}));var D=m&&[["Run ID",null===m||void 0===m?void 0:m.id],["Variables",(0,b.jsx)(a.Z,{language:"json",small:!0,source:E.join("\n")},"variable_value")]],S=m&&(0,b.jsx)(u.Z,{pb:p.cd,px:p.cd,children:(0,b.jsx)(d.Z,{alignTop:!0,columnFlex:[null,1],columnMaxWidth:function(e){return 1===e?"100px":null},rows:D.map((function(e,n){var t=(0,i.Z)(e,2),l=t[0],r=t[1];return[(0,b.jsx)(o.ZP,{monospace:!0,muted:!0,children:l},"key_".concat(n)),(0,b.jsx)(o.ZP,{monospace:!0,textOverflow:!0,children:r},"val_".concat(n))]})),uuid:"LogDetail"})}),C=_&&k;return(0,b.jsxs)(b.Fragment,{children:[C&&(0,b.jsx)(u.Z,{py:p.cd,children:(0,b.jsx)(s.Z,{onClickTab:k,selectedTabUUID:null===_||void 0===_?void 0:_.uuid,tabs:P,underlineStyle:!0})}),(!C||g.uuid===(null===_||void 0===_?void 0:_.uuid))&&(0,b.jsx)(c.ZP,j(j({},y),{},{height:n,heightOffset:(t||0)+(C?x:0),pipeline:l})),Z.uuid===(null===_||void 0===_?void 0:_.uuid)&&S]})}},83641:function(e,n,t){"use strict";t.d(n,{I7:function(){return i},IB:function(){return c},VV:function(){return r},_7:function(){return s},rn:function(){return a}});var i,l=t(41143),r="datetime",s="code",a=l.V;!function(e){e.SECOND="second",e.MINUTE="minute",e.HOUR="hour",e.DAY="day",e.WEEK="week",e.MONTH="month",e.YEAR="year",e.CUSTOM="custom"}(i||(i={}));var c=[i.MINUTE,i.HOUR,i.DAY,i.WEEK,i.MONTH,i.YEAR,i.CUSTOM]},51532:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return ue}});var i=t(75582),l=t(77837),r=t(82394),s=t(38860),a=t.n(s),c=t(82684),u=t(69864),o=t(34376),d=t(83641),p=t(71180),f=t(15338),v=t(55485),b=t(85854),h=t(55072),m=t(75457),j=t(53943),x=t(44265),Z=t(83784),g=t(44085),P=t(38276),_=t(4190),k=t(75499),y=t(30160),O=t(35686),I=t(8955),w=t(72473),E=t(74395),D=t(70515),S=t(28795),C=t(81728),M=t(3917),T=t(8916),N=t(81655),L=t(16488),F=t(15610),A=t(42122),R=t(50178),U=t(72619),V=t(3314),B=t(69419),H=t(70320),z=t(28598);function Y(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function K(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?Y(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):Y(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var X=function(e){var n=e.backfill,t=e.errors,l=e.fetchBackfill,r=e.pipeline,s=e.setErrors,a=e.variables,Y=(0,R.Ct)(),X=(0,H.q)(),G=(0,o.useRouter)(),W=n||{},q=W.block_uuid,Q=W.end_datetime,J=W.id,$=W.interval_type,ee=W.interval_units,ne=W.name,te=W.pipeline_run_dates,ie=W.start_datetime,le=W.status,re=W.total_run_count,se=W.variables,ae=void 0===se?{}:se,ce=r.uuid,ue=(0,B.iV)(),oe={_limit:40,_offset:40*(null!==ue&&void 0!==ue&&ue.page?ue.page:0)};null!==ue&&void 0!==ue&&ue.status&&(oe.status=ue.status);var de=O.ZP.pipeline_runs.list(K(K({},oe),{},{backfill_id:J}),{refreshInterval:3e3,revalidateOnFocus:!0},{pauseFetch:!J}),pe=de.data,fe=de.mutate,ve=!(ie&&Q&&$&&ee),be=!le,he=(0,c.useMemo)((function(){return(be?te:null===pe||void 0===pe?void 0:pe.pipeline_runs)||[]}),[pe,te,be]),me=(0,c.useMemo)((function(){var e;return(null===pe||void 0===pe||null===(e=pe.metadata)||void 0===e?void 0:e.count)||[]}),[pe]),je=(0,c.useState)(null),xe=je[0],Ze=je[1],ge=(0,c.useMemo)((function(){var e=null!==ue&&void 0!==ue&&ue.page?ue.page:0;return(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(j.Z,{disableRowSelect:be,emptyMessage:null!==ue&&void 0!==ue&&ue.status?"No runs available":'No runs available. Please complete backfill configuration by clicking "Edit backfill" above.',fetchPipelineRuns:fe,onClickRow:function(e){return Ze((function(n){var t=he[e];return(null===n||void 0===n?void 0:n.id)!==t.id?t:null}))},pipelineRuns:he,selectedRun:xe,setErrors:s,setSelectedRun:Ze}),(0,z.jsx)(P.Z,{p:2,children:(0,z.jsx)(h.ZP,{maxPages:9,onUpdate:function(e){var n=Number(e),t=K(K({},ue),{},{page:n>=0?n:0});G.push("/pipelines/[pipeline]/backfills/[...slug]","/pipelines/".concat(ce,"/backfills/").concat(J,"?").concat((0,B.uM)(t)))},page:Number(e),totalPages:Math.ceil(me/40)})})]})}),[fe,J,he,ce,ue,G,xe,s,be,me]),Pe=(0,c.useState)(I.G7[0]),_e=Pe[0],ke=Pe[1],ye=(0,u.Db)(O.ZP.backfills.useUpdate(J),{onSuccess:function(e){return(0,U.wD)(e,{callback:function(){l(),fe()},onErrorCallback:function(e,n){return s({errors:n,response:e})}})}}),Oe=(0,i.Z)(ye,2),Ie=Oe[0],we=Oe[1].isLoading,Ee=(0,c.useMemo)((function(){return!!le&&(d.rn.CANCELLED!==le&&d.rn.FAILED!==le)}),[le]),De=(0,c.useMemo)((function(){return le&&d.rn.CANCELLED!==le&&d.rn.FAILED!==le&&d.rn.INITIAL!==le&&d.rn.RUNNING!==le}),[le]),Se=(0,c.useMemo)((function(){var e={default:!0,size:1.5*D.iI},n=[[(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(w.VW,K({},e)),(0,z.jsx)(P.Z,{mr:1}),(0,z.jsx)(y.ZP,{default:!0,children:"Backfill type"})]},"backfill_type_label"),(0,z.jsx)(y.ZP,{monospace:!0,children:q?d._7:d.VV},"backfill_type")],[(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(w.rs,K({},e)),(0,z.jsx)(P.Z,{mr:1}),(0,z.jsx)(y.ZP,{default:!0,children:"Status"})]},"backfill_status_label"),(0,c.createElement)(y.ZP,K(K({},(0,N.NC)(le)),{},{key:"backfill_status"}),le||"inactive")]];return q||n.push.apply(n,[[(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(w.aw,K({},e)),(0,z.jsx)(P.Z,{mr:1}),(0,z.jsx)(y.ZP,{default:!0,children:"Start date and time"})]},"backfill_start_date_label"),(0,z.jsx)(y.ZP,{monospace:!0,small:!0,children:X?(0,M.XG)(ie,X):(0,L.Vx)(ie)},"backfill_start_date")],[(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(w.aw,K({},e)),(0,z.jsx)(P.Z,{mr:1}),(0,z.jsx)(y.ZP,{default:!0,children:"End date and time"})]},"backfill_end_date_label"),(0,z.jsx)(y.ZP,{monospace:!0,small:!0,children:X?(0,M.XG)(Q,X):(0,L.Vx)(Q)},"backfill_end_date")],[(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(w.Pf,K({},e)),(0,z.jsx)(P.Z,{mr:1}),(0,z.jsx)(y.ZP,{default:!0,children:"Interval type"})]},"interval_type_label"),(0,z.jsx)(y.ZP,{monospace:!0,children:$&&(0,C.kC)($)},"interval_type")],[(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(w.Pf,K({},e)),(0,z.jsx)(P.Z,{mr:1}),(0,z.jsx)(y.ZP,{default:!0,children:"Interval units"})]},"interval_units_label"),(0,z.jsx)(y.ZP,{monospace:!0,children:ee},"interval_units")],[(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(w.qZ,K({},e)),(0,z.jsx)(P.Z,{mr:1}),(0,z.jsx)(y.ZP,{default:!0,children:"Total runs"})]},"total_runs_label"),(0,z.jsx)(y.ZP,{monospace:!0,children:re},"total_runs")]]),(0,z.jsx)(k.Z,{columnFlex:[null,1],rows:n})}),[q,X,Q,$,ee,ie,le,re]),Ce=(0,c.useMemo)((function(){return ae||{}}),[ae]),Me=(0,c.useMemo)((function(){var e=(0,T.wx)(a,(function(e){return e.uuid===Z.C}))||[];return(0,A.Qr)(Ce)||Object.entries(Ce).forEach((function(n){var t=(0,i.Z)(n,2),l=t[0],r=t[1],s=e.findIndex((function(e){return(null===e||void 0===e?void 0:e.uuid)===l}));-1!==s?e.splice(s,1,{uuid:l,value:(0,T.FS)(r)}):e.push({uuid:l,value:(0,T.FS)(r)})})),"undefined"!==typeof e&&null!==e&&void 0!==e&&e.length?(0,z.jsx)(k.Z,{columnFlex:[null,1],rows:e.map((function(e){var n=e.uuid,t=e.value;return[(0,z.jsx)(y.ZP,{default:!0,monospace:!0,small:!0,children:n},"settings_variable_label_".concat(n)),(0,z.jsx)(y.ZP,{monospace:!0,small:!0,children:t},"settings_variable_".concat(n))]}))}):null}),[Ce,a]);return(0,z.jsx)(z.Fragment,{children:(0,z.jsxs)(m.Z,{afterHidden:!xe,before:(0,z.jsxs)(E.M,{children:[(0,z.jsxs)(P.Z,{mb:D.HN,pt:D.cd,px:D.cd,children:[(0,z.jsx)(P.Z,{mb:D.cd,children:(0,z.jsx)(w.yg,{size:5*D.iI})}),(0,z.jsx)(b.Z,{children:ne})]}),(0,z.jsx)(P.Z,{px:D.cd,children:(0,z.jsx)(b.Z,{level:5,children:"Settings"})}),(0,z.jsx)(f.Z,{light:!0,mt:1,short:!0}),Se,Me&&(0,z.jsxs)(P.Z,{my:D.HN,children:[(0,z.jsx)(P.Z,{px:D.cd,children:(0,z.jsx)(b.Z,{level:5,children:"Runtime variables"})}),(0,z.jsx)(f.Z,{light:!0,mt:1,short:!0}),Me]})]}),beforeWidth:34*D.iI,breadcrumbs:[{label:function(){return"Backfills"},linkProps:{as:"/pipelines/".concat(ce,"/backfills"),href:"/pipelines/[pipeline]/backfills"}},{label:function(){return ne},linkProps:{as:"/pipelines/".concat(ce,"/backfills/").concat(J),href:"/pipelines/[pipeline]/backfills/[...slug]"}}],buildSidekick:function(e){return(0,I.ZP)(K(K({},e),{},{selectedRun:xe,selectedTab:_e,setSelectedTab:ke}))},errors:t,pageName:S.M.BACKFILLS,pipeline:r,setErrors:s,subheader:(0,z.jsxs)(v.ZP,{alignItems:"center",children:[!De&&(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(p.ZP,{beforeIcon:Ee?(0,z.jsx)(w.dz,{size:2*D.iI}):(0,z.jsx)(w.Py,{inverted:!(d.rn.CANCELLED===le||d.rn.FAILED===le),size:2*D.iI}),danger:Ee,disabled:ve,loading:we,onClick:function(e){(0,V.j)(e),Ie({backfill:{status:Ee?d.rn.CANCELLED:d.rn.INITIAL}})},outline:!0,success:!Ee&&!(d.rn.CANCELLED===le||d.rn.FAILED===le)&&!ve,children:Ee?"Cancel backfill":d.rn.CANCELLED===le||d.rn.FAILED===le?"Retry backfill":"Start backfill"}),(0,z.jsx)(P.Z,{mr:D.cd})]}),!Y&&(0,z.jsxs)(z.Fragment,{children:[le===x.VO.COMPLETED?(0,z.jsx)(y.ZP,{bold:!0,default:!0,large:!0,children:"Filter runs by status:"}):(0,z.jsx)(p.ZP,{linkProps:{as:"/pipelines/".concat(ce,"/backfills/").concat(J,"/edit"),href:"/pipelines/[pipeline]/backfills/[...slug]"},noHoverUnderline:!0,outline:!0,sameColorAsText:!0,children:"Edit backfill"}),(0,z.jsx)(P.Z,{mr:D.cd})]}),!be&&(0,z.jsxs)(g.Z,{compact:!0,defaultColor:!0,onChange:function(e){e.preventDefault(),"all"===e.target.value?G.push("/pipelines/[pipeline]/backfills/[...slug]","/pipelines/".concat(ce,"/backfills/").concat(J)):(0,F.u7)({page:0,status:e.target.value})},paddingRight:4*D.iI,placeholder:"Select run status",value:(null===ue||void 0===ue?void 0:ue.status)||"all",children:[(0,z.jsx)("option",{value:"all",children:"All statuses"},"all_statuses"),x.IK.map((function(e){return(0,z.jsx)("option",{value:e,children:x.Do[e]},e)}))]})]}),title:function(){return ne},uuid:"backfill/detail",children:[(0,z.jsx)(P.Z,{mt:D.cd,px:D.cd,children:(0,z.jsx)(b.Z,{level:5,children:"Runs for this backfill"})}),(0,z.jsx)(f.Z,{light:!0,mt:D.cd,short:!0}),pe?ge:(0,z.jsx)(P.Z,{m:2,children:(0,z.jsx)(_.Z,{inverted:!0})})]})})},G=t(14805),W=t(50724),q=t(97618),Q=t(37899),J=t(17488),$=[{label:function(){return"Date and time window"},description:function(){return"Backfill between a date and time range."},uuid:d.VV}],ee=t(88785),ne=t(79500);function te(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function ie(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?te(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):te(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var le=function(e){var n=e.backfill,t=e.errors,l=e.fetchBackfill,r=e.pipeline,s=e.setErrors,a=e.variables,h=(0,o.useRouter)(),j=(0,H.q)(),x=(0,c.useState)(),Z=x[0],_=x[1],I=Z||{},E=I.block_uuid,M=I.id,N=I.interval_type,F=I.interval_units,R=I.name,V=r.uuid,B=(0,c.useMemo)((function(){return(0,A.Qr)((null===n||void 0===n?void 0:n.variables)||{})?(0,T.Tt)(a)||{}:(0,A.Xc)(n.variables,(function(e){return(0,T.FS)(e)}))}),[null===n||void 0===n?void 0:n.variables,a]),Y=(0,c.useState)(!1),K=Y[0],X=Y[1],te=(0,c.useState)(B),le=te[0],re=te[1],se=(0,c.useState)(E?d._7:d.VV),ae=se[0],ce=se[1],ue=(0,c.useState)(!1),oe=ue[0],de=ue[1],pe=(0,c.useState)(!1),fe=pe[0],ve=pe[1],be=(0,c.useState)(null),he=be[0],me=be[1],je=(0,c.useState)(null),xe=je[0],Ze=je[1],ge=(0,c.useState)({hour:"00",minute:"00"}),Pe=ge[0],_e=ge[1],ke=(0,c.useState)({hour:"00",minute:"00"}),ye=ke[0],Oe=ke[1];(0,c.useEffect)((function(){if(n){_(n);var e=n.start_datetime;if(e){var t=(0,ne.a)(e,{localTimezone:j});Ze(null===t||void 0===t?void 0:t.date),Oe(t.time)}var i=n.end_datetime;if(i){var l=(0,ne.a)(i,{localTimezone:j});me(null===l||void 0===l?void 0:l.date),_e(null===l||void 0===l?void 0:l.time)}}}),[j,n]);var Ie=(0,c.useMemo)((function(){var e=[[(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(w.KJ,{default:!0}),(0,z.jsx)(P.Z,{mr:1}),(0,z.jsx)(y.ZP,{default:!0,children:"Backfill name"})]},"model_name_detail"),(0,z.jsx)(J.Z,{monospace:!0,onChange:function(e){e.preventDefault(),_((function(n){return ie(ie({},n),{},{name:e.target.value})}))},placeholder:"Name this backfill",value:R},"model_name_input_detail")]];return d.VV===ae&&e.push.apply(e,[[(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(w.aw,{default:!0}),(0,z.jsx)(P.Z,{mr:1}),(0,z.jsx)(y.ZP,{default:!0,children:"Start date and time"})]},"start_time"),(0,z.jsxs)("div",{style:{minHeight:"".concat(5.75*D.iI,"px")},children:[!oe&&(0,z.jsx)(J.Z,{monospace:!0,onClick:function(){return de((function(e){return!e}))},onFocus:function(){return de(!0)},placeholder:"YYYY-MM-DD HH:MM",value:xe?(0,L.XM)(xe,ye,{localTimezone:j}):""}),(0,z.jsx)("div",{style:{width:"400px"},children:(0,z.jsx)(W.Z,{disableEscape:!0,onClickOutside:function(){return de(!1)},open:oe,style:{position:"relative"},children:(0,z.jsx)(G.Z,{localTime:j,selectedDate:xe,selectedTime:ye,setSelectedDate:Ze,setSelectedTime:Oe,topPosition:!0})})})]},"start_time_input")],[(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(w.aw,{default:!0}),(0,z.jsx)(P.Z,{mr:1}),(0,z.jsx)(y.ZP,{default:!0,children:"End date and time"})]},"end_time"),(0,z.jsxs)("div",{style:{minHeight:"".concat(5.75*D.iI,"px")},children:[!fe&&(0,z.jsx)(J.Z,{monospace:!0,onClick:function(){return ve((function(e){return!e}))},onFocus:function(){return ve(!0)},placeholder:"YYYY-MM-DD HH:MM",value:he?(0,L.XM)(he,Pe,{localTimezone:j}):""}),(0,z.jsx)("div",{style:{width:"400px"},children:(0,z.jsx)(W.Z,{disableEscape:!0,onClickOutside:function(){return ve(!1)},open:fe,style:{position:"relative"},children:(0,z.jsx)(G.Z,{localTime:j,selectedDate:he,selectedTime:Pe,setSelectedDate:me,setSelectedTime:_e,topPosition:!0})})})]},"end_time_input")],[(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(w.Pf,{default:!0}),(0,z.jsx)(P.Z,{mr:1}),(0,z.jsx)(y.ZP,{default:!0,children:"Interval type"})]},"interval_type"),(0,z.jsx)(g.Z,{monospace:!0,onChange:function(e){e.preventDefault(),_((function(n){return ie(ie({},n),{},{interval_type:e.target.value})}))},placeholder:"Time spacing between each backfill",value:N,children:d.IB.map((function(e){return(0,z.jsx)("option",{value:e,children:(0,C.kC)(e)},e)}))},"interval_type_input")],[(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(w.Pf,{default:!0}),(0,z.jsx)(P.Z,{mr:1}),(0,z.jsx)(y.ZP,{default:!0,children:"Interval units"})]},"interval_units"),(0,z.jsx)(J.Z,{disabled:!N,monospace:!0,onChange:function(e){e.preventDefault(),_((function(n){return ie(ie({},n),{},{interval_units:e.target.value})}))},placeholder:N?"Number of ".concat(N).concat(N!==d.I7.CUSTOM?"s":""," between each backfill"):"Interval type is required",type:"number",value:F},"interval_unit_input")]]),(0,A.Qr)(B)||e.push([(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(w.LO,{default:!0}),(0,z.jsx)(P.Z,{mr:1}),(0,z.jsx)(y.ZP,{default:!0,children:"Runtime variables"})]},"overwrite_runtime_variables"),(0,z.jsx)(Q.Z,{borderless:!0,compact:!0,enableVariablesOverwrite:K,runtimeVariables:le,setEnableVariablesOverwrite:X,setRuntimeVariables:re},"overwrite_runtime_variables_table")]),(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(P.Z,{mb:2,px:D.cd,children:(0,z.jsx)(b.Z,{children:"Settings"})}),(0,z.jsx)(f.Z,{light:!0,short:!0}),(0,z.jsx)(k.Z,{columnFlex:[null,1],rows:e})]})}),[he,xe,j,K,N,F,R,le,B,ae,oe,fe,Pe,ye]),we=(0,u.Db)(O.ZP.backfills.useUpdate(M),{onSuccess:function(e){return(0,U.wD)(e,{callback:function(){l(),h.push("/pipelines/[pipeline]/backfills/[...slug]","/pipelines/".concat(V,"/backfills/").concat(M))},onErrorCallback:function(e,n){return s({errors:n,response:e})}})}}),Ee=(0,i.Z)(we,2),De=Ee[0],Se=Ee[1].isLoading,Ce=(0,c.useCallback)((function(){var e=ie(ie({},(0,A.GL)(Z,["name"])),{},{end_datetime:null,interval_type:null,interval_units:null,start_datetime:null,variables:K?(0,T.e7)(le):{}});return d._7===ae||(e.interval_type=N,e.interval_units=F,e.end_datetime=he&&null!==Pe&&void 0!==Pe&&Pe.hour&&null!==Pe&&void 0!==Pe&&Pe.minute?(0,L.XM)(he,Pe,{convertToUtc:j,includeSeconds:!0,localTimezone:j}):null,e.start_datetime=xe&&null!==ye&&void 0!==ye&&ye.hour&&null!==ye&&void 0!==ye&&ye.minute?(0,L.XM)(xe,ye,{convertToUtc:j,includeSeconds:!0,localTimezone:j}):null),De({backfill:e})}),[he,xe,j,K,N,F,Z,le,ae,Pe,ye,De]),Me=(0,c.useMemo)((function(){return d._7===ae?!E:!(he&&xe&&N&&F)}),[E,he,xe,N,F,ae]);return(0,z.jsxs)(m.Z,{breadcrumbs:[{label:function(){return"Backfills"},linkProps:{as:"/pipelines/".concat(V,"/backfills"),href:"/pipelines/[pipeline]/backfills"}},{label:function(){return null===Z||void 0===Z?void 0:Z.name},linkProps:{as:"/pipelines/".concat(V,"/backfills/").concat(M),href:"/pipelines/[pipeline]/backfills/[...slug]"}}],errors:t,pageName:S.M.BACKFILLS,pipeline:r,setErrors:s,subheader:(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(p.ZP,{disabled:Me,loading:Se,onClick:Ce,outline:!0,primary:!0,children:"Save changes"}),(0,z.jsx)(P.Z,{mr:1}),(0,z.jsx)(p.ZP,{linkProps:{href:"/pipelines/[pipeline]/backfills/[...slug]",as:"/pipelines/".concat(V,"/backfills/").concat(M)},noHoverUnderline:!0,outline:!0,sameColorAsText:!0,children:"Cancel"})]}),title:function(){return"Edit ".concat(null===Z||void 0===Z?void 0:Z.name)},uuid:"backfill/edit",children:[(0,z.jsxs)(P.Z,{p:D.cd,children:[(0,z.jsxs)(P.Z,{mb:2,children:[(0,z.jsx)(b.Z,{children:"Backfill type"}),(0,z.jsx)(y.ZP,{muted:!0,children:"How would you like this pipeline to be backfilled?"})]}),(0,z.jsx)(v.ZP,{children:$.map((function(e){var n=e.label,t=e.description,i=e.uuid,l=ae===i,r=ae&&!l;return(0,z.jsx)(p.ZP,{noBackground:!0,noBorder:!0,noPadding:!0,onClick:function(){ce(i)},children:(0,z.jsx)(ee.U,{selected:l,children:(0,z.jsxs)(v.ZP,{alignItems:"center",children:[(0,z.jsx)(q.Z,{children:(0,z.jsx)("input",{checked:l,type:"radio"})}),(0,z.jsx)(P.Z,{mr:D.cd}),(0,z.jsxs)(q.Z,{alignItems:"flex-start",flexDirection:"column",children:[(0,z.jsx)(b.Z,{bold:!0,default:!l&&!r,level:5,muted:!l&&r,children:n()}),(0,z.jsx)(y.ZP,{default:!l&&!r,leftAligned:!0,muted:r,children:t()})]})]})})},i)}))})]}),(0,z.jsx)(P.Z,{mt:5,children:Ie})]})},re=t(93808);function se(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function ae(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?se(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):se(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function ce(e){var n=e.backfillId,t=e.pipelineUUID,i=e.subpath,l=(0,c.useState)(null),r=l[0],s=l[1],a=O.ZP.variables.pipelines.list(t,{},{revalidateOnFocus:!1}).data,u=(0,c.useMemo)((function(){return null===a||void 0===a?void 0:a.variables}),[a]),o=O.ZP.pipelines.detail(t,{includes_content:!1,includes_outputs:!1},{revalidateOnFocus:!1}).data,d=(0,c.useMemo)((function(){return ae(ae({},null===o||void 0===o?void 0:o.pipeline),{},{uuid:t})}),[o,t]),p=O.ZP.backfills.detail(n,{include_preview_runs:!0}),f=p.data,v=p.mutate,b=(0,c.useMemo)((function(){return null===f||void 0===f?void 0:f.backfill}),[f]);return"edit"===i?(0,z.jsx)(le,{backfill:b,errors:r,fetchBackfill:v,pipeline:d,setErrors:s,variables:u}):(0,z.jsx)(X,{backfill:b,errors:r,fetchBackfill:v,pipeline:d,setErrors:s,variables:u})}ce.getInitialProps=function(){var e=(0,l.Z)(a().mark((function e(n){var t,l,r,s,c,u;return a().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=n.query,l=t.pipeline,r=t.slug,!Array.isArray(r)){e.next=4;break}return s=(0,i.Z)(r,2),c=s[0],u=s[1],e.abrupt("return",{backfillId:c,pipelineUUID:l,subpath:u});case 4:return e.abrupt("return",{pipelineUUID:l});case 5:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}();var ue=(0,re.Z)(ce)},53664:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/pipelines/[pipeline]/backfills/[...slug]",function(){return t(51532)}])}},function(e){e.O(0,[2678,1154,844,5820,1124,9161,4495,4267,600,8487,8264,7858,5499,5457,4366,722,3943,845,9774,2888,179],(function(){return n=53664,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8450],{16488:function(n,e,t){"use strict";t.d(e,{IJ:function(){return b},M8:function(){return I},Vx:function(){return h},XM:function(){return y},_U:function(){return v},eI:function(){return _},gU:function(){return P},lO:function(){return A},ri:function(){return E},tL:function(){return T},vJ:function(){return N},xH:function(){return O}});var r,i=t(82394),u=t(92083),o=t.n(u),c=t(3917),l=t(4383),a=t(30229),s=t(42122),f=t(86735);function d(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(n);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,r)}return t}function p(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?d(Object(t),!0).forEach((function(e){(0,i.Z)(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):d(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}var v=function(n){return!!n&&!Object.values(a.U5).includes(n)};function b(n){return null===n||void 0===n?void 0:n.reduce((function(n,e){var t=e.block_uuid,r=e.completed_at,u=e.started_at,c=e.status,l=null;u&&r&&(l=o()(r).valueOf()-o()(u).valueOf());return p(p({},n),{},(0,i.Z)({},t,{runtime:l,status:c}))}),{})}var m,E=function(n){var e=[{description:function(){return"This pipeline will run continuously on an interval or just once."},label:function(){return"Schedule"},uuid:a.Xm.TIME},{description:function(){return"This pipeline will run when a specific event occurs."},label:function(){return"Event"},uuid:a.Xm.EVENT},{description:function(){return"Run this pipeline when you make an API call."},label:function(){return"API"},uuid:a.Xm.API}];return n?e.slice(0,1):e};function O(n){var e=(0,s.gR)(n,[a.gm.INTERVAL,a.gm.TYPE]),t=n[a.gm.INTERVAL];t&&(e["schedule_interval[]"]=encodeURIComponent(t));var r=n[a.gm.TYPE];return r&&(e["schedule_type[]"]=r),e}function _(n){return n?new Date(o()(n).valueOf()):null}function h(n){if("string"!==typeof n)return n;var e=n.split("+")[0];return o()(_(e)).format(c.Nx)}!function(n){n.DAY="day",n.HOUR="hour",n.MINUTE="minute",n.SECOND="second"}(m||(m={}));var T=(r={},(0,i.Z)(r,m.DAY,86400),(0,i.Z)(r,m.HOUR,3600),(0,i.Z)(r,m.MINUTE,60),(0,i.Z)(r,m.SECOND,1),r);function P(n){var e=m.SECOND,t=n;return n%86400===0?(t/=86400,e=m.DAY):n%3600===0?(t/=3600,e=m.HOUR):n%60===0&&(t/=60,e=m.MINUTE),{time:t,unit:e}}function N(n,e){return n*T[e]}function y(n,e,t){var r,i=o()(n);return i.set("hour",+(null===e||void 0===e?void 0:e.hour)||0),i.set("minute",+(null===e||void 0===e?void 0:e.minute)||0),i.set("second",0),r=i.format(c.TD),null!==t&&void 0!==t&&t.includeSeconds&&(r=r.concat(":00")),null!==t&&void 0!==t&&t.localTimezone&&(r=i.format(c.lE),null!==t&&void 0!==t&&t.convertToUtc&&(r=(0,c.d$)(r,{includeSeconds:null===t||void 0===t?void 0:t.includeSeconds,utcFormat:!0}))),r}function I(n){var e,t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r="",i=!0;return i&&(t?r="".concat(window.origin,"/api/pipeline_schedules/").concat(null===n||void 0===n?void 0:n.id,"/api_trigger"):(r="".concat(window.origin,"/api/pipeline_schedules/").concat(null===n||void 0===n?void 0:n.id,"/pipeline_runs"),null!==n&&void 0!==n&&n.token&&(r="".concat(r,"/").concat(n.token)))),i&&(e=window.location.port)&&(r=r.replace(e,l.QT)),r}function g(n,e,t){return n.match(/[*,-/]/)?{additionalOffset:0,cronValue:n}:function(n,e,t){var r=t.indexOf(n),i=0;if(e<0)for(var u=0;u>e;u--)0===r?(r=t.length-1,i-=1):r-=1;else if(e>0)for(var o=0;o<e;o++)r===t.length-1?(r=0,i+=1):r+=1;return{additionalOffset:i,cronValue:String(t[r]||n)}}(+n,e,t)}var j=(0,f.m5)(60),k=(0,f.m5)(24),w=(0,c.Cs)();function A(n,e){if(!n)return n;var t=o()().local().format("Z"),r=t.split(":"),i="-"===t[0],u=3===r[0].length?Number(r[0].slice(1)):Number(r[0]),c=Number(r[1]);(i&&!e||!i&&e)&&(u=-u,c=-c);var l=n.split(" "),a=l[0],s=l[1],f=l[2],d=g(a,c,j),p=g(s,u+d.additionalOffset,k);if(l[0]=d.cronValue,l[1]=p.cronValue,0!==(null===p||void 0===p?void 0:p.additionalOffset)){var v=g(f,p.additionalOffset,w);l[2]=v.cronValue}return l.join(" ")}},70320:function(n,e,t){"use strict";t.d(e,{h:function(){return o},q:function(){return u}});var r=t(78419),i=t(53808);function u(){return(0,i.U2)(r.am,null)||!1}function o(n){return"undefined"!==typeof n&&(0,i.t8)(r.am,n),n}},83641:function(n,e,t){"use strict";t.d(e,{I7:function(){return r},IB:function(){return l},VV:function(){return u},_7:function(){return o},rn:function(){return c}});var r,i=t(41143),u="datetime",o="code",c=i.V;!function(n){n.SECOND="second",n.MINUTE="minute",n.HOUR="hour",n.DAY="day",n.WEEK="week",n.MONTH="month",n.YEAR="year",n.CUSTOM="custom"}(r||(r={}));var l=[r.MINUTE,r.HOUR,r.DAY,r.WEEK,r.MONTH,r.YEAR,r.CUSTOM]},44265:function(n,e,t){"use strict";t.d(e,{Az:function(){return a},BF:function(){return l},Do:function(){return f},IK:function(){return c},P0:function(){return i},VO:function(){return o},sZ:function(){return s}});var r,i,u=t(82394),o=t(41143).V,c=[o.FAILED,o.COMPLETED,o.RUNNING,o.CANCELLED,o.INITIAL],l=[o.INITIAL,o.RUNNING],a=[o.CANCELLED,o.COMPLETED,o.FAILED],s="__mage_variables",f=(r={},(0,u.Z)(r,o.CANCELLED,"Cancelled"),(0,u.Z)(r,o.COMPLETED,"Done"),(0,u.Z)(r,o.FAILED,"Failed"),(0,u.Z)(r,o.INITIAL,"Ready"),(0,u.Z)(r,o.RUNNING,"Running"),r);!function(n){n.PIPELINE_UUID="pipeline_uuid[]",n.STATUS="status[]",n.TAG="pipeline_tag[]"}(i||(i={}))},30229:function(n,e,t){"use strict";t.d(e,{PN:function(){return c},TR:function(){return v},U5:function(){return a},Wb:function(){return p},Xm:function(){return u},Z4:function(){return s},fq:function(){return l},gm:function(){return f},kJ:function(){return d}});var r,i,u,o=t(82394),c="__bookmark_values__";!function(n){n.API="api",n.EVENT="event",n.TIME="time"}(u||(u={}));var l,a,s=(r={},(0,o.Z)(r,u.API,(function(){return"API"})),(0,o.Z)(r,u.EVENT,(function(){return"event"})),(0,o.Z)(r,u.TIME,(function(){return"schedule"})),r);!function(n){n.ACTIVE="active",n.INACTIVE="inactive"}(l||(l={})),function(n){n.ONCE="@once",n.HOURLY="@hourly",n.DAILY="@daily",n.WEEKLY="@weekly",n.MONTHLY="@monthly",n.ALWAYS_ON="@always_on"}(a||(a={}));var f,d,p=[a.ONCE,a.HOURLY,a.DAILY,a.WEEKLY,a.MONTHLY];!function(n){n.INTERVAL="frequency[]",n.STATUS="status[]",n.TAG="tag[]",n.TYPE="type[]"}(f||(f={})),function(n){n.CREATED_AT="created_at",n.NAME="name",n.PIPELINE="pipeline_uuid",n.STATUS="status",n.TYPE="schedule_type"}(d||(d={}));var v=(i={},(0,o.Z)(i,d.CREATED_AT,"Created at"),(0,o.Z)(i,d.NAME,"Name"),(0,o.Z)(i,d.PIPELINE,"Pipeline"),(0,o.Z)(i,d.STATUS,"Active"),(0,o.Z)(i,d.TYPE,"Type"),i)},11650:function(n,e,t){"use strict";t.r(e),t.d(e,{default:function(){return Y}});var r=t(77837),i=t(75582),u=t(38860),o=t.n(u),c=t(82684),l=t(69864),a=t(34376),s=t(82394),f=t(12691),d=t.n(f),p=t(83641),v=t(71180),b=t(48670),m=t(75499),E=t(30160),O=t(72473),_=t(44265),h=t(81655),T=t(70515),P=t(3917),N=t(16488),y=t(50178),I=t(70320),g=t(28598);function j(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(n);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,r)}return t}function k(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?j(Object(t),!0).forEach((function(e){(0,s.Z)(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):j(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}var w=function(n){var e=n.models,t=n.onClickRow,r=n.pipeline,i=n.selectedRow,u=(0,y.Ct)(),o=(0,I.q)(),l=null===r||void 0===r?void 0:r.uuid,a=o?h.O$:{},s=[{uuid:"Status"},{uuid:"Name"},{uuid:"Type"},{uuid:"Runs"},k(k({},a),{},{uuid:"Backfill"}),k(k({},a),{},{uuid:"Started at"}),k(k({},a),{},{uuid:"Completed at"})];return u||s.push({label:function(){return""},uuid:"edit"}),(0,g.jsx)(m.Z,{columnFlex:[null,1,null,null,null,1,1,null],columns:s,isSelectedRow:function(n){return e[n].id===(null===i||void 0===i?void 0:i.id)},onClickRow:function(n){return t(e[n])},rows:e.map((function(n,e){var t=n.block_uuid,r=n.completed_at,i=n.end_datetime,a=n.id,s=n.name,f=n.start_datetime,m=n.started_at,y=n.status,I=n.total_run_count,j=[(0,c.createElement)(E.ZP,k(k({},(0,h.NC)(y)),{},{key:"status"}),y||"inactive"),(0,g.jsx)(d(),{as:"/pipelines/".concat(l,"/backfills/").concat(a),href:"/pipelines/[pipeline]/backfills/[...slug]",passHref:!0,children:(0,g.jsx)(b.Z,{bold:!0,sameColorAsText:!0,children:s})},"name"),(0,g.jsx)(E.ZP,{default:!0,monospace:!0,children:t?p._7:p.VV},"type"),(0,g.jsx)(E.ZP,{default:!0,monospace:!0,children:I||0},"runs"),(0,g.jsxs)(E.ZP,{default:!0,monospace:!0,small:!0,children:[f&&i&&(0,g.jsxs)(g.Fragment,{children:[o?(0,P.XG)(f,o):(0,N.Vx)(f),"\xa0-\xa0",o?(0,P.XG)(i,o):(0,N.Vx)(i)]}),!(f&&i)&&(0,g.jsx)(g.Fragment,{children:"\u2014"})]},"backfill"),(0,g.jsx)(E.ZP,{default:!0,monospace:!0,small:!0,title:m?(0,P._6)(m):null,children:m?o?(0,P.XG)(m,o):(0,N.Vx)(m):(0,g.jsx)(g.Fragment,{children:"\u2014"})},"started_at"),(0,g.jsx)(E.ZP,{default:!0,monospace:!0,small:!0,title:r?(0,P._6)(r):null,children:r?o?(0,P.XG)(r,o):(0,N.Vx)(r):(0,g.jsx)(g.Fragment,{children:"\u2014"})},"completed_at")];return u||j.push((0,g.jsx)(v.ZP,{default:!0,disabled:y===_.VO.COMPLETED,iconOnly:!0,linkProps:{as:"/pipelines/".concat(l,"/backfills/").concat(a,"/edit"),href:"/pipelines/[pipeline]/backfills/[...slug]"},noBackground:!0,title:"Edit",children:(0,g.jsx)(O.I8,{default:!0,size:2*T.iI})},"".concat(e,"_edit_button"))),j})),uuid:"pipeline-runs"})},A=t(93369),Z=t(75457),C=t(93808),D=t(38276),L=t(35686),x=t(28795),S=t(15610),R=t(72619),U=t(69419),V=t(81728);function M(n){var e=n.pipeline,t=(0,a.useRouter)(),r=e.uuid,u=L.ZP.backfills.list({_limit:20,_offset:0,include_run_count:!0,pipeline_uuid:r},{refreshInterval:6e4}).data,o=(0,c.useMemo)((function(){return(null===u||void 0===u?void 0:u.backfills)||[]}),[u]),s=(0,U.iV)(),f=(0,c.useState)(null),d=f[0],p=f[1],v=(0,c.useState)(null),b=v[0],m=v[1];(0,c.useEffect)((function(){null!==s&&void 0!==s&&s.backfill_id?p(null===o||void 0===o?void 0:o.find((function(n){return n.id===Number(s.backfill_id)}))):d&&p(null)}),[o,s,d]);var _=(0,c.useMemo)((function(){var n="/pipelines/".concat(r,"/backfills"),e=[{label:function(){return"Backfills"},linkProps:d?{as:n,href:"/pipelines/[pipeline]/backfills"}:null}];return d&&e.push({label:function(){return d.name}}),e}),[r,d]),h=(0,l.Db)(L.ZP.backfills.pipelines.useCreate(r),{onSuccess:function(n){return(0,R.wD)(n,{callback:function(n){var e=n.backfill.id;t.push("/pipelines/[pipeline]/backfills/[...slug]","/pipelines/".concat(r,"/backfills/").concat(e,"/edit"))},onErrorCallback:function(n,e){return m({errors:e,response:n})}})}}),P=(0,i.Z)(h,2),N=P[0],y=P[1].isLoading;return(0,g.jsxs)(Z.Z,{breadcrumbs:_,errors:b,pageName:x.M.BACKFILLS,pipeline:e,setErrors:m,title:function(n){var e=n.name;return"".concat(e," backfills")},uuid:"".concat(x.M.BACKFILLS,"_").concat(r),children:[(0,g.jsx)(D.Z,{p:T.cd,children:(0,g.jsx)(A.ZP,{beforeElement:(0,g.jsx)(O.mm,{size:2.5*T.iI}),blackBorder:!0,inline:!0,loading:y,noHoverUnderline:!0,onClick:function(){return N({backfill:{name:(0,V.Y6)()}})},sameColorAsText:!0,uuid:"PipelineDetailPage/Backfills/add_new_backfill",children:"Create new backfill"})}),o&&0===o.length&&(0,g.jsx)(D.Z,{p:T.cd,children:(0,g.jsx)(E.ZP,{bold:!0,default:!0,monospace:!0,muted:!0,children:"No backfills available"})}),(null===o||void 0===o?void 0:o.length)>=1&&(0,g.jsx)(w,{models:o,onClickRow:function(n){var e=n.id;return(0,S.u7)({backfill_id:e})},pipeline:e,selectedRow:d})]})}M.getInitialProps=function(){var n=(0,r.Z)(o().mark((function n(e){var t;return o().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return t=e.query.pipeline,n.abrupt("return",{pipeline:{uuid:t}});case 2:case"end":return n.stop()}}),n)})));return function(e){return n.apply(this,arguments)}}();var Y=(0,C.Z)(M)},37459:function(n,e,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/pipelines/[pipeline]/backfills",function(){return t(11650)}])},80022:function(n,e,t){"use strict";function r(n){if(void 0===n)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n}t.d(e,{Z:function(){return r}})},15544:function(n,e,t){"use strict";function r(n){return r=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},r(n)}t.d(e,{Z:function(){return r}})},13692:function(n,e,t){"use strict";t.d(e,{Z:function(){return i}});var r=t(61049);function i(n,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");n.prototype=Object.create(e&&e.prototype,{constructor:{value:n,writable:!0,configurable:!0}}),e&&(0,r.Z)(n,e)}},93189:function(n,e,t){"use strict";t.d(e,{Z:function(){return u}});var r=t(12539),i=t(80022);function u(n,e){if(e&&("object"===r(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return(0,i.Z)(n)}},61049:function(n,e,t){"use strict";function r(n,e){return r=Object.setPrototypeOf||function(n,e){return n.__proto__=e,n},r(n,e)}t.d(e,{Z:function(){return r}})}},function(n){n.O(0,[2678,1154,844,4267,600,8487,8264,7858,5499,5457,9774,2888,179],(function(){return e=37459,n(n.s=e);var e}));var e=n.O();_N_E=e}]);
|