ltotal/config_client

There is no license information available for the latest version (0.207) of this package.

Installs: 54

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 0

Open Issues: 0

pkg:composer/ltotal/config_client

0.207 2023-04-21 01:18 UTC

This package is auto-updated.

Last update: 2025-09-21 06:40:43 UTC


README

安装

composer require ltotal/config_client

使用

require_once './vendor/autoload.php';

use Ltotal\ConfigClient\ConfigClient;

$appConf = [
    'rpc_server' => 'tcp://127.0.0.1:1234', // 配置中心客户端服务
    'app_id' => 'sales-mkt', // 配置中心设置的应用id
    'app_secret' => '', // 配置中心的应用密钥
    'cluster' => 'default', // 配置中心使用的集群
    'cache_file_path' => './apollo', // 本地配置缓存路径
];

ConfigClient::init($appConf);
$data = ConfigClient::get('SALES.rz_hfdb_core');