Class DocumentStoreFactory
java.lang.Object
org.apache.hadoop.yarn.server.timelineservice.documentstore.lib.DocumentStoreFactory
Factory methods for instantiating a timeline Document Store reader or
writer. Based on the
DocumentStoreVendor that is configured,
appropriate reader or writer would be instantiated.-
Method Summary
Modifier and TypeMethodDescriptionstatic <Document extends TimelineDocument>
DocumentStoreReader<Document>createDocumentStoreReader(org.apache.hadoop.conf.Configuration conf) Creates a DocumentStoreReader for aDocumentStoreVendor.static <Document extends TimelineDocument>
DocumentStoreWriter<Document>createDocumentStoreWriter(org.apache.hadoop.conf.Configuration conf) Creates a DocumentStoreWriter for aDocumentStoreVendor.
-
Method Details
-
createDocumentStoreWriter
public static <Document extends TimelineDocument> DocumentStoreWriter<Document> createDocumentStoreWriter(org.apache.hadoop.conf.Configuration conf) throws org.apache.hadoop.yarn.exceptions.YarnException Creates a DocumentStoreWriter for aDocumentStoreVendor.- Type Parameters:
Document- type of Document for which the writer has to be created, i.e TimelineEntityDocument, FlowActivityDocument etc- Parameters:
conf- for creating client connection- Returns:
- document store writer
- Throws:
DocumentStoreNotSupportedException- if there is no implementation for a configuredDocumentStoreVendoror unknownDocumentStoreVendoris configured.org.apache.hadoop.yarn.exceptions.YarnException- if the required configs for DocumentStore is missing.
-
createDocumentStoreReader
public static <Document extends TimelineDocument> DocumentStoreReader<Document> createDocumentStoreReader(org.apache.hadoop.conf.Configuration conf) throws org.apache.hadoop.yarn.exceptions.YarnException Creates a DocumentStoreReader for aDocumentStoreVendor.- Type Parameters:
Document- type of Document for which the writer has to be created, i.e TimelineEntityDocument, FlowActivityDocument etc- Parameters:
conf- for creating client connection- Returns:
- document store reader
- Throws:
DocumentStoreNotSupportedException- if there is no implementation for a configuredDocumentStoreVendoror unknownDocumentStoreVendoris configured.org.apache.hadoop.yarn.exceptions.YarnException- if the required configs for DocumentStore is missing.
-