Java API

Synopsis

public SystemRecord storeObject(java.nio.channels.ReadableByteChannel dataChannel)

public SystemRecord

storeObject(ReadableByteChannel dataChannel,NameValueRecord record) throws ArchiveException,IOException

Description

Takes a ReadableByteChannel (and an optional NameValueRecord) and returns a

SystemRecord instance containing the system metadata for the new object.

storeMetadata

Creates a new metadata record in the name-value object archive linked to the data object identified by the OID.

Synopsis

public SystemRecord storeMetadata(ObjectIdentifier linkOID, NameValueRecord record);

throws ArchiveException, java.io.IOException

Description

Takes a NameValueRecord and OID and returns a SystemRecord instance containing the system metadata for the new metadata record.

checkIndexed

Checks if the metadata for an object is present in the query engine, and inserts the metadata if it is not present.

Synopsis

public int checkIndexed(ObjectIdentifier identifier)

throws ArchiveException, IOException

Description

checkIndexed is intended as way to resolve a store index exception under program control (see “The 5800 System Query Integrity Model” on page 21 for more information).

Once a store index exception occurs (as indicated by a SystemRecord.isIndexed value of false after a store operation) then archive.checkIndexed(oid) can be called repeatedly until it returns any non-zero value. This will ensure that the metadata for the object has been inserted into the query engine; the object should then start to show up in matching queries.

32

Sun StorageTek 5800 System Client API Reference Manual • June 2008

Page 32
Image 32
Sun Microsystems 5800 manual StoreMetadata