impala-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chen Huang <paulhuan...@gmail.com>
Subject Synchronization in CatalogOpExecutor
Date Tue, 03 May 2016 17:14:23 GMT
Hi,

I saw we are doing some synchronization in CatalogOpExecutor:
https://github.com/cloudera/Impala/blob/cdh5-trunk/fe/src/main/java/com/cloudera/impala/service/CatalogOpExecutor.java#L337

Can anybody help me understand what the effect of synchronizing on a
method-local variable tbl?
- Doesn't each thread get its own copy of tbl, which is just a reference to
the actual table object and thus end up synchronize with only itself since
no other threads can ever share the same local copy of tbl?
- Isn't the lock on catalog_ already doing the global synchronization? Why
do we need another synchronization on tbl?

Thanks,
Chen

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message