Github user meiercaleb commented on a diff in the pull request:

    https://github.com/apache/incubator-rya/pull/251#discussion_r153582032
  
    --- Diff: 
extras/rya.pcj.fluo/pcj.fluo.app/src/main/java/org/apache/rya/indexing/pcj/fluo/app/query/FluoQueryMetadataCache.java
 ---
    @@ -0,0 +1,247 @@
    +/*
    + * Licensed to the Apache Software Foundation (ASF) under one
    + * or more contributor license agreements.  See the NOTICE file
    + * distributed with this work for additional information
    + * regarding copyright ownership.  The ASF licenses this file
    + * to you under the Apache License, Version 2.0 (the
    + * "License"); you may not use this file except in compliance
    + * with the License.  You may obtain a copy of the License at
    + *
    + *   http://www.apache.org/licenses/LICENSE-2.0
    + *
    + * Unless required by applicable law or agreed to in writing,
    + * software distributed under the License is distributed on an
    + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
    + * KIND, either express or implied.  See the License for the
    + * specific language governing permissions and limitations
    + * under the License.
    + */package org.apache.rya.indexing.pcj.fluo.app.query;
    +
    +import static com.google.common.base.Preconditions.checkArgument;
    +
    +import java.util.concurrent.Callable;
    +
    +import org.apache.fluo.api.client.SnapshotBase;
    +import org.apache.fluo.api.data.Bytes;
    +import org.apache.fluo.api.data.Column;
    +import org.apache.rya.indexing.pcj.fluo.app.NodeType;
    +import org.slf4j.Logger;
    +import org.slf4j.LoggerFactory;
    +
    +import com.google.common.base.Optional;
    +import com.google.common.cache.Cache;
    +import com.google.common.cache.CacheBuilder;
    +
    +/**
    + * Wrapper for {@link FluoQueryMetadataDAO} that caches any metadata that 
has been retrieved from Fluo. This class first
    + * checks the cache to see if the metadata is present before delegating to 
the underlying DAO method to retrieve the
    + * data.
    + *
    + */
    +public class FluoQueryMetadataCache extends FluoQueryMetadataDAO {
    --- End diff --
    
    The delete question might actually be a problem.  I'm going to create a 
Jira ticket for this.  We need some way to notify the workers when metadata has 
been deleted so that the caches on each JVM can purge the metadata for any 
deleted nodeIds.


---

Reply via email to