Support Dubbo configuration
API7 implements the httpproxy to dubbothrough the dubbo-proxy plugin.
Enable dubbo-proxy plugin
Enable
API7 does not load the dobbo-proxy plugin by default. You need to add the following configuration to the configuration file of the gateway node ./conf/config.yaml. Restart the gateway node and activate the plugin.
# Add this in config.yaml
plugins:
- ... # plugin you need
- dubbo-proxy
plugin_attr:
dubbo-proxy:
upstream_multiplex_count: 32
Parameter description
| Name | Type | Required | Default Value | Valid Value | Description |
|---|---|---|---|---|---|
| upstream_multiplex_count | number | Yes | 32 | >=1 | Maximum number of multiplex requests in an upstream connection |
Binding API
The activation method of the dubbo-proxy plugin was introduced earlier. After the plugin is activated, it can bind the API to implement the http proxy to dubbo.
When binding the API, the dubbo-proxy plugin only needs to configure one field, as described below:
| Name | Type | Required | Default Value | Description |
|---|---|---|---|---|
| service_name | string | Yes | Dubbo service name | |
| service_version | string | Yes | Dubbo service version | |
| method | string | No | URI path | Dubbo service method |