public class ClassLoaderSafeConnectorPageSink extends Object implements ConnectorPageSink
NOT_BLOCKED| Constructor and Description |
|---|
ClassLoaderSafeConnectorPageSink(ConnectorPageSink delegate,
ClassLoader classLoader) |
| Modifier and Type | Method and Description |
|---|---|
void |
abort() |
CompletableFuture<?> |
appendPage(Page page)
Returns a future that will be completed when the page sink can accept
more pages.
|
CompletableFuture<Collection<io.airlift.slice.Slice>> |
finish()
Notifies the connector that no more pages will be appended and returns
connector-specific information that will be sent to the coordinator to
complete the write operation.
|
long |
getCompletedBytes()
Gets the number of output bytes written by this page source so far.
|
long |
getSystemMemoryUsage()
Get the total memory that needs to be reserved in the general memory pool.
|
long |
getValidationCpuNanos()
ConnectorPageSink can provide optional validation to check
the data is correctly consumed by connector (e.g.
|
public ClassLoaderSafeConnectorPageSink(ConnectorPageSink delegate, ClassLoader classLoader)
public long getCompletedBytes()
ConnectorPageSinkgetCompletedBytes in interface ConnectorPageSinkpublic long getSystemMemoryUsage()
ConnectorPageSinkgetSystemMemoryUsage in interface ConnectorPageSinkpublic long getValidationCpuNanos()
ConnectorPageSinkThis method returns the CPU spent on validation, if any.
getValidationCpuNanos in interface ConnectorPageSinkpublic CompletableFuture<?> appendPage(Page page)
ConnectorPageSinkNOT_BLOCKED.appendPage in interface ConnectorPageSinkpublic CompletableFuture<Collection<io.airlift.slice.Slice>> finish()
ConnectorPageSinkConnectorPageSink.appendPage(com.facebook.presto.common.Page) (even if the returned
future is not complete).finish in interface ConnectorPageSinkpublic void abort()
abort in interface ConnectorPageSinkCopyright © 2012–2022. All rights reserved.