Skip to content

Conversation

@mikemcdougall
Copy link
Collaborator

Summary

Implements the FeatureServer applyEdits endpoint for CRUD operations as specified in issue #11.

Changes

  • ✅ POST /rest/services/{serviceId}/FeatureServer/{layerId}/applyEdits endpoint
  • ✅ Support for adds array to create new features
  • ✅ Support for updates array to update existing features by objectId
  • ✅ Support for deletes array to remove features by objectId
  • ✅ Response includes success/failure per operation with appropriate error codes
  • ✅ Proper JSON serialization with Esri-compatible models
  • ✅ Comprehensive integration tests for all operations
  • ✅ Support for mixed operations in single request
  • ✅ Feature validation and error handling

Implementation Details

  • Added ApplyEditsRequest/Response models with proper JSON context
  • Implemented ProcessAddOperationsAsync, ProcessUpdateOperationsAsync, ProcessDeleteOperationsAsync
  • Added structured logging for operations
  • Follows existing code patterns and architecture
  • Uses existing IFeatureStore interface methods (CreateAsync, UpdateAsync, DeleteAsync)

Test Coverage

  • Integration test: add feature returns new objectId
  • Integration test: update feature modifies by objectId
  • Integration test: delete feature removes from database
  • Integration test: mixed operations work correctly
  • Integration test: error handling for invalid operations

Closes #11

Mike McDougall added 2 commits December 20, 2025 22:51
- Add ApplyEdits endpoint for CRUD operations
- Support for adding, updating, and deleting features
- Add ApplyEditsRequest/Response models with proper JSON serialization
- Implement feature validation and error handling
- Add comprehensive integration tests for all operations
- Support mixed operations in single request

Fixes #11
Applied dotnet format to fix IDE0055 formatting violations that were causing CI build failures. This resolves the "Build & Format Check" CI failure.

No functional changes - formatting only.
@github-actions
Copy link

🤖 LLM Architecture Review

Assessment: APPROVED

🏗️ Architecture Review Summary

⚠️ OpenAI Analysis Error:
Error calling OpenAI API: Error code: 429 - {'error': {'message': 'Request too large for gpt-4-turbo-preview in organization org-rf4P6tWUtUKBIeMU1oBdAkPn on tokens per min (TPM): Limit 30000, Requested 47064. The input or output tokens must be reduced in order to run successfully. Visit https://platform.openai.com/account/rate-limits to learn more.', 'type': 'tokens', 'param': None, 'code': 'rate_limit_exceeded'}}

💡 Fallback Recommendation:
Please configure OPENAI_API_KEY in repository secrets and ensure OpenAI credits are available.

Overall Assessment: NEEDS_ATTENTION (API Configuration Issue)

Falling back to basic static analysis...


Automated architectural analysis powered by OpenAI GPT-4
This review focuses on architectural patterns and design decisions
Human review still recommended for complex changes

@mikemcdougall mikemcdougall merged commit 0d124ad into trunk Dec 21, 2025
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ApplyEdits endpoint with add/update/delete

2 participants