Interface RFile.WriterOptions
- All Known Subinterfaces:
RFile.WriterFSOptions
- Enclosing class:
- RFile
public static interface RFile.WriterOptions
This is an intermediate interface in a larger builder pattern. Supports setting optional
parameters for creating a RFile and building a RFileWriter.
- Since:
- 1.8.0
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
withSampler
(SamplerConfiguration samplerConf) An option to store sample data in the generated RFile.default RFile.WriterOptions
withSummarizers
(SummarizerConfiguration... summarizerConf) Enable generating summary data in the created RFile by runningSummarizer
's based on the specified configuration.withTableProperties
(Iterable<Map.Entry<String, String>> props) Create an RFile using the same configuration as an Accumulo table.withTableProperties
(Map<String, String> props) withVisibilityCacheSize
(int maxSize)
-
Method Details
-
withSummarizers
Enable generating summary data in the created RFile by runningSummarizer
's based on the specified configuration.- Parameters:
summarizerConf
- Configuration for summarizer to run.- Since:
- 2.0.0
-
withSampler
An option to store sample data in the generated RFile.- Parameters:
samplerConf
- configuration to use when generating sample data.- Returns:
- this
- Throws:
IllegalArgumentException
- if table properties were previously specified and the table properties also specify a sampler.
-
withTableProperties
Create an RFile using the same configuration as an Accumulo table. Properties for a table can be obtained by callingTableOperations.getProperties(String)
. Any property that impacts file behavior regardless of whether it has theProperty.TABLE_PREFIX
may be accepted and used. For example, cache and crypto properties could be passed here.- Parameters:
props
- iterable over Accumulo table key value properties.- Returns:
- this
- Throws:
IllegalArgumentException
- if sampler was previously specified and the table properties also specify a sampler.
-
withTableProperties
- See Also:
-
withVisibilityCacheSize
- Parameters:
maxSize
- As keys are added to an RFile the visibility field is validated. Validating the visibility field requires parsing it. In order to make validation faster, previously seen visibilities are cached. This option allows setting the maximum size of this cache.- Returns:
- this
-
build
- Returns:
- a new RfileWriter created with the options previously specified.
- Throws:
IOException
-