Documentation ¶
Overview ¶
Package datamovement provides way to read and write in bulk
Index ¶
- type QueryBatch
- type QueryBatcher
- func (qbr *QueryBatcher) BatchSize() uint16
- func (qbr *QueryBatcher) RemoveListener(listener chan *QueryBatch) *QueryBatcher
- func (qbr *QueryBatcher) Run() *QueryBatcher
- func (qbr *QueryBatcher) Timestamp() string
- func (qbr *QueryBatcher) Wait() *QueryBatcher
- func (qbr *QueryBatcher) WithBatchSize(batchSize uint16) *QueryBatcher
- func (qbr *QueryBatcher) WithListener(listener chan *QueryBatch) *QueryBatcher
- func (qbr *QueryBatcher) WithQuery(query handle.Handle) *QueryBatcher
- func (qbr *QueryBatcher) WithTransaction(transaction *util.Transaction) *QueryBatcher
- type Service
- type WriteBatch
- func (wb *WriteBatch) Client() *clients.Client
- func (wb *WriteBatch) DocumentDescriptions() []*documents.DocumentDescription
- func (wb *WriteBatch) DocumentsService() *documents.Service
- func (wb *WriteBatch) Response() handle.ResponseHandle
- func (wb *WriteBatch) Timestamp() string
- func (wb *WriteBatch) WithResponse(response handle.ResponseHandle) *WriteBatch
- type WriteBatcher
- func (wbr *WriteBatcher) BatchSize() uint16
- func (wbr *WriteBatcher) RemoveListener(listener chan<- *WriteBatch) *WriteBatcher
- func (wbr *WriteBatcher) Run() *WriteBatcher
- func (wbr *WriteBatcher) ThreadCount() uint8
- func (wbr *WriteBatcher) Timestamp() string
- func (wbr *WriteBatcher) Wait() *WriteBatcher
- func (wbr *WriteBatcher) WithBatchSize(batchSize uint16) *WriteBatcher
- func (wbr *WriteBatcher) WithListener(listener chan<- *WriteBatch) *WriteBatcher
- func (wbr *WriteBatcher) WithThreadCount(threadCount uint8) *WriteBatcher
- func (wbr *WriteBatcher) WithTransaction(transaction *util.Transaction) *WriteBatcher
- func (wbr *WriteBatcher) WithTransform(transform *util.Transform) *WriteBatcher
- func (wbr *WriteBatcher) WithWriteChannel(writeChannel <-chan *documents.DocumentDescription) *WriteBatcher
- func (wbr *WriteBatcher) WriteChannel() <-chan *documents.DocumentDescription
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type QueryBatch ¶
type QueryBatch struct { URIs []string // contains filtered or unexported fields }
QueryBatch batch of URIs matching a query and relevant meta information
func (*QueryBatch) Client ¶
func (qb *QueryBatch) Client() *clients.Client
Client used to with forest for the documents
type QueryBatcher ¶
type QueryBatcher struct {
// contains filtered or unexported fields
}
QueryBatcher reads documents in bulk
func (*QueryBatcher) BatchSize ¶
func (qbr *QueryBatcher) BatchSize() uint16
BatchSize is the number documents we'll retrieve in a single batch
func (*QueryBatcher) RemoveListener ¶
func (qbr *QueryBatcher) RemoveListener(listener chan *QueryBatch) *QueryBatcher
RemoveListener remove the a listener
func (*QueryBatcher) Timestamp ¶
func (qbr *QueryBatcher) Timestamp() string
Timestamp for the read operation
func (*QueryBatcher) Wait ¶
func (qbr *QueryBatcher) Wait() *QueryBatcher
Wait on the QueryBatcher to finish
func (*QueryBatcher) WithBatchSize ¶
func (qbr *QueryBatcher) WithBatchSize(batchSize uint16) *QueryBatcher
WithBatchSize set the batch size
func (*QueryBatcher) WithListener ¶
func (qbr *QueryBatcher) WithListener(listener chan *QueryBatch) *QueryBatcher
WithListener add a listener channel
func (*QueryBatcher) WithQuery ¶
func (qbr *QueryBatcher) WithQuery(query handle.Handle) *QueryBatcher
WithQuery add a query
func (*QueryBatcher) WithTransaction ¶
func (qbr *QueryBatcher) WithTransaction(transaction *util.Transaction) *QueryBatcher
WithTransaction add a transaction
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service is used for the datamovement service
func NewService ¶
NewService returns a new datamovement.Service
func (*Service) QueryBatcher ¶
func (s *Service) QueryBatcher() *QueryBatcher
QueryBatcher for reading documents in bulk
func (*Service) WriteBatcher ¶
func (s *Service) WriteBatcher() *WriteBatcher
WriteBatcher for writing documents in bulk
type WriteBatch ¶
type WriteBatch struct {
// contains filtered or unexported fields
}
WriteBatch batch of DocumentDescriptions to write to MarkLogic and relevant meta information
func (*WriteBatch) Client ¶
func (wb *WriteBatch) Client() *clients.Client
Client used to write the documents
func (*WriteBatch) DocumentDescriptions ¶
func (wb *WriteBatch) DocumentDescriptions() []*documents.DocumentDescription
DocumentDescriptions representations of the documents written
func (*WriteBatch) DocumentsService ¶
func (wb *WriteBatch) DocumentsService() *documents.Service
DocumentsService used to write the documents
func (*WriteBatch) Response ¶
func (wb *WriteBatch) Response() handle.ResponseHandle
Response return the write batch response
func (*WriteBatch) Timestamp ¶
func (wb *WriteBatch) Timestamp() string
Timestamp for the write operation
func (*WriteBatch) WithResponse ¶
func (wb *WriteBatch) WithResponse(response handle.ResponseHandle) *WriteBatch
WithResponse set write batch response
type WriteBatcher ¶
type WriteBatcher struct {
// contains filtered or unexported fields
}
WriteBatcher writes documents in bulk
func (*WriteBatcher) BatchSize ¶
func (wbr *WriteBatcher) BatchSize() uint16
BatchSize is the number documents we'll create in a single batch
func (*WriteBatcher) RemoveListener ¶
func (wbr *WriteBatcher) RemoveListener(listener chan<- *WriteBatch) *WriteBatcher
RemoveListener remove the a listener
func (*WriteBatcher) ThreadCount ¶
func (wbr *WriteBatcher) ThreadCount() uint8
ThreadCount is the number threads we'll create
func (*WriteBatcher) Timestamp ¶
func (wbr *WriteBatcher) Timestamp() string
Timestamp for the write operation
func (*WriteBatcher) Wait ¶
func (wbr *WriteBatcher) Wait() *WriteBatcher
Wait on the WriteBatcher to finish
func (*WriteBatcher) WithBatchSize ¶
func (wbr *WriteBatcher) WithBatchSize(batchSize uint16) *WriteBatcher
WithBatchSize set the batch size
func (*WriteBatcher) WithListener ¶
func (wbr *WriteBatcher) WithListener(listener chan<- *WriteBatch) *WriteBatcher
WithListener add a listener channel
func (*WriteBatcher) WithThreadCount ¶
func (wbr *WriteBatcher) WithThreadCount(threadCount uint8) *WriteBatcher
WithThreadCount set the thread count
func (*WriteBatcher) WithTransaction ¶
func (wbr *WriteBatcher) WithTransaction(transaction *util.Transaction) *WriteBatcher
WithTransaction perform writes in given transaction
func (*WriteBatcher) WithTransform ¶
func (wbr *WriteBatcher) WithTransform(transform *util.Transform) *WriteBatcher
WithTransform transform to apply to the documents
func (*WriteBatcher) WithWriteChannel ¶
func (wbr *WriteBatcher) WithWriteChannel(writeChannel <-chan *documents.DocumentDescription) *WriteBatcher
WithWriteChannel add a channel od documents to write
func (*WriteBatcher) WriteChannel ¶
func (wbr *WriteBatcher) WriteChannel() <-chan *documents.DocumentDescription
WriteChannel is the channel that documents to write will be pulled from