Http syntax – HP StoreAll Storage User Manual

Page 172

Advertising
background image

HTTP syntax

The commands provided in this section should be entered on one line.

The HTTP request line format is the following on one line:

PUT

/<urlpath>/<pathname>?assign=[system::retentionExpirationTime=<retentionExpirationTime>]

[,system::worm='true'] HTTP/1.1

The equivalent curl command format is the following on one line:

curl -g -X PUT

"http[s]://<IP_address>:<port>/<urlpath>/<pathname>?assign=

nl

[system::retentionExpirationTime= <retentionExpirationTime>]

[,system::worm='true']"

Either or both system::retentionExpirationTime or system::worm can be specified.

Description

Parameter

The name of an existing file on the HTTP share. The retention properties of
this file will be changed.

pathname

If present, defines the date/time at which the file should expire from the
retained state. After that time, the file will still be WORM (immutable) forever,

system:retentionExpirationTime

but the file can be deleted. The date/time must be formatted according to

“API date formats” (page 155)

.

If the file is not currently in the retained state, the date/time is stored as the
file’s atime, but retention rules are only applied to the file if
system::worm=true

in this command or a later command.

If the file is already retained, the date/time is changed to
system::retentionExpirationTime

, unless

system::retentionExpirationTime

is earlier than the file’s existing

retention expiration date/time and the file system’s retention mode is set to
enterprise

. In this case, an error is returned and the date/time is not

changed. The retention period can be shortened only in relaxed mode, not
in enterprise mode.

If not present, and system::worm is present, the default retention period
is applied to the file, if a default is defined for this file system. If no default
is applied, then the file becomes WORM (immutable) but not retained (so it
can still be deleted).

This attribute sets the state of the file to WORM. If present, the value must be
the literal string true; no other value is accepted. At the same time, if the

system::worm

atime (retention expiration date/time) is in the future, or if the file system’s
default retention period is nonzero, it sets the retention expiration date/time
either to the atime (if it is in the future) or the default retention period.

A file’s state can be changed to WORM only once. A file in WORM or
retained state cannot be reverted to non-WORM, and cannot be un-retained
through the StoreAll REST API. See the ibrix_reten_adm command or
the equivalent Management Console actions for administrative override
methods to un-retain a file.

Example: Set a file to WORM without specifying retention expiration

curl -g -X PUT

"https://99.226.50.92/ibrix_share1/lab/images/xyz.jpg?assign=system::worm='true'"

In this example, no retention expiration date/time is provided, but the file state is changed to
WORM.

172

HTTP-REST API file-compatible mode shares

Advertising