Virtual File System (VFS)
I. Introduction
VFS (acronym for Virtual File System) is an IO component that
offers a simple mechanism to access files from remote site or a
particular file structure in a same way as native file system from
OS.
1. VFS components
- Schema
The component that uniquely identifies VFS from others.
Example: s3: for Amazon Web Services S3
VFS.
- Address
The component that indicates the location of VFS.
Example: https://s3.amazonaws.com for Amazon Web
Services S3 VFS.
- Particular properties
The specific components that indicate required data necessary
for access VFS. Each of them is a pair of Name and
Value, where Name is the unique
identifier for the property and Value is the
data.
Example: AccessKeyId,
SecretAccessKey for Amazon Web Services S3
VFS.
2. Supported Virtual File Systems
- S3
- Schema: s3
- Particular properties:
- bucket: The AWS bucket name used for connecting
to S3 service (optional if self-contained in the URL address)
- region: The AWS region string used for connecting
to S3 service
- accessKeyId: The username used for connecting to
S3 service
- secretAccessKey: The password used for connecting
to S3 service
- x-amz-*: Other custom parameter(s) used for
connecting to S3 service, if needed (e.g.
'x-amz-request-payer')
- HTTP
- Schema: http
- Particular properties:
- username: The username used for connecting to
HTTP service
- password: The password used for connecting to
HTTP service
Note: Because on HTTP there is not a
clearly defined API, such as on Swift or Amazon AWS, the HTTP VFS
works only with "Index of" pages from Apache HTTP Server.
- Open Stack Swift S3
- Schema: oss
- Particular properties:
- authAddress: The address of authentication
service used for connecting to Open Stack Swift S3 service
- container: The Open Stack Swift S3 container name
used for connecting to Open Stack Swift S3 service
- domain: The Open Stack Swift S3 domain name used
for connecting to Open Stack Swift S3 service
- projectId: The Open Stack Swift S3 project Id
used for connecting to Open Stack Swift S3 service
- user: The username used for connecting to Open
Stack Swift S3 service
- password: The password used for connecting to
Open Stack Swift S3 service
II. The VFS Remote File Repositories
The VFS Remote File Repositories represents a set of
configurations which designate a VFS.
Note: The current VFS implementations
(http, swift, s3) allow multiple Remote File Repositories for each
type of VFS (schema), with the condition that the configured name
is unique.
1. Add a new VFS Remote File Repository
- From SNAP "Tools" menu select "Options".
From "Options" window select "General", then select "Remote File
Repositories".
|
|
- Click on button "Create New Remote File Repository"
from the left of "Remote File
Repositories List" table.
The new VFS Remote File Repository is created and "Remote File
Repository Configurations" area will appear.
|
|
- Enter the "VFS Remote File Repository Name" in the
corresponding field (only alpha-numeric characters and "_"
(underline) are allowed, the name must be unique).
The name of VFS Remote File Repository can be changed anytime by
entering new one in the corresponding field.
If name is correct it will be saved, otherwise a warning message
will notify what was wrong.
|
|
- Enter the "VFS Remote File Repository Scheme" in the
corresponding field (only lowercase alpha-numeric characters are
allowed).
The scheme of VFS Remote File Repository can be changed anytime by
entering new one in the corresponding field.
If schema is correct it will be saved, otherwise a warning message
will notify what was wrong.
|
|
- Enter the "VFS Remote File Repository Address" in the
corresponding field (only URL specific characters are allowed).
The address of VFS Remote File Repository can be changed anytime by
entering new one in the corresponding field.
If address is correct it will be saved, otherwise a warning message
will notify what was wrong.
|
|
- If VFS Remote File Repository requires specific properties such
as "username" and "password", these can be created using next
guideline.
|
|
|
2. Add a new VFS Remote File Repository Property
- From SNAP "Tools" menu select "Options".
From "Options" window select "General", then select "Remote File
Repositories".
|
|
- Select VFS Remote File Repository from "Remote File
Repositories List" table, and Remote "File Repository
Configurations" area will appear.
|
|
- Click on button "Create New Remote File Repository Property"
from the left of "Properties"
table.
The new VFS Remote File Repository Property is created and an empty
row will appear at the end of Properties table.
|
|
- In the new row of "Properties" table, column "Name", enter the
name of new VFS Remote File Repository Property (only alpha-numeric
characters and "_" (underline) are allowed, the name must be
unique) and hit Enter key.
The name of VFS Remote File Repository Property can be changed
anytime by double-clicking on the corresponding cell.
|
|
- In the new row of "Properties" table, column "Value", enter the
value of new VFS Remote File Repository Property (must not be
empty) and hit Enter key. The value of VFS Remote File Repository
Property can be changed anytime by double-clicking on the
corresponding cell.
|
|
|
|
3. Remove VFS Remote File Repository
- From SNAP "Tools" menu select "Options".
From "Options" window select "General", then select "Remote File
Repositories".
|
|
- Select VFS Remote File Repository from "Remote File
Repositories List" table, and Remote "File Repository
Configurations" area will appear.
|
|
- Click on button "Remove Remote File Repository"
from the left of "Remote File
Repositories List" table.
A confirmation prompt will be shown. Answer with YES to confirm the
deletion of Remote File Repository with all Properties.
|
|
|
|
4. Remove VFS Remote File Repository Property
- From SNAP "Tools" menu select "Options".
From "Options" window select "General", then select "Remote File
Repositories".
|
|
- Select VFS Remote File Repository from "Remote File
Repositories List" table, and Remote "File Repository
Configurations" area will appear.
|
|
- Select VFS Remote File Repository Property from "Properties"
table.
|
|
- Click on button "Remove Remote File Repository Property"
from the left of "Properties"
table.
A confirmation prompt will be shown. Answer with YES to confirm the
deletion of Remote File Repository Property.
|
|
|
|
III. Using the VFS
The VFS provides the possibility to open products from remote
locations (e.g. CREODIAS, AWS).
1. Opening a product from VFS
Note: In order to use the VFS for opening a
product, the Remote File Repositories must be correctly configured
and SNAP Application restarted after saving the VFS
configuration.
Note: The following example explains the
opening of a Sentinel-2 (S2) product from Swift VFS (CREODIAS).
- From SNAP "File" menu select "Open Product" or simple click on
button "Open Product"
from the File Toolbar.
|
|
- From SNAP File Chooser select the VFS (e.g. Swift) on "Look in"
combo box. The VFS roots have the icon:
|
|
- Browse through VFS by double-clicking on VFS directories. The
VFS directories have the icon:
|
|
- Select the product file by double-clicking on VFS file or
single-click on it and click on "Open" button . The VFS files have
the icon:
|
|
- Wait until product is opened in SNAP.
|
|
|
|