Class: Voltdb::BulkLoaderSuccessCallback

Inherits:
Object
  • Object
show all
Includes:
Java::OrgVoltdbClient::ClientResponse, Java::OrgVoltdbClientVoltBulkLoader::BulkLoaderSuccessCallback
Defined in:
lib/voltdb/callbacks.rb

Instance Method Summary collapse

Constructor Details

#initialize(&block) ⇒ BulkLoaderSuccessCallback

Returns a new instance of BulkLoaderSuccessCallback.



48
49
50
# File 'lib/voltdb/callbacks.rb', line 48

def initialize(&block)
  @block = block
end

Instance Method Details

#success(row_handle, client_response) ⇒ Object

Callback for successful row import. Callers are reponsible for managing their own exception reporting

Parameters:

  • row_handle

    parameter received in the insertRow()

  • client_response (Java::OrgVoltdbClient::ClientResponse)

    response generated by VoltDB indicating success

Raises:

  • exceptions from the caller method



59
60
61
62
# File 'lib/voltdb/callbacks.rb', line 59

def success(row_handle, client_response)
  client_response.extend(ClientResponseUtils)
  @block.call(row_handle, client_response)
end