nginx-upsync-module icon indicating copy to clipboard operation
nginx-upsync-module copied to clipboard

ngx_print_escape 函数只在 NGX_HTTP_UPSTREAM_CHECK 开启时定义

Open imjustfly opened this issue 9 years ago • 1 comments

ngx_print_escape 函数只在 NGX_HTTP_UPSTREAM_CHECK 开启时定义,否则gcc会报一个「定义后未使用」的错误,而且该函数只在NGX_HTTP_UPSTREAM_CHECK开启的时候才会被调用,所以将函数定义也放在upstream check中也更合适。

imjustfly avatar Dec 30 '15 04:12 imjustfly

yeah, great, thanks!

之前的策略是支持把upstream 的配置dump 的本地,目的:保持远程与本地server配置的一致性,降低nginx 对配置中心的依赖性,在配置中心出问题时,可以随时的本地reload。 现在发现dump upstream 太重,upstream 内的子配置项很多,要实现上面的目的,只要dump upstream 内的server 便可,所以新的分支里便把此部分去掉了

当前只支持consul,为了便于添加其它的配置服务,做了一个架构调整,见分支:https://github.com/weibocom/nginx-upsync-module/tree/support_other_conf_server ;

这个分支已通过测试,添加些回归测试用例,便会merge 到主分支;欢迎提交对其它配置服务的pr(etcd、zk...)thanks

@imjustfly

xiaokai-wang avatar Dec 30 '15 06:12 xiaokai-wang