Interface AsyncDatastoreService
-
- All Superinterfaces:
- BaseDatastoreService
- All Known Implementing Classes:
- AdminDatastoreService
public interface AsyncDatastoreService extends BaseDatastoreService
An asynchronous version ofDatastoreService
. All methods return immediately and provideFutures
as their return values.The key difference between implementations of
AsyncDatastoreService
and implementations ofDatastoreService
is that async implementations do not perform implicit transaction management. The reason is that implicit transaction management requires automatic commits of some transactions, and without some sort of callback mechanism there is no way to determine that a put/get/delete that has been implicitly enrolled in a transaction is complete and therefore ready to be committed. SeeImplicitTransactionManagementPolicy
for more information.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method and Description java.util.concurrent.Future<KeyRange>
allocateIds(Key parent, java.lang.String kind, long num)
java.util.concurrent.Future<KeyRange>
allocateIds(java.lang.String kind, long num)
java.util.concurrent.Future<Transaction>
beginTransaction()
java.util.concurrent.Future<Transaction>
beginTransaction(TransactionOptions options)
java.util.concurrent.Future<java.lang.Void>
delete(java.lang.Iterable<Key> keys)
java.util.concurrent.Future<java.lang.Void>
delete(Key... keys)
java.util.concurrent.Future<java.lang.Void>
delete(Transaction txn, java.lang.Iterable<Key> keys)
java.util.concurrent.Future<java.lang.Void>
delete(Transaction txn, Key... keys)
java.util.concurrent.Future<java.util.Map<Key,Entity>>
get(java.lang.Iterable<Key> keys)
java.util.concurrent.Future<Entity>
get(Key key)
java.util.concurrent.Future<java.util.Map<Key,Entity>>
get(Transaction txn, java.lang.Iterable<Key> keys)
java.util.concurrent.Future<Entity>
get(Transaction txn, Key key)
java.util.concurrent.Future<DatastoreAttributes>
getDatastoreAttributes()
java.util.concurrent.Future<java.util.Map<Index,Index.IndexState>>
getIndexes()
java.util.concurrent.Future<Key>
put(Entity entity)
java.util.concurrent.Future<java.util.List<Key>>
put(java.lang.Iterable<Entity> entities)
java.util.concurrent.Future<Key>
put(Transaction txn, Entity entity)
java.util.concurrent.Future<java.util.List<Key>>
put(Transaction txn, java.lang.Iterable<Entity> entities)
-
Methods inherited from interface com.google.appengine.api.datastore.BaseDatastoreService
getActiveTransactions, getCurrentTransaction, getCurrentTransaction, prepare, prepare
-
-
-
-
Method Detail
-
get
java.util.concurrent.Future<Entity> get(Key key)
- See Also:
DatastoreService.get(Key)
-
get
java.util.concurrent.Future<Entity> get(Transaction txn, Key key)
- See Also:
DatastoreService.get(Transaction, Key)
-
get
java.util.concurrent.Future<java.util.Map<Key,Entity>> get(java.lang.Iterable<Key> keys)
- See Also:
DatastoreService.get(Iterable)
-
get
java.util.concurrent.Future<java.util.Map<Key,Entity>> get(Transaction txn, java.lang.Iterable<Key> keys)
-
put
java.util.concurrent.Future<Key> put(Entity entity)
- See Also:
DatastoreService.put(Entity)
-
put
java.util.concurrent.Future<Key> put(Transaction txn, Entity entity)
-
put
java.util.concurrent.Future<java.util.List<Key>> put(java.lang.Iterable<Entity> entities)
- See Also:
DatastoreService.put(Iterable)
-
put
java.util.concurrent.Future<java.util.List<Key>> put(Transaction txn, java.lang.Iterable<Entity> entities)
-
delete
java.util.concurrent.Future<java.lang.Void> delete(Key... keys)
- See Also:
DatastoreService.delete(Key...)
-
delete
java.util.concurrent.Future<java.lang.Void> delete(Transaction txn, Key... keys)
-
delete
java.util.concurrent.Future<java.lang.Void> delete(java.lang.Iterable<Key> keys)
- See Also:
DatastoreService.delete(Iterable)
-
delete
java.util.concurrent.Future<java.lang.Void> delete(Transaction txn, java.lang.Iterable<Key> keys)
-
beginTransaction
java.util.concurrent.Future<Transaction> beginTransaction()
- See Also:
DatastoreService.beginTransaction()
-
beginTransaction
java.util.concurrent.Future<Transaction> beginTransaction(TransactionOptions options)
-
allocateIds
java.util.concurrent.Future<KeyRange> allocateIds(java.lang.String kind, long num)
-
allocateIds
java.util.concurrent.Future<KeyRange> allocateIds(Key parent, java.lang.String kind, long num)
-
getDatastoreAttributes
java.util.concurrent.Future<DatastoreAttributes> getDatastoreAttributes()
-
getIndexes
java.util.concurrent.Future<java.util.Map<Index,Index.IndexState>> getIndexes()
- See Also:
DatastoreService.getIndexes()
-
-