Go to main content
Oracle® ZFS Storage Appliance RESTful API 설명서, 릴리스 OS8.6.x

인쇄 보기 종료

업데이트 날짜: 2016년 9월
 
 

스키마

사용자정의 스키마 등록 정보를 관리합니다.

표 93  스키마 등록 정보
요청
경로 /api/storage/v1
설명
GET
/schema
모든 NAS 스키마 등록 정보 객체를 나열합니다.
GET
/schema/<property>
지정된 NAS 스키마 등록 정보 등록 정보를 가져옵니다.
POST
/schema
새 NAS 스키마 등록 정보를 만듭니다.
PUT
/schema/<property>
지정된 NAS 스키마 등록 정보 객체를 수정합니다.
DELETE
/schema/<property>
지정된 NAS 스키마 등록 정보 객체를 삭제합니다.

사용자정의 등록 정보 이름에 접두어 "custom:"을 추가하여 프로젝트, 파일 시스템 및 LUN에서 각 사용자정의 스키마 등록 정보를 설정할 수 있습니다.

예를 들어, 다음 "PUT" 본문은 이름이 "priority"인 고객 int 등록 정보를 수정합니다.

{"custom:priority": 5}
표 94  스키마 매개변수
매개변수
설명
property
등록 정보의 이름(변경할 수 없음)
description
등록 정보 설명(브라우저 인터페이스용)
type
유형(“String”, “Integer”, “PositiveInteger”, “Boolean”, “EmailAddress”, “Host”)

등록 정보 나열

스키마 등록 정보를 나열합니다.

요청 예:

GET /api/storage/v1/schema

결과 예:

{
    "properties": [{
        "description": "bob",
        "href": "/api/storage/v1/schema/bob",
        "property": "bob",
        "type": "String"
    },{
        "description": "boo",
        "href": "/api/storage/v1/schema/boo",
        "property": "boo",
        "type": "String"
    }]
}

등록 정보 가져오기

스키마 등록 정보를 가져옵니다.

요청 예:

GET /api/storage/v1/schema/priority

결과 예:

{
    "property": {
        "description": "priority",
        "href": "/api/storage/v1/schema/priority",
        "property": "bob",
        "type": "Integer"
    }
}

등록 정보 만들기

새 스키마 등록 정보를 만듭니다.

요청 예:

POST /api/storage/v1/schema HTTP/1.1
Host: zfssa.example.com:215
Content-Type: application/json
Content-Length: 64

{"property":"priority", "type":"Integer", "description":"Oh my"}

결과 예:

HTTP/1.1 201 Created
Content-Length: 89
X-Zfssa-Nas-Api: 1.0
Content-Type: application/json
Location: /api/storage/v1/schema/priority

{
    "property": {
        "href": "/api/storage/v1/schema",
        "type": "Integer",
        "description": "Oh my"
    }
}

등록 정보 수정

스키마 등록 정보를 수정합니다.

요청 예:

PUT /api/storage/v1/schema/priority

{"description":"My custom priority level"}

결과 예:

HTTP/1.1 202 Accepted
X-Zfssa-Nas-Api: 1.0
Content-Type: application/json
Content-Length: 90

{
    "property": {
        "href": "//api/storage/v1/schema/priority",
        "type": "Integer",
        "description": "My custom priority level"
    }
}

등록 정보 삭제

스키마 등록 정보를 삭제합니다.

요청 예:

DELETE /api/storage/v1/schema/me HTTP/1.1

결과 예:

HTTP/1.1 204 No Content