@Component public class D1MemberNode extends Object
| Constructor and Description |
|---|
D1MemberNode() |
| Modifier and Type | Method and Description |
|---|---|
org.dataone.service.types.v1.Node |
doPing() |
org.dataone.service.types.v1.Node |
doRootPing() |
org.dataone.service.types.v1.Node |
doRootV1Ping() |
org.dataone.service.types.v1.Node |
getCapabilities() |
org.dataone.service.types.v1.Checksum |
getChecksum(javax.servlet.http.HttpServletRequest request,
String pid,
String checksumAlgorithm)
Represents the value of a computed :term:`checksum`
expressed as a hexadecimal formatted version of the message digest.
|
javax.ws.rs.core.Response |
getDescribeObject(javax.servlet.http.HttpServletRequest request,
String pid)
This method provides a lighter weight mechanism than MNRead.getSystemMetadata() for a client to determine basic
properties of the referenced object.
|
org.dataone.service.types.v1.Log |
getLogRecords(String fromDate,
String toDate,
String event,
String pidFilter,
Integer start,
Integer count)
Represents a collection of :class:`Types.LogEntry`
elements, used to transfer log information between DataONE
components.
|
javax.ws.rs.core.Response |
getObject(javax.servlet.http.HttpServletRequest request,
String pid)
Lookup DSpaceObject and Return in specific format.
|
org.dataone.service.types.v1_1.QueryEngineDescription |
getQueryEngineDescription(String queryEngine) |
javax.ws.rs.core.Response |
getReplica(javax.servlet.http.HttpServletRequest request,
String pid)
Called by a target Member Node to fullfill the replication request originated by a Coordinating Node calling
MNReplication.replicate().
|
org.dataone.service.types.v1.SystemMetadata |
getSystemMetadata(javax.servlet.http.HttpServletRequest request,
String pid)
Describes the object identified by id by returning the associated system metadata object.
|
boolean |
isAuthorized(String pid,
String action) |
org.dataone.service.types.v1.ObjectList |
listObjects(String identifier,
String fromDate,
String toDate,
String formatId,
Boolean replicaStatus,
Integer start,
Integer count)
Retrieve the list of objects present on the MN that match the calling parameters.
|
org.dataone.service.types.v1_1.QueryEngineList |
listQueryEngines() |
InputStream |
query(String queryEngine,
String query)
Submit a query against the specified queryEngine and return the response as formatted by the queryEngine.
|
void |
setNode(org.dataone.service.types.v1.Node node) |
javax.ws.rs.core.Response |
synchronizationFailed(javax.servlet.http.HttpServletRequest request,
InputStream message)
This is a callback method used by a CN to indicate to a MN that it cannot complete synchronization of the
science metadata identified by pid.
|
@Autowired public void setNode(org.dataone.service.types.v1.Node node)
public org.dataone.service.types.v1.Node doRootV1Ping()
throws org.dataone.service.exceptions.NotImplemented,
org.dataone.service.exceptions.ServiceFailure,
org.dataone.service.exceptions.InsufficientResources
org.dataone.service.exceptions.NotImplementedorg.dataone.service.exceptions.ServiceFailureorg.dataone.service.exceptions.InsufficientResourcespublic org.dataone.service.types.v1.Node doRootPing()
throws org.dataone.service.exceptions.NotImplemented,
org.dataone.service.exceptions.ServiceFailure,
org.dataone.service.exceptions.InsufficientResources
org.dataone.service.exceptions.NotImplementedorg.dataone.service.exceptions.ServiceFailureorg.dataone.service.exceptions.InsufficientResourcespublic org.dataone.service.types.v1.Node doPing()
throws org.dataone.service.exceptions.NotImplemented,
org.dataone.service.exceptions.ServiceFailure,
org.dataone.service.exceptions.InsufficientResources
org.dataone.service.exceptions.NotImplementedorg.dataone.service.exceptions.ServiceFailureorg.dataone.service.exceptions.InsufficientResourcespublic org.dataone.service.types.v1.Node getCapabilities()
throws org.dataone.service.exceptions.NotImplemented,
org.dataone.service.exceptions.ServiceFailure
org.dataone.service.exceptions.NotImplementedorg.dataone.service.exceptions.ServiceFailurepublic org.dataone.service.types.v1.Log getLogRecords(String fromDate, String toDate, String event, String pidFilter, Integer start, Integer count) throws org.dataone.service.exceptions.InvalidRequest, org.dataone.service.exceptions.InvalidToken, org.dataone.service.exceptions.NotAuthorized, org.dataone.service.exceptions.NotImplemented, org.dataone.service.exceptions.ServiceFailure
<xs:complexType xmlns:ns="http://ns.dataone.org/service/types/v1" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="Log">
<xs:complexContent>
<xs:extension base="ns:Slice">
<xs:sequence>
<xs:element type="ns:LogEntry" name="logEntry" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:extension>
</xs:complexContent>
</xs:complexType>
A single log entry as reported by a Member Node or
Coordinating Node through the :func:`MNCore.getLogRecords` or :func:`CNCore.getLogRecords` methods.
Schema fragment(s) for this class:
<xs:complexType xmlns:ns="http://ns.dataone.org/service/types/v1" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="LogEntry">
<xs:sequence>
<xs:element type="xs:string" name="entryId" minOccurs="1" maxOccurs="1"/>
<xs:element type="ns:Identifier" name="identifier" minOccurs="1" maxOccurs="1"/>
<xs:element type="xs:string" name="ipAddress" minOccurs="1" maxOccurs="1"/>
<xs:element type="xs:string" name="userAgent" minOccurs="1" maxOccurs="1"/>
<xs:element type="ns:Subject" name="subject" minOccurs="1" maxOccurs="1"/>
<xs:element type="ns:Event" name="event" minOccurs="1" maxOccurs="1"/>
<xs:element type="xs:dateTime" name="dateLogged" minOccurs="1" maxOccurs="1"/>
<xs:element type="ns:NodeReference" name="nodeIdentifier" minOccurs="1" maxOccurs="1"/>
</xs:sequence>
</xs:complexType>
Example Response:
fromDate - fromDate (Types.DateTime) – Records with time stamp greater than or equal to (>=) this value
will be returned. Transmitted as a URL query parameter, and so must be escaped accordingly.toDate - toDate (Types.DateTime) – Records with a time stamp less than (<) this value will be returned.
If not specified, then defaults to now. Transmitted as a URL query parameter, and so must be
escaped accordingly.event - event (Types.Event) – Return only log records for the specified type of event. Default is all.
Transmitted as a URL query parameter, and so must be escaped accordingly.pidFilter - pidFilter (string) – Return only log records for identifiers that start with the supplied
identifier string. Support for this parameter is optional and MAY be ignored by the Member
Node implementation with no warning. Accepts PIDs and SIDs Transmitted as a URL query parameter,
and so must be escaped accordingly.start - start=0 (integer) – Optional zero based offset from the first record in the set of matching log
records. Used to assist with paging the response. Transmitted as a URL query parameter, and so
must be escaped accordingly.count - count=1000 (integer) – The maximum number of log records that should be returned in the response.
The Member Node may return fewer and the caller should check the total in the response to determine
if further pages may be retrieved. Transmitted as a URL query parameter, and so must be escaped
accordingly.org.dataone.service.exceptions.InvalidRequest - (errorCode=400, detailCode=1480) The request parameters were malformed or an invalid date range was specified.org.dataone.service.exceptions.InvalidToken - (errorCode=401, detailCode=1470)org.dataone.service.exceptions.NotAuthorized - (errorCode=401, detailCode=1460) Raised if the user making the request is not authorized to access the log records. This is determined by the policy of the Member Node.org.dataone.service.exceptions.NotImplemented - (errorCode=501, detailCode=1461)org.dataone.service.exceptions.ServiceFailure - (errorCode=500, detailCode=1490)public javax.ws.rs.core.Response getObject(@Context
javax.servlet.http.HttpServletRequest request,
String pid)
throws org.dataone.service.exceptions.InvalidToken,
org.dataone.service.exceptions.NotAuthorized,
org.dataone.service.exceptions.NotImplemented,
org.dataone.service.exceptions.ServiceFailure,
org.dataone.service.exceptions.NotFound,
org.dataone.service.exceptions.InsufficientResources
pid - persistent identifier, must be resolve able in IdentifierService. (Types.Identifier) – The identifier
for the object to be retrieved. May be a PID or a SID. Transmitted as part of the URL path and must
be escaped accordingly.org.dataone.service.exceptions.InvalidToken - (errorCode=401, detailCode=1010)org.dataone.service.exceptions.NotAuthorized - (errorCode=401, detailCode=1000)org.dataone.service.exceptions.NotImplemented - (errorCode=501, detailCode=1001)org.dataone.service.exceptions.ServiceFailure - (errorCode=500, detailCode=1030)org.dataone.service.exceptions.NotFound - (errorCode=404, detailCode=1020) The object specified by id does not exist at this node.
The description should include a reference to the resolve method.org.dataone.service.exceptions.InsufficientResources - (errorCode=413, detailCode=1002) The node is unable to service the request
due to insufficient resources such as CPU, memory, or bandwidth being over utilized.public org.dataone.service.types.v1.SystemMetadata getSystemMetadata(@Context
javax.servlet.http.HttpServletRequest request,
String pid)
throws org.dataone.service.exceptions.InvalidToken,
org.dataone.service.exceptions.NotAuthorized,
org.dataone.service.exceptions.NotImplemented,
org.dataone.service.exceptions.ServiceFailure,
org.dataone.service.exceptions.NotFound
<xs:complexType xmlns:ns="http://ns.dataone.org/service/types/v1" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="SystemMetadata">
<xs:sequence>
<xs:element type="xs:long" name="serialVersion" minOccurs="0" maxOccurs="1"/>
<xs:element type="ns:Identifier" name="identifier"/>
<xs:element type="ns:ObjectFormatIdentifier" name="formatId"/>
<xs:element type="xs:long" name="size"/>
<xs:element type="ns:Checksum" name="checksum"/>
<xs:element type="ns:Subject" name="submitter" minOccurs="0" maxOccurs="1"/>
<xs:element type="ns:Subject" name="rightsHolder"/>
<xs:element type="ns:AccessPolicy" name="accessPolicy" minOccurs="0" maxOccurs="1"/>
<xs:element type="ns:ReplicationPolicy" name="replicationPolicy" minOccurs="0" maxOccurs="1"/>
<xs:element type="ns:Identifier" name="obsoletes" minOccurs="0" maxOccurs="1"/>
<xs:element type="ns:Identifier" name="obsoletedBy" minOccurs="0" maxOccurs="1"/>
<xs:element type="xs:boolean" name="archived" minOccurs="0" maxOccurs="1"/>
<xs:element type="xs:dateTime" name="dateUploaded" minOccurs="0" maxOccurs="1"/>
<xs:element type="xs:dateTime" name="dateSysMetadataModified" minOccurs="0" maxOccurs="1"/>
<xs:element type="ns:NodeReference" name="originMemberNode" minOccurs="0" maxOccurs="1"/>
<xs:element type="ns:NodeReference" name="authoritativeMemberNode" minOccurs="0" maxOccurs="1"/>
<xs:element type="ns:Replica" name="replica" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
pid - (Types.Identifier) – Identifier for the science data or science metedata object of interest.
May be either a PID or a SID. Transmitted as part of the URL path and must be escaped accordingly.org.dataone.service.exceptions.InvalidToken - (errorCode=401, detailCode=1050)org.dataone.service.exceptions.NotAuthorized - (errorCode=401, detailCode=1040)org.dataone.service.exceptions.NotImplemented - (errorCode=501, detailCode=1041)org.dataone.service.exceptions.ServiceFailure - (errorCode=500, detailCode=1090)org.dataone.service.exceptions.NotFound - (errorCode=404, detailCode=1060) There is no data or science metadata identified by the given
pid on the node where the request was serviced. The error message should provide a hint to use the
CNRead.resolve() mechanism.public javax.ws.rs.core.Response getDescribeObject(@Context
javax.servlet.http.HttpServletRequest request,
String pid)
throws org.dataone.service.exceptions.InvalidRequest,
org.dataone.service.exceptions.InvalidToken,
org.dataone.service.exceptions.NotAuthorized,
org.dataone.service.exceptions.NotImplemented,
org.dataone.service.exceptions.ServiceFailure,
org.dataone.service.exceptions.NotFound
request - pid - (Types.Identifier) – Identifier for the object in question. May be either a PID or a SID.
Transmitted as part of the URL path and must be escaped accordingly.org.dataone.service.exceptions.InvalidRequestorg.dataone.service.exceptions.InvalidToken - (errorCode=401, detailCode=1370)org.dataone.service.exceptions.NotAuthorized - (errorCode=401, detailCode=1360)org.dataone.service.exceptions.NotImplemented - (errorCode=501, detailCode=1361)org.dataone.service.exceptions.ServiceFailure - (errorCode=500, detailCode=1390)org.dataone.service.exceptions.NotFound - (errorCode=404, detailCode=1380)public org.dataone.service.types.v1.Checksum getChecksum(@Context
javax.servlet.http.HttpServletRequest request,
String pid,
String checksumAlgorithm)
throws org.dataone.service.exceptions.InvalidRequest,
org.dataone.service.exceptions.InvalidToken,
org.dataone.service.exceptions.NotAuthorized,
org.dataone.service.exceptions.NotImplemented,
org.dataone.service.exceptions.ServiceFailure,
org.dataone.service.exceptions.NotFound
<xs:complexType xmlns:ns="http://ns.dataone.org/service/types/v1" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="Checksum">
<xs:simpleContent>
<xs:extension base="xs:string">
<xs:attribute type="xs:string" use="required" name="algorithm"/>
</xs:extension>
</xs:simpleContent>
</xs:complexType>
pid - (Types.Identifier) – The identifier of the object the operation is being performed on. Transmitted as
part of the URL path and must be escaped accordingly.checksumAlgorithm - (string) – The name of an algorithm that will be used to compute a checksum of the
bytes of the object. This value is drawn from a DataONE controlled list of values as
indicted in the Types.SystemMetadata. If not specified, then the system wide default
checksum algorithm should be used. Transmitted as a URL query parameter, and so must
be escaped accordingly.org.dataone.service.exceptions.InvalidRequest - (errorCode=400, detailCode=1402) A supplied parameter was invalid, most likely an
unsupported checksum algorithm was specified, in which case the error message should include an enumeration
of supported checksum algorithms.org.dataone.service.exceptions.InvalidToken - (errorCode=401, detailCode=1430)org.dataone.service.exceptions.NotAuthorized - (errorCode=401, detailCode=1400)org.dataone.service.exceptions.NotImplemented - (errorCode=501, detailCode=1401)org.dataone.service.exceptions.ServiceFailure - (errorCode=500, detailCode=1410)org.dataone.service.exceptions.NotFound - (errorCode=404, detailCode=1420)public org.dataone.service.types.v1.ObjectList listObjects(String identifier, String fromDate, String toDate, String formatId, Boolean replicaStatus, Integer start, Integer count) throws org.dataone.service.exceptions.InvalidRequest, org.dataone.service.exceptions.InvalidToken, org.dataone.service.exceptions.NotAuthorized, org.dataone.service.exceptions.NotImplemented, org.dataone.service.exceptions.ServiceFailure
<xs:complexType xmlns:ns="http://ns.dataone.org/service/types/v1" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="ObjectInfo">
<xs:sequence>
<xs:element type="ns:Identifier" name="identifier" minOccurs="1" maxOccurs="1"/>
<xs:element type="ns:ObjectFormatIdentifier" name="formatId"/>
<xs:element type="ns:Checksum" name="checksum" minOccurs="1" maxOccurs="1"/>
<xs:element type="xs:dateTime" name="dateSysMetadataModified"/>
<xs:element type="xs:long" name="size"/>
</xs:sequence>
</xs:complexType>
identifier - (Types.Identifier) – Restrict results to the specified identifier. May be a PID or a SID.
In the case of the latter, returns a listing of all PIDs that share the given SID.
Transmitted as a URL query parameter, and so must be escaped accordingly.fromDate - (Types.DateTime) – Entries with SystemMetadata.dateSysMetadataModified greater than (>) fromDate
must be returned. Transmitted as a URL query parameter, and so must be escaped accordingly.toDate - (Types.DateTime) – Entries with SystemMetadata.dateSysMetadataModified less than (<) toDate must
be returned. Transmitted as a URL query parameter, and so must be escaped accordingly.formatId - (Types.ObjectFormatIdentifier) – Restrict results to the specified object format identifier.
Transmitted as a URL query parameter, and so must be escaped accordingly.replicaStatus - TBDstart - start=0 (integer) – The zero-based index of the first value, relative to the first record of the
resultset that matches the parameters. Transmitted as a URL query parameter, and so must be escaped
accordingly.count - count=1000 (integer) – The maximum number of entries that should be returned in the response.
The Member Node may return fewer and the caller should check the total in the response to determine
if further pages may be retrieved. Transmitted as a URL query parameter, and so must be escaped
accordingly.org.dataone.service.exceptions.InvalidRequest - (errorCode=400, detailCode=1540)org.dataone.service.exceptions.InvalidToken - (errorCode=401, detailCode=1530)org.dataone.service.exceptions.NotAuthorized - (errorCode=401, detailCode=1520)org.dataone.service.exceptions.NotImplemented - (errorCode=501, detailCode=1560) Raised if some functionality requested is not implemented.
In the case of an optional request parameter not being supported, the errorCode should be 400. If the requested
format (through HTTP Accept headers) is not supported, then the standard HTTP 406 error code should be returned.org.dataone.service.exceptions.ServiceFailure - (errorCode=500, detailCode=1580)public javax.ws.rs.core.Response synchronizationFailed(@Context
javax.servlet.http.HttpServletRequest request,
InputStream message)
throws org.dataone.service.exceptions.InvalidToken,
org.dataone.service.exceptions.NotAuthorized,
org.dataone.service.exceptions.NotImplemented,
org.dataone.service.exceptions.ServiceFailure
message - message (Types.Exception) – An instance of the Exceptions.SynchronizationFailed exception
with body appropriately filled. Transmitted as an UTF-8 encoded XML structure for the
respective type as defined in the DataONE types schema, as a File part of the MIME
multipart/mixed message.org.dataone.service.exceptions.InvalidToken - (errorCode=401, detailCode=2164)org.dataone.service.exceptions.NotAuthorized - (errorCode=401, detailCode=2162)org.dataone.service.exceptions.NotImplemented - (errorCode=501, detailCode=2160)org.dataone.service.exceptions.ServiceFailure - (errorCode=500, detailCode=2161)public javax.ws.rs.core.Response getReplica(@Context
javax.servlet.http.HttpServletRequest request,
String pid)
throws org.dataone.service.exceptions.InvalidToken,
org.dataone.service.exceptions.NotAuthorized,
org.dataone.service.exceptions.NotImplemented,
org.dataone.service.exceptions.ServiceFailure,
org.dataone.service.exceptions.NotFound,
org.dataone.service.exceptions.InsufficientResources
pid - pid (Types.Identifier) – The identifier of the object to get as a replica Transmitted as part
of the URL path and must be escaped accordingly.org.dataone.service.exceptions.InvalidToken - (errorCode=401, detailCode=2183)org.dataone.service.exceptions.NotAuthorized - (errorCode=401, detailCode=2182)org.dataone.service.exceptions.NotImplemented - (errorCode=501, detailCode=2180)org.dataone.service.exceptions.ServiceFailure - (errorCode=500, detailCode=2181)org.dataone.service.exceptions.NotFound - (errorCode=404, detailCode=2185)org.dataone.service.exceptions.InsufficientResources - (errorCode=413, detailCode=2184) The node is unable to service the request due
to insufficient resources such as CPU, memory, or bandwidth being over utilized.public InputStream query(String queryEngine, String query) throws org.dataone.service.exceptions.InvalidToken, org.dataone.service.exceptions.ServiceFailure, org.dataone.service.exceptions.NotAuthorized, org.dataone.service.exceptions.InvalidRequest, org.dataone.service.exceptions.NotImplemented, org.dataone.service.exceptions.NotFound
queryEngine - specify the engine will be used for this queryquery - query string.org.dataone.service.exceptions.InvalidRequestorg.dataone.service.exceptions.InvalidTokenorg.dataone.service.exceptions.NotAuthorizedorg.dataone.service.exceptions.NotImplementedorg.dataone.service.exceptions.ServiceFailureorg.dataone.service.exceptions.NotFoundpublic org.dataone.service.types.v1_1.QueryEngineDescription getQueryEngineDescription(String queryEngine) throws org.dataone.service.exceptions.InvalidToken, org.dataone.service.exceptions.ServiceFailure, org.dataone.service.exceptions.NotAuthorized, org.dataone.service.exceptions.NotImplemented, org.dataone.service.exceptions.NotFound
org.dataone.service.exceptions.InvalidTokenorg.dataone.service.exceptions.ServiceFailureorg.dataone.service.exceptions.NotAuthorizedorg.dataone.service.exceptions.NotImplementedorg.dataone.service.exceptions.NotFoundpublic org.dataone.service.types.v1_1.QueryEngineList listQueryEngines()
throws org.dataone.service.exceptions.InvalidToken,
org.dataone.service.exceptions.ServiceFailure,
org.dataone.service.exceptions.NotAuthorized,
org.dataone.service.exceptions.NotImplemented
org.dataone.service.exceptions.InvalidTokenorg.dataone.service.exceptions.ServiceFailureorg.dataone.service.exceptions.NotAuthorizedorg.dataone.service.exceptions.NotImplementedpublic boolean isAuthorized(String pid, String action) throws org.dataone.service.exceptions.ServiceFailure, org.dataone.service.exceptions.InvalidRequest, org.dataone.service.exceptions.InvalidToken, org.dataone.service.exceptions.NotFound, org.dataone.service.exceptions.NotAuthorized, org.dataone.service.exceptions.NotImplemented
org.dataone.service.exceptions.ServiceFailureorg.dataone.service.exceptions.InvalidRequestorg.dataone.service.exceptions.InvalidTokenorg.dataone.service.exceptions.NotFoundorg.dataone.service.exceptions.NotAuthorizedorg.dataone.service.exceptions.NotImplementedCopyright © 2016 DuraSpace. All rights reserved.