Skip to content

Latest commit

 

History

History
92 lines (82 loc) · 5.49 KB

models.md

File metadata and controls

92 lines (82 loc) · 5.49 KB

Models

Publication

  • Publication is any geospatial data that can be published by Layman through REST API.
  • Currently available publications are map and layer.
  • Each publication is placed in one workspace.

Layer

  • Layer is publication created from combination of vector or raster data (GeoJSON, ShapeFile, GeoTIFF, JPEG2000, PNG or JPEG) and visualization (SLD, SE, or QML style). Raster layer can hold also timeseries data.
  • Published layer can be accessed by standardized OGC interfaces
  • Thumbnail image available
  • Layer-related data is named and structured
    • either by workspace name and layername
      • REST API: /rest/workspaces/<workspace_name>/layers/<layername>
      • filesystem: /path/to/LAYMAN_DATA_DIR/workspaces/<workspace_name>/layers/<layername>
      • GeoServer WFS: /geoserver/<workspace_name>/ows, layer=<layername>
      • GeoServer WMS: /geoserver/<workspace_name>_wms/ows, layer=<layername>, style=<layername>
    • or by UUID:
      • PostgreSQL: db=LAYMAN_PG_DBNAME, schema=<workspace_name>, table=layer_<UUID>
      • Micka: /record/basic/m-<uuid>
  • Simple rules
    • one DB table per input file (vector layers only)
    • one WFS feature type per DB table (vector layers only)
    • one WMS layer per DB table
    • one SLD or QGIS style per WMS layer
    • one thumbnail per WMS layer
    • one metadata record per WMS&WFS layer

Timeseries

  • Timeseries is layer created from set of raster data files (GeoJSON, ShapeFile, GeoTIFF, JPEG2000, PNG or JPEG).
  • Each file represents one time instant, more files may represent the same time instant.
  • Information about time representation is passed through time_regex parameter.

Map

  • Also referred to as map composition
  • Map is publication defined by JSON valid against map-composition schema version 2 used by Hslayers-ng
  • Map is collection of WMS layers and vector data
  • Maps composed from WMS layers only are fully supported
  • Documented map publishing process
  • Thumbnail image available
  • Map-related data is named and structured
    • either by workspace and layername
      • REST API: /rest/workspaces/<workspace_name>/maps/<mapname>
      • file system: /path/to/LAYMAN_DATA_DIR/workspaces/<workspace_name>/maps/<mapname>
    • or by UUID:
      • Micka: /record/basic/m-<uuid>
  • Simple rules
    • one map file per map
    • one thumbnail per map
    • one metadata record per map

User

  • User is any person who communicates with Layman REST API through any client.
  • User can be either authenticated, or unauthenticated (i.e. anonymous).
  • User is sometimes identified by username

Username

  • Username is a string identifying one user, so it is unique among all users.
  • The string is lower-case (in contrast with role name).
  • Each user is represented by max. one username.
  • Username is also used to identify user's personal workspace when communicating with Layman REST API.
  • Username can be reserved by PATCH Current User.
  • Anonymous user has no username.

Role

  • Role is any group of users. One user can be assigned to multiple roles.
  • Each role is identified by name that is unique among all roles.
  • The name is upper-case (in contrast with username).
  • Roles can be used for assigning access rights.

Workspace

  • Workspace is folder for publications.
  • Each workspace is identified by name that is unique among all workspaces.
  • Workspace name is sometimes used for structuring publication-related data. For example, it's part of REST API URL (/rest/workspaces/<workspace_name>/...), directory names (<LAYMAN_DATA_DIR>/workspaces/<workspace_name>/...), DB schemas, or OGC Web Services (/geoserver/<workspace_name>/..., /geoserver/<workspace_name>_wms/...).
  • Workspace's REST API consists of all map and layer endpoints endpoints.
  • There are following types of workspaces:

Personal workspace

  • Personal workspace is a workspace whose name is equal to username of some user.
  • Such user is considered as owner of this workspace and he is the only one who can publish new publications in this workspace.
  • Personal workspace is created automatically when username is reserved.

Public workspace