-
Notifications
You must be signed in to change notification settings - Fork 466
Open
Flagsmith/flagsmith-backstage-plugin
#2Description
Summary
Refactor the Flagsmith Backstage plugin from backend plugin to proxy-based architecture, following the pattern used by LaunchDarkly, Harness, and other community plugins.
Parent Epic: #5641
Spike: #6359
Current Architecture
Frontend → Backend Plugin → Flagsmith API
(src/service/)
(35 API calls for 17 flags)
Target Architecture
Frontend → Backstage Proxy → Flagsmith API
(/proxy/flagsmith)
(1 call + lazy load on expand)
Benefits
| Aspect | Before | After |
|---|---|---|
| Installation | 2 packages (frontend + backend) | 1 package (frontend only) |
| Initial API calls | 35 (for 17 flags) | 1 |
| Configuration | Custom backend config | Standard proxy config |
| Pattern | Custom | Matches LaunchDarkly, Harness |
Implementation Tasks
- Update
FlagsmithClient.tsto use proxy (/proxy/flagsmith) - Add lazy loading methods (
getFeatureVersions,getFeatureStates) - Update
FlagsTab.tsxwith lazy loading on accordion expand - Update
FlagsmithOverviewCard.tsxfor new client - Delete
src/service/directory (backend plugin) - Update
src/index.tsto remove backend export - Update
package.jsonto remove backend dependencies - Update
README.mdwith proxy configuration
Proxy Configuration
Users will configure in app-config.yaml:
proxy:
endpoints:
'/flagsmith':
target: 'https://api.flagsmith.com/api/v1'
headers:
Authorization: Api-Key ${FLAGSMITH_API_TOKEN}Acceptance Criteria
- Plugin works with proxy configuration only
- No backend plugin required
- Lazy loading reduces initial API calls
- README updated with new installation steps
Metadata
Metadata
Assignees
Labels
No labels