> On Oct. 3, 2018, 6:55 p.m., Sergio Pena wrote: > > sentry-hdfs/sentry-hdfs-service/src/main/java/org/apache/sentry/hdfs/PathImageRetriever.java > > Lines 97-107 (patched) > > <https://reviews.apache.org/r/68547/diff/9/?file=2093712#file2093712line97> > > > > Why do we need the sequence# and image# here? Those are already checked > > in the DbUpdateForward class. I think the cache invalidation here should be > > done by looking at the current snapshot ID on the SentryStore and comparing > > it with the one store in the cache.
We are not invalidating cache here. We are just checking if the cache is current. If it isn't, we fetch a fresh full update from Sentry Db, and update the cache - Arjun ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/68547/#review209184 ----------------------------------------------------------- On Oct. 2, 2018, 9:57 p.m., Arjun Mishra wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/68547/ > ----------------------------------------------------------- > > (Updated Oct. 2, 2018, 9:57 p.m.) > > > Review request for sentry, kalyan kumar kalvagadda, Na Li, and Sergio Pena. > > > Bugs: SENTRY-2370 > https://issues.apache.org/jira/browse/SENTRY-2370 > > > Repository: sentry > > > Description > ------- > > When NN requests path updates from sentry and if it exceeds the time > threshold, on consecutive attempts sentry will attempt to fetch the full > update from scratch. Instead it should cache it and update the cache before > sending it to NN > > > Diffs > ----- > > > sentry-hdfs/sentry-hdfs-common/src/main/java/org/apache/sentry/hdfs/ImageRetriever.java > 11b75411d > > sentry-hdfs/sentry-hdfs-service/src/main/java/org/apache/sentry/hdfs/DBUpdateForwarder.java > 08b16a4df > > sentry-hdfs/sentry-hdfs-service/src/main/java/org/apache/sentry/hdfs/PathImageRetriever.java > 3532ef33d > > sentry-hdfs/sentry-hdfs-service/src/main/java/org/apache/sentry/hdfs/PermImageRetriever.java > 443434127 > > sentry-hdfs/sentry-hdfs-service/src/test/java/org/apache/sentry/hdfs/TestDBUpdateForwarder.java > f86ce6f83 > > sentry-hdfs/sentry-hdfs-service/src/test/java/org/apache/sentry/hdfs/TestImageRetriever.java > fb42b279a > > > Diff: https://reviews.apache.org/r/68547/diff/9/ > > > Testing > ------- > > > Thanks, > > Arjun Mishra > >