fix: restrict batch import by gateway type and product type compatibility#273
Merged
learnerjohn merged 1 commit intohigress-group:mainfrom Apr 17, 2026
Merged
Conversation
…lity - Fix HigressModelResult missing modelApiId/modelApiName fields - Add backend validation: Higress only supports MCP_SERVER batch import - Add backend validation: Nacos does not support REST_API import - HigressOperator.fetchAgentAPIs returns empty PageResult instead of null - Frontend: disable unsupported source types with tooltip instead of hiding - Frontend: hide batch import button for AGENT_SKILL/WORKER (use dedicated Nacos import)
learnerjohn
approved these changes
Apr 17, 2026
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
📝 Description
modelApiId/modelApiNamefields, which caused the import dialog to show empty service names when importing from HigressvalidateImportParam: Higress gateway only supports MCP_SERVER batch import; REST_API, AGENT_API, and MODEL_API are explicitly rejected with clear error messagesHigressOperator.fetchAgentAPIs()returningnullinstead of emptyPageResult, which could cause NPEBackground
The batch import feature was originally designed for MCP_SERVER and AGENT_API from Gateway/Nacos. However, it was inadvertently exposed for all product types including REST_API, MODEL_API, AGENT_SKILL, and WORKER. This caused several issues:
🔗 Related Issues
Fix #272
✅ Type of Change
🧪 Testing
INVALID_REQUESTwith clear messageINVALID_REQUESTwith clear messageINVALID_REQUESTwith clear message📋 Checklist
mvn spotless:applyfor backend,npm run lint:fixfor frontend)