File tree Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -110,7 +110,7 @@ ARCUS_ACL_ZOOKEEPER="127.0.0.1:2181" ARCUS_ACL_GROUP="prod"\
110110이 경우 ` ARCUS_ACL_ZOOKEEPER ` , ` ARCUS_ACL_GROUP ` 환경변수는 설정된 상태여야 정상 동작한다.
111111반대로, SASL 인증을 동적으로 비활성화하는 기능은 제공하지 않는다.
112112
113- ARCUS Cache Server는 ZooKeeper에 저장된 인증/권한 정보를 가져와서 캐싱하여 사용하며, 24시간 주기로 갱신한다 .
113+ ARCUS Cache Server는 ZooKeeper에 저장된 인증/권한 정보를 가져와서 캐싱하여 사용하며, 마지막 캐싱 시점으로부터 12- 24시간 사이 랜덤한 시간이 지난 뒤 캐싱 작업을 재수행한다 .
114114따라서 ACL 사용자 정보를 추가/수정/제거하는 경우 캐시에 반영되어 사용되기까지 최대 24시간이 소요될 수 있다.
115115필요 시 빠른 반영을 위해 ` reload auth ` 명령을 제공한다.
116116
Original file line number Diff line number Diff line change 1313
1414/* cache table's size */
1515#define SASL_TABLE_SIZE 16
16- #define REFRESH_PERIOD 24 * 60 * 60 /* sec */
16+ #define REFRESH_PERIOD 12 * 60 * 60 /* sec */
1717#define GROUP_MAXLEN 32
1818#define USERNAME_MAXLEN 32
1919#define PROPNAME_MAXLEN 32
@@ -176,12 +176,14 @@ static void* acl_refresh_thread(void *arg)
176176
177177 clock_gettime (CLOCK_REALTIME , & ts );
178178 srand (ts .tv_sec );
179- ts .tv_sec += rand () % REFRESH_PERIOD ;
180179
181180 mc_logger -> log (EXTENSION_LOG_INFO , NULL , "ACL refresh thread is running.\n" );
182181
183182 acl_thread_running = true;
184183 while (!acl_thread_stopreq ) {
184+ clock_gettime (CLOCK_REALTIME , & ts );
185+ ts .tv_sec += REFRESH_PERIOD + (rand () % REFRESH_PERIOD );
186+
185187 ts .tv_sec += REFRESH_PERIOD ;
186188 pthread_mutex_lock (& acl_thread_lock );
187189 if (!acl_thread_stopreq ) {
You can’t perform that action at this time.
0 commit comments