Zu den Hauptinhalten
  • Bestellungen schnell und einfach aufgeben
  • Bestellungen anzeigen und den Versandstatus verfolgen
  • Profitieren Sie von exklusiven Prämien und Rabatten für Mitglieder
  • Erstellen Sie eine Liste Ihrer Produkte, auf die Sie jederzeit zugreifen können.
  • Verwalten Sie mit der Unternehmensverwaltung Ihre Dell EMC Seiten, Produkte und produktspezifischen Kontakte.

PowerScale OneFS API Reference

PDF

Get the contents of a directory

Retrieves a list of files and subdirectories from a directory.

Request syntax

GET /namespace/<access_point>/<container_path>[?<query>] HTTP/1.1
Host <hostname>[:<port>]
Date: <date>
Authorization: <signature>
NOTE:

The query argument is optional and can include the parameters in the following table.

Request query parameters

Parameter Name Description Default Type Required
detail Specifies which object attributes are displayed. If the detail parameter is excluded, only the name of the object is returned. You can specify multiple attribute names in CSV format. If you set this value to default, the following attributes are included: name, size, owner, last_modified, type, group, and mode. None String No
limit Specifies the maximum number of objects to send to the client. You can set the value to a negative number to retrieve all objects. Also, you can specify the maximum number of objects to return when sorting directory entries by opening a secure shell (SSH) connection to any node in the cluster, logging in, and running the following command:
isi_gconfig -t oapi max_sort_dir_sz=<integer>
1000 Integer No
resume Specifies a token to return in the JSON result to indicate when there is a next page. The client can include the resume token to access the next page. None String No
sort Specifies one or more attributes to sort on the directory entries. You can specify multiple attributes by separating the attributes with a comma, such as name, size, last_modified. When sorting is on, the maximum number of objects returned is 1000. The entries are sorted in the order that the attributes appear in the list, from left to right. None String No
dir Specifies the sort direction. This value can be either ascending (ASC) or descending (DESC). None String No
type Specifies the object type to return, which can be one of the following values: container, object, pipe, character_device, block_device, symbolic_link, socket, or whiteout_file. None String No
hidden Specifies if hidden objects are returned. None Boolean No

Request headers

Header Name Description Default Type Required
If-Modified-Since Returns directory content only if the directory was modified since the specified time. If no directory content was modified, a 304 message is returned. None HTTP date No
If-Unmodified-Since Returns directory content only if the directory was not modified since the specified time. If there is no unmodified directory content, a 412 message is returned to indicate that the precondition failed. None HTTP date No

Response headers

Header Name Description Default Type Required
Content-Encoding Provides the content encoding that was applied to the object content, so that decoding can be applied when retrieving the content. None String No
Content-Type Provides a standard MIME-type description of the content format. application/json String No
x-isi-ifs-attr-<attr_name> Provides the extended attributes that were set in the message header. None String No
x-isi-ifs-missing-attr Provides the number of attributes that cannot be displayed in the HTTP header. None Integer No
x-isi-ifs-access-control Provides the POSIX mode in octal notation. None String No

Response body

An array of objects in the directory is output in JSON format.

Example request

The following request returns the contents of a directory named 'folder1/folder2'.

GET /namespace/folder1/folder2 HTTP/1.1
Host my_cluster:8080
Content-Length: <length>
Date: Thu, 22 Sep 2011 12:00:00 GMT
Authorization: <signature>

Example response

HTTP/1.1 200 OK
Date: Thu, 22 Sep 2011 12:00:00 GMT
Content-Type: application/JSON
Connection: close
Server: Apache2/2.2.19 

{
   "children":[
      {
         "name":"cover"
      },
      {
         "name":"f2"
      },
      {
         "name":"cover.txt"
      },
      {
         "name":"cover8"
      }
   ]
}

Request example 2

This request returns object details for the directory named 'folder1/folder2'.

GET /namespace/folder1/folder2/?limit=500&detail=default HTTP/1.1
Host my_cluster:8080
Content-Length: 0
Date: Thu, 22 Sep 2011 12:00:00 GMT
Authorization: <signature>

Response example 2

HTTP/1.1 200 OK
Date: Thu, 22 Sep 2011 12:00:00 GMT
Content-Type: application/JSON
Connection: close

{
   "resume":"<the_resume_token>",
   "children":[
      {
         "last_modified":"Fri, 18 Nov 2011 22:45:31 GMT",
         "name":"cover",
         "size":24,
         "type":"object",

      },
      {
         "last_modified":"Fri, 18 Nov 2011 20:01:04 GMT",
         "name":"f2",
         "size":4,
         "type":"object",

      },
      {
         "last_modified":"Fri, 18 Nov 2011 22:45:40 GMT",
         "name":"finance",
         "size":0,
         "type":"container",

      }
   ]
}

Diesen Inhalt bewerten

Präzise
Nützlich
Leicht verständlich
War dieser Artikel hilfreich?
0/3000 characters
  Bitte geben Sie eine Bewertung ab (1 bis 5 Sterne).
  Bitte geben Sie eine Bewertung ab (1 bis 5 Sterne).
  Bitte geben Sie eine Bewertung ab (1 bis 5 Sterne).
  Bitte geben Sie an, ob der Artikel hilfreich war.
  Die folgenden Sonderzeichen dürfen in Kommentaren nicht verwendet werden: <>()\