-
Notifications
You must be signed in to change notification settings - Fork 534
feat(Feature Lifecycle): Update API with feature lifecycle info #7789
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
emyller
wants to merge
23
commits into
main
Choose a base branch
from
feat/feature-lifecycle-api-endpoints
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
23 commits
Select commit
Hold shift + click to select a range
fa6c72b
Sanitise InfluxDB API
emyller ca7127a
Merge remote-tracking branch 'github/main' into feat/lifecycle-api
emyller 9326c3d
Introduce foundation for feature lifecycle
emyller a746974
Fix lint
emyller fac1a2e
Feature lifecycle summary
emyller 8788442
Proven Influxdb flavour!
emyller 450a2c6
Unhappy paths
emyller a637c31
Ignore mypy cache
emyller 5ed1952
Make it portable
emyller 0941176
TDD for existing endpoints
emyller bc4570d
Add lifecycle stage to existing feature endpoints
emyller 71361ae
Add lifecycle counts to the MCP stack
emyller 247e682
Log
emyller c54b9fd
Filter by stage
emyller 20ee233
Fix lint
emyller 5bdce13
Fix event catalogue
emyller 76de9b7
Clean up API
emyller 952c924
Merge remote-tracking branch 'github/main' into feat/feature-lifecycl…
emyller 6b7c8d5
Clean up querying
emyller ec7875a
Slop
emyller a9273d0
Improve API
emyller 2d75b64
"Faster!" they said
emyller 9a39d26
🗡️ it right
emyller File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
23 changes: 23 additions & 0 deletions
23
api/app_analytics/migrations/0009_analytics_buckets_index.py
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,23 @@ | ||
| # Generated by Django 5.2.15 on 2026-06-24 14:52 | ||
|
|
||
| from django.db import migrations, models | ||
|
|
||
|
|
||
| class Migration(migrations.Migration): | ||
|
|
||
| dependencies = [ | ||
| ("app_analytics", "0008_labels_jsonb"), | ||
| ] | ||
|
|
||
| operations = [ | ||
| migrations.AlterField( | ||
| model_name="apiusagebucket", | ||
| name="created_at", | ||
| field=models.DateTimeField(db_index=True), | ||
| ), | ||
| migrations.AlterField( | ||
| model_name="featureevaluationbucket", | ||
| name="created_at", | ||
| field=models.DateTimeField(db_index=True), | ||
| ), | ||
| ] |
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
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| from rest_framework import serializers | ||
|
|
||
|
|
||
| class FeatureLifecycleCountsSerializer(serializers.Serializer[dict[str, int]]): | ||
| """Number of features in each lifecycle stage for an environment""" | ||
|
|
||
| new = serializers.IntegerField() | ||
| live = serializers.IntegerField() | ||
| stale = serializers.IntegerField() | ||
| permanent = serializers.IntegerField() | ||
| needs_monitoring = serializers.IntegerField() | ||
| to_remove = serializers.IntegerField() |
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is currently a seq scan. Do we need to add an index to
FeatureEvaluationBucket?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe... A bit of scope creep but I added 2d75b64 since it's low-cost in effort — both evaluation and usage buckets are often queried for by
created_at.I wonder though if adding either index here may cause a sudden spike in db storage for certain self-hosted customers? 🤔
Please cast a vote.