-
- All Implemented Interfaces:
-
graphql.execution.preparsed.persisted.PersistedQueryCache
public interface AutomaticPersistedQueriesCache implements PersistedQueryCache
-
-
Method Summary
Modifier and Type Method Description PreparsedDocumentEntry
getPersistedQueryDocument(Object persistedQueryId, ExecutionInput executionInput, PersistedQueryCacheMiss onCacheMiss)
CompletableFuture<PreparsedDocumentEntry>
getPersistedQueryDocumentAsync(Object persistedQueryId, ExecutionInput executionInput, PersistedQueryCacheMiss onCacheMiss)
abstract CompletableFuture<PreparsedDocumentEntry>
getOrElse(String key, Function0<PreparsedDocumentEntry> supplier)
Get the PreparsedDocumentEntry associated with the key from the cache. -
-
Method Detail
-
getPersistedQueryDocument
@Deprecated(message = "deprecated in favor of async retrieval of PreparsedDocumentEntry", replaceWith = @ReplaceWith(imports = {}, expression = "getPersistedQueryDocumentAsync(persistedQueryId, executionInput, onCacheMiss)")) PreparsedDocumentEntry getPersistedQueryDocument(Object persistedQueryId, ExecutionInput executionInput, PersistedQueryCacheMiss onCacheMiss)
-
getPersistedQueryDocumentAsync
CompletableFuture<PreparsedDocumentEntry> getPersistedQueryDocumentAsync(Object persistedQueryId, ExecutionInput executionInput, PersistedQueryCacheMiss onCacheMiss)
-
getOrElse
abstract CompletableFuture<PreparsedDocumentEntry> getOrElse(String key, Function0<PreparsedDocumentEntry> supplier)
Get the PreparsedDocumentEntry associated with the key from the cache.
If the PreparsedDocumentEntry is missing in the cache, the supplier will provide one, and then it should be added to the cache.
- Parameters:
key
- The hash of the requested query.supplier
- that will provide the document in case there is a cache miss.
-
-
-
-