-
Notifications
You must be signed in to change notification settings - Fork 32
Ambient breakdown sessions handler #242
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
Ambient breakdown sessions handler #242
Conversation
d6f63d4 to
94d233f
Compare
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
Break up backend/handlers/sessions.go,rfe.go,projects.go into smaller files for improved development and maintainability. Signed-off-by: sallyom <somalley@redhat.com> Co-authored-by: Gage Krumbach <gkrumbach@gmail.com> Co-authored-by: Claude <noreply@anthropic.com>
bc93a82 to
464a3e9
Compare
1640cfc to
eb1de06
Compare
This comment was marked as outdated.
This comment was marked as outdated.
Signed-off-by: sallyom <somalley@redhat.com>
eb1de06 to
6c1a1d2
Compare
Pull Request Review: Backend Refactor - Breaking Down Large Handler FilesOverviewThis PR implements a significant refactoring of the backend handlers, breaking down two massive files ( ✅ Strengths1. Excellent Code OrganizationThe file breakdown follows clear separation of concerns: Sessions Module (formerly
RFE Module (formerly
Projects Module (formerly
This breakdown significantly improves:
2. Type-Safe Helper FunctionsThe new helper functions in func GetMetadataMap(obj *unstructured.Unstructured) (map[string]interface{}, bool)
func GetSpecMap(obj *unstructured.Unstructured) (map[string]interface{}, bool)
func GetStatusMap(obj *unstructured.Unstructured) (map[string]interface{}, bool)These replace unsafe type assertions (like
Impact: Prevents runtime panics when dealing with Kubernetes Custom Resources. 3. Improved DocumentationAll new files have:
Example from // RetryWithBackoff attempts an operation with exponential backoff.
// Used for operations that may temporarily fail due to async resource creation.
//
// Parameters:
// - maxRetries: Maximum number of retry attempts
// - initialDelay: Initial delay duration before first retry
// ...4. Frontend Improvements
5. golangci-lint ConfigurationThe simplified
|
| Category | Score | Notes |
|---|---|---|
| Code Quality | 9/10 | Excellent organization, minor type safety verification needed |
| Security | 10/10 | All patterns correct, no violations found |
| Performance | 8/10 | ResolveContentServiceName could be optimized |
| Testing | 5/10 | No new tests, must verify existing tests pass |
| Documentation | 9/10 | Excellent inline docs, CLAUDE.md updates consistent |
Overall: Strong Approve pending verification of linting and tests.
Great work on this refactor! 🎉
|
Merging! ✅ Safe to Merge As-Is
|
@Gkrumbach07 I'm testing now :) --------- Signed-off-by: sallyom <somalley@redhat.com> Co-authored-by: Gage Krumbach <gkrumbach@gmail.com> Co-authored-by: Claude <noreply@anthropic.com>
This reverts commit 8a8e409.
This reverts commit 47eccf0.
Merged upstream/main (Ambient breakdown sessions handler ambient-code#242) into feature/gitlab-support branch. Resolved conflicts: 1. types/session.go - Preserved both GitLab mixed provider types and new session management types from upstream 2. handlers/rfe.go - File was deleted upstream and split into multiple files (rfe_agents.go, rfe_crud.go, rfe_seeding.go, rfe_sessions.go, rfe_types.go). Ported GitLab provider detection logic to new rfe_seeding.go file for SeedProjectRFEWorkflow and CheckProjectRFEWorkflowSeeding functions. The merge preserves all GitLab integration functionality while adopting the new modular handler structure from upstream. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Merged upstream/main which reverted PR ambient-code#242 "Ambient breakdown sessions handler". This brought back the monolithic handler structure. Resolved conflicts: 1. handlers/rfe.go - Ported GitLab provider detection logic from deleted rfe_seeding.go into the reverted rfe.go file for both SeedProjectRFEWorkflow() and CheckProjectRFEWorkflowSeeding() functions. Fixed variable redeclaration error by removing duplicate 'var err error' declaration. 2. types/session.go - Kept GitLab mixed provider types (ProviderResult, MixedProviderSessionResult) from our feature branch. 3. Deleted handlers/rfe_seeding.go as it was removed in the revert. All GitLab integration functionality preserved while adopting the reverted monolithic structure. Verified compilation succeeds with no errors. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
@Gkrumbach07 I'm testing now :) --------- Signed-off-by: sallyom <somalley@redhat.com> Co-authored-by: Gage Krumbach <gkrumbach@gmail.com> Co-authored-by: Claude <noreply@anthropic.com>
…nt-code#253) This reverts commit 47eccf0.
@Gkrumbach07 I'm testing now :) --------- Signed-off-by: sallyom <somalley@redhat.com> Co-authored-by: Gage Krumbach <gkrumbach@gmail.com> Co-authored-by: Claude <noreply@anthropic.com>
…nt-code#253) This reverts commit 47eccf0.
@Gkrumbach07 I'm testing now :) --------- Signed-off-by: sallyom <somalley@redhat.com> Co-authored-by: Gage Krumbach <gkrumbach@gmail.com> Co-authored-by: Claude <noreply@anthropic.com>
…nt-code#253) This reverts commit 47eccf0.
@Gkrumbach07 I'm testing now :) --------- Signed-off-by: sallyom <somalley@redhat.com> Co-authored-by: Gage Krumbach <gkrumbach@gmail.com> Co-authored-by: Claude <noreply@anthropic.com>
…nt-code#253) This reverts commit 47eccf0.
@Gkrumbach07 I'm testing now :) --------- Signed-off-by: sallyom <somalley@redhat.com> Co-authored-by: Gage Krumbach <gkrumbach@gmail.com> Co-authored-by: Claude <noreply@anthropic.com>
…nt-code#253) This reverts commit 47eccf0.
@Gkrumbach07 I'm testing now :) --------- Signed-off-by: sallyom <somalley@redhat.com> Co-authored-by: Gage Krumbach <gkrumbach@gmail.com> Co-authored-by: Claude <noreply@anthropic.com>
…nt-code#253) This reverts commit 47eccf0.
@Gkrumbach07 I'm testing now :)