jhnmora000 commented on a change in pull request #156: GORA 411 - Add 
exists(key) to DataStore interface
URL: https://github.com/apache/gora/pull/156#discussion_r272807465
 
 

 ##########
 File path: 
gora-core/src/main/java/org/apache/gora/store/impl/DataStoreBase.java
 ##########
 @@ -150,6 +150,11 @@ public void setBeanFactory(BeanFactory<K, T> beanFactory) 
{
     return beanFactory;
   }
 
+       @Override
+       public boolean exists(K key) throws GoraException {
+               return get(key, new String[0]) != null;
 
 Review comment:
   As discussed on Jira[1] it would be better to not implement a default 
behavior for exists(), since future developers could ignore to code custom 
solutions and led to performance issues. I will remove this.
   [1] https://issues.apache.org/jira/browse/GORA-411

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to