Declarative Native App 매니페스트 참조¶
공급자는 :doc:`패키지<package>`의 일부로 매니페스트 파일을 생성합니다.
매니페스트 파일은 텍스트 기반 `YAML<https://yaml.org/spec/>`_파일이며, 파일 이름은 ``manifest.yml``입니다. 노트북, 테이블, 뷰 등 컨슈머와 데이터를 선언적으로 공유하는 데 사용됩니다.
매니페스트 파일은 앱 소유자가 앱의 데이터와 기능의 하위 집합을 역할별로 조직 팀의 팀과 공유하는 데 사용할 수 있는 :doc:`앱 역할<app-roles>`도 정의합니다.
애플리케이션 패키지 개발에 대한 자세한 내용은 네이티브 애플리케이션 프레임워크의 선언적 공유에서 사용되는 애플리케이션 패키지 섹션을 참조하세요.
Declarative Native App 메니페스트¶
|declarative-app-short|의 일반 형식 매니페스트에는 다음이 포함됩니다.
manifest_version: # Added automatically. Don't include.
application_content: # Optional, describes associated app logic
roles: # Optional, describes roles associated with shared_content
shared_content: # Required, describes associated data to be shared
필드¶
Declarative Native App 매니페스트에는 다음 필드가 포함됩니다.
manifest_version 필드¶
이 필드는 애플리케이션 패키지의 새 버전을 릴리스할 때 매니페스트 파일에 자동으로 추가됩니다.
애플리케이션 패키지에 포함할 매니페스트 파일을 생성할 때 이 필드를 포함하지 마세요. 이 필드는 수동으로 편집할 수 없습니다.
manifest_version 최상위 필드(정수, 필수)는 매니페스트 파일의 버전 번호를 지정합니다.
버전 관리에 대한 자세한 내용은 네이티브 애플리케이션 프레임워크에서 선언적 공유의 패키지 버전 섹션을 참조하세요.
application_content 필드¶
``application_content``필드(목록, 선택 사항)는 앱에서 선언적으로 공유하는 번들 콘텐츠를 정의합니다.
이 필드에는 단일 notebooks 필드가 포함되어 있습니다.
``application_content.notebooks``(목록, 필수): 명명된 :doc:`노트북</user-guide/ui-snowsight/notebooks>`의 목록입니다.
application_content.notebooks.{named notebook} 필드¶
명명된 각 노트북 다음과 같은 이름 값 페어를 지원합니다.
``main_file``(문자열, 필수) 대화형 Python 노트북(.ipynb) 파일의 이름입니다.
``comment``(문자열, 선택 사항): 노트북을 설명하는 설명입니다.
``runtime_environment_version``(문자열, 선택 사항): 플랫폼 내에서 해당되는 경우 노트북 실행 컨텍스트에 대한 특정 :ref:`런타임 환경 버전<label-notebook_runtime_descriptions>`을 지정합니다.
``roles``(목록, 선택 사항): 노트북에 대한 액세스 권한을 부여할 수 있는 앱 역할 목록(예:
[sales,marketing])입니다. 이 필드가 비어 있거나([]) 생략된 경우 앱 소유자 및 :ref:`IMPORTED PRIVILEGES<label-sa_share_access_to_all_data>`가 부여된 역할만 액세스 권한을 받습니다. 포함된 역할은 :ref:`최상위 역할 필드<label_sa-manifest-roles-top>`에 정의되어야 합니다.
application_context 예제¶
이 예에서 단일 노트북인 salesbook**은 알려진 **안정적인 런타임을 사용하고 영업 또는 마케팅 역할이 부여된 사용자에게 액세스 권한을 제공하는 노트북 파일 **NOTEBOOK1.ipynb**를 사용하여 정의됩니다.
application_content:
notebooks:
- salesbook:
roles: [sales, marketing]
main_file: NOTEBOOK1.ipynb
comment: Notebook1: Sales and marketing notebook
runtime_environment_version: stable
roles:
- sales:
- marketing:
roles 필드¶
roles 최상위 필드(목록, 선택 사항)는 :doc:`앱 역할 <app-roles>`의 목록을 정의합니다. 이러한 역할을 통해 앱 소유자는 스키마, 테이블, 뷰, 노트북과 같은 앱의 공유 오브젝트에 대한 액세스 권한을 조직에 제공할 수 있습니다.
명명된 각 역할에는 선택적으로 ``comment``가 포함될 수 있으며, 이는 앱 소유자가 애플리케이션에서 역할을 나열할 때 설명으로 나타납니다.
이러한 역할은 매니페스트에서 공유 오브젝트에 의해 명명된 notebook, schema, table, view 수준으로 참조됩니다. table 또는 view 수준의 오브젝트의 경우 역할은 schema 수준에서도 지정되어야 합니다.
참고
매니페스트의 모든 콘텐츠는 앱 소유자, ACCOUNTADMIN 및 앱에 :ref:`IMPORTED PRIVILEGES<label-sa_share_access_to_all_data>`가 부여된 역할의 사용자가 액세스할 수 있습니다.
이 매니페스트 파일에 정의된 오브젝트 이름은 런타임 오브젝트 확인에 사용됩니다. 공급자가 매니페스트 파일을 새 버전으로 업데이트하지 않고 오브젝트 이름을 변경하면 컨슈머는 오브젝트에 액세스할 수 없게 됩니다.
roles 예제¶
roles:
- sales:
- marketing:
application_content:
notebooks:
- salesbook:
roles: [sales, marketing]
main_file: NOTEBOOK1.ipynb
comment: Sales and marketing notebook
shared_content:
databases:
- sales:
schemas:
- orders:
roles: [sales, marketing]
tables:
- january_2025: # App owners/assignees only
- february_2025:
roles: [sales] # Accessible to sales only
- march_2025:
roles: [marketing] # Accessible to marketing only
- customer_info:
schemas:
- customer_contact:
roles: [customer_support]
views:
- customer_address:
roles: [customer_support] # Accessible to customer_support
- customer_details:
roles: [] # App owners/assignees only
역할에 대한 자세한 내용은 :doc:`앱 역할<app-roles>`을 참조하세요.
매니페스트 파일 예¶
다음 코드 블록은 Declarative Native App 매니페스트 파일의 예입니다.
manifest_version: 2
roles:
- VIEWER:
comment: "The VIEWER role provides access to only one view."
- ANALYST:
comment: "The ANALYST role provides access to both views and the table."
shared_content:
databases:
- SNAF_POPULATION_DB:
schemas:
- DATA_SCHEMA:
roles: [VIEWER, ANALYST]
tables:
- COUNTRY_POP_BY_YEAR:
roles: [ANALYST]
views:
- COUNTRY_POP_BY_YEAR_2000:
roles: [VIEWER, ANALYST]
application_content:
notebooks:
- intro_notebook:
roles: [VIEWER, ANALYST]
main_file: INTRO_NB.ipynb
- analyst_notebook:
roles: [ANALYST]
main_file: ANALYST_NB.ipynb