fix(ARTESCA-17607): fix Rubrik bucket name UX issues (points 2-6)#1211
Closed
damiengillesscality wants to merge 598 commits into
Closed
fix(ARTESCA-17607): fix Rubrik bucket name UX issues (points 2-6)#1211damiengillesscality wants to merge 598 commits into
damiengillesscality wants to merge 598 commits into
Conversation
…hZenkoConfigurationMutation
…us/w/4.2/bugfix/deployment-polling-fast-complete
…/4.2/improvement/bump-core-ui
- Add definePlatform API for declarative platform configuration - Implement buildFields for field generation with overrides - Implement buildMutations for mutation sequence generation - Add composable Joi validators (account, iam, buckets, immutable) - Define comprehensive TypeScript types (FormData, FullContext, FieldDef, MutationDef) - Export minimal public API through engine/index.ts
- Add Commvault platform with WORM bucket support - Add Veeam VBR platform with SOS API, capacity, and perBucketSteps - Add Veeam VBO platform with application selector and conditional immutable - Include platform registry for centralized platform management - Add comprehensive unit tests for all platforms
- Implement FormRenderer for dynamic field rendering based on FieldDef - Add AccountSelectorField for account selection with create/existing toggle - Add IAMUserSelectorField for IAM user management in advanced settings - Add BucketArrayField for dynamic bucket array handling - Add shared PlatformTooltips for reusable tooltip components - Add useMutationExecutor hook for template-to-mutation conversion - Add ISVFormContext for form state management
- Refactor ISVConfiguration to use FormRenderer and platform templates - Simplify ISVApplyActions using useMutationExecutor - Update ISVModal to use platform registry and disabledMessage - Update ISVSteps, ISVSummary for template-driven flow - Streamline types/index.ts by moving types to engine/types.ts - Update all related tests for new architecture
- Remove deprecated modules/ directory (commvault, veeam, veeam-vbo) - Move VeeamLogo, CommvaultLogo to components/logos/ - Move Veeam capacity components to components/veeam/ - Consolidate CapacityTooltip and VeeamCapacityTooltip in PlatformTooltips - Update import paths across codebase - Clean up unused exports and types
- Update all components to replace 'template' with 'platform' for consistency - Adjust related types and props to reflect the new naming convention - Modify tests to ensure they align with the updated component structure
…port - Introduce SummaryRenderProps type for improved prop management - Refactor ISVSummary to support custom rendering via platform configuration - Update related tests to remove platform references and align with new structure - Clean up unused code and streamline the component's logic
…and mutations - Rename `insertFields` to `additionalFields` for clarity and consistency - Change `mutations` to `mutationOverrides` to better reflect its purpose - Update related functions and types to align with new naming conventions - Ensure backward compatibility by adjusting existing platform implementations
…nto w/4.2/feature/isv-template-refactor
…late' into w/4.2/feature/fix-customRender-in-template
…and mutations - Rename `insertFields` to `additionalFields` for clarity and consistency - Change `mutations` to `mutationOverrides` to better reflect its purpose - Update related functions and types to align with new naming conventions - Ensure backward compatibility by adjusting existing platform implementations feat(isv): enhance summary screen customization and integrate S3 service point fix(tests): correct syntax in VeeamVBRPlatform test cases for consistency test feature feat(isv): add VeeamRepositorySummary component and mock repository creation refactor(isv): streamline ISVApplyActions and ISVSummary components
feat(isv): implement actual API call for Veeam repository creation and error handling fix(tests): add missing newline at the end of the VeeamVBRPlatform test file fix(tests): ensure newline at the end of the VeeamVBRPlatform test file feat(isv): add Veeam folder path constants and update platform configuration to use them
…IMutation and enhance deployment state checks in usePatchZenkoConfigurationMutation
…o utilize useCurrentApp for dynamic base URL
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Pensieve returns 204 No Content from GET /account/{canonicalId}/metrics
when an account has no storage consumption metrics yet. The generated
management client calls response.json() on every 2xx response, which
throws on an empty body, causing the Locations tab to display
"An error occurred while loading the locations".
Re-apply the original 2023 fix (22c7448) in the same place. It was
wiped by the ZKUI-447 regen (2601c0c) and the restore attempt
(5f4020a) landed on the wrong function (inviteOrbitUsersByEmail).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
PR #1166 synced accountName on account-radio switch but the Continue button could still freeze silently. Several paths left the form invalid with no visible reason, because the Controller's defaultValue is ignored once the field is already registered -- the Select/Input displays a value while form state stays empty. Apply defense in depth across the full switch flow: - AccountSelectorField: after resetIAMFields, also call onAccountSelected(accounts[0].name) when switching to 'existing' so the radio path fetches IAM users just like picking the account via the Select. - ISVFormContext.resetIAMFields: pre-fill IAMUserName with the account name synchronously on 'existing' switch, so the form stays valid even if onAccountSelected's async AssumeRole hangs or fails. - ISVFormContext.onAccountSelected: when IAM users exist but none matches accountName, default IAMUserName to Users[0].UserName (in addition to expanding the accordion), keeping UI and form state in sync. - IAMUserSelectorField: add a missing onOptionChange that explicitly setValue('IAMUserName', ...) on mode switch, mirroring PR #1166's pattern for accountName. Tests (built with TDD -- each added test was confirmed RED before the fix): - Radio-only path (no advanced settings, no Select interaction). - IAM user fetch that never resolves. - IAM users present but none matches accountName. - IAM user radio round-trip (existing -> create -> existing). - Two existing tests updated from getByText('test-user') to getByRole('option', { name: 'test-user' }) since the IAM Select now pre-fills, matching PR #1166's getByText('test-account') treatment. Relates to ARTESCA-17417. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Add ISVConnectorModal as a federated module so other UIs (e.g. the new Overview page) can import and render the ISV selection dialog. Navigation on Continue uses openLink for cross-app routing, with a HistoryPushEvent fallback when already in zenko-ui context — same pattern as WelcomeModal. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
ISVConnectorModal test and fix core-ui bump breakage
…latforms without immutability Platforms using disableImmutability: true (e.g. Rubrik) do not declare enableImmutableBackup in their Joi validator. Including the field in the base form defaults caused Joi to reject it as an unknown key, keeping isValid: false and preventing the Continue button from being enabled. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…y update logic The shared useCreateOrAddBucketToPolicyMutation fingerprints the main statement by checking for all defaultActions. Rubrik's original policy was missing GetBucketVersioning and GetBucketObjectLockConfiguration, so statementIndex always returned -1, causing duplicate statements to be appended on each re-run instead of updating the resource list. Additionally, the code pushed Statement[1] of the new policy to add the ListAllMyBuckets statement — but Rubrik's original single-statement policy had no Statement[1], resulting in null being serialized into the policy document and a MalformedPolicyDocument error from IAM. Fix: restructure GET_RUBRIK_POLICY to match the two-statement pattern (bucket-scoped actions + wildcard ListBucket statement) used by all other platforms, and include defaultActions so fingerprinting works. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…r Rubrik Rubrik recently introduced Object Lock (S3 immutability). Three things change as a result: - Immutability toggle is now enabled for the Rubrik platform (removes disableImmutability and customValidator overrides). The bucket is created with ObjectLockEnabledForBucket when the toggle is on, which also enables S3 versioning automatically — no separate step needed. - GET_RUBRIK_POLICY is now conditional: the non-immutable path keeps the existing two-statement structure; the immutable path generates a three-statement policy (GlobalPermission / BucketLevel / ObjectLevel) matching the spec provided in the PR review and confirmed by the official ISV-437 guide. The immutable policy adds s3:PutBucketObjectLockConfiguration, s3:GetBucketPublicAccessBlock, s3:GetBucketPolicy, and all object-version/retention/legal-hold actions required by Rubrik for versioned Object Lock buckets. - The static openssl command in the summary is replaced by RubrikRSAKeySection, which generates a 2048-bit RSA key in the browser on mount (Web Crypto API), extracts the PKCS#1 payload from the PKCS#8 output, and renders the key with copy and download buttons. Rubrik CDM requires PKCS#1 format (BEGIN RSA PRIVATE KEY). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…ation Docs-only ISVs reaching the else branch have no entry in the ISV config registry, so passing ?platform would cause AccountCreate to redirect to /isv/configuration for an unknown platform after account creation. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…ints 2-6)
- Point 2: fix Joi error message template — {N} was treated as a Joi variable
and resolved to empty; replaced with literal <number> in both string.min and
string.pattern.name messages so the full error always shows
- Point 3: wire helpText from fieldOverrides through buildFields → BucketArrayField
→ BucketField → FormGroup so it renders as visible helper text below the field
- Point 4: wire tooltip from fieldOverrides through the same chain so the platform
tooltip (using ListItem) is used instead of the default Text-based tooltip,
matching the font size of other fields
- Point 5: fix 'an unique' → 'a unique' in defaultBucketNameTooltip
- Point 6: update Immutable Backup helper text to
'Enables object lock on the bucket, making backups permanent and unchangeable.'
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes points 2–6 from ARTESCA-17607 — UX issues on the bucket name field and form validation in the Rubrik ISV assistant.
{N}in the Joi message string was treated as a Joi template variable and resolved to empty, producing"must end with -rubrik-". Replaced with literal<number>in bothstring.minandstring.pattern.namemessages.helpTextfromfieldOverrides.bucketNamethroughbuildFields→BucketArrayField→BucketField→FormGroup.helpso the format requirement renders as visible text below the field instead of being hidden behind the IconHelp tooltip.tooltipfromfieldOverrides.bucketNamethrough the same chain so the platform-specific tooltip (usingListItem, consistent with other fields) is used instead of the fallback plain<Text>tooltip."Choose an unique name"→"Choose a unique name"indefaultBucketNameTooltip."Enables object lock on the bucket, making backups permanent and unchangeable.".Test plan
Bucket name must end with -rubrik-<number> (e.g. my-archive-rubrik-0)-rubrik-<N>suffix — same error messageMust end with -rubrik-<number> (e.g. my-archive-rubrik-0)is visible below the bucket name field without opening any tooltipnpx jest --testNamePattern="rubrik|Rubrik"🤖 Generated with Claude Code