@weamd/nacosdiscovery
v1.0.8
Published
与 `nacos` 对外接口一致
Downloads
1
Readme
@weamd/nacosdiscovery
与 nacos
对外接口一致
install
yarn add @weamd/nacosdiscovery
example
import { NacosDiscoveryClient } from '@weamd/nacosdiscovery';
const client = new NacosDiscoveryClient({
serverList: ['10.12.101.29:8848'],
logger: console,
namespace: 'public',
syncInterval: 30000,
});
client.ready().then(() => {
client.registerInstance('nodejs-xx-service', {
ip: '192.168.1.1',
port: 7001,
});
});