-
Notifications
You must be signed in to change notification settings - Fork 4
Description
Is your feature request related to a problem? Please describe.
The frontend cannot access the validation logic directly from the validator microservice, causing CORS issues and tight coupling between frontend and services.
Describe the solution you'd like
Implement a dedicated /api/validate endpoint in the backend that receives payloads from the frontend and forwards them to the validator microservice. The backend should handle communication, response parsing, and error management.
Describe alternatives you've considered
Calling the validator service directly from the frontend, but this approach violates CORS policies and breaks the principle of service isolation.
Use Case
Provides a centralized API gateway for validation across multiple environments, allowing the frontend to request validation results securely and consistently.
Additional context
- Add caching for results based on a hash of the configuration to reduce repeated calls.
- Ensure proper error handling if the validator service is unavailable.
- Consider adding logging for validation requests for monitoring and debugging.