Skip to content

Database description#

All the data of the timestamp type is stored in the RFC 3339 format.

The time used for storing data in the database can be set in the configuration file for each service in the "STORAGE_TIME" parameter. You can select "LOCAL" or "UTC" storage time.

When the "STORAGE_TIME" is set to "LOCAL" but you receive time in "UTC", data is converted to local time. When "UTC" is set but the received time is local it is also converted to "UTC".

Faces database description#

This section describes the Faces database fields.

For more information, see "Faces service".

Faces database schema
Faces database schema

Attribute table model#

The database table model describes face attributes linked to faces.

Name

Type

Description

face_id

varchar(36)

Face ID.

gender

integer

Result of gender estimation based on face image:

  • "0" β€” Male
  • "1" β€” Female

gender_obtaining_method

integer

Algorithm used to estimate gender based on face image.

gender_version

integer

Version of the algorithm for estimating gender based on face image.

age

integer

Result of age estimation based on face image.

age_obtaining_method

integer

Algorithm used to estimate age based on face image.

age_version

integer

Version of the algorithm for estimating age based on face image.

ethnicity

integer

Result of ethnicity estimation.

ethnicity_obtaining_method

integer

Version of the algorithm for estimating ethnicity.

ethnicity_version

integer

Version of the algorithm for estimating ethnicity.

create_time

timestamp

Attribute creation date and time.

account_id

varchar(36)

Account ID to which the attribute belongs.

descriptor_samples_generation

integer

Generation of the samples used. This value changes when the attribute sample is updated. The initial value is 0.

Descriptor table model#

The database table model describes descriptors.

Name

Type

Description

attribute_id

varchar(36)

Attribute ID.

descriptor_version

integer

Version of NN that was used to extract the descriptor.

descriptor

bytea

Binary descriptor.

descriptor_obtaining_method

integer

Algorithm that was used to obtain the descriptor.

descriptor_generation

integer

Generation of the descriptor. This value changes when the attribute descriptor is updated. It shows that the descriptor does not match existing samples. The initial value is 0.

encryption_hash

bytea | Hash sum of the encryption key and algorithm. See "Descriptor encryption".

Face table model#

The database table model describes existing faces.

Name

Type

Description

face_id

varchar(36)

Face ID.

account_id

varchar(36)

Account ID to which the face belongs.

event_id

varchar(36)

Event ID. A reference to the event that created the face.

user_data

varchar(128)

User-defined data for the face.

create_time

timestamp

Time and date of the face creation.

last_update_time

timestamp

Time and date of the last face update.

external_id

varchar(36)

External ID.

External ID is specified in the create face request or in the event creation request ("face_policy").

avatar

varchar(256)

URL of a photo image that corresponds to the face.

List table model#

The database table model describes existing lists.

Name Type Description
list_id varchar(36) List ID.
account_id varchar(36) Account ID to which the list belongs.
user_data varchar(128) User data for the list.
create_time timestamp Time and date when the list was created.
last_update_time timestamp Time and date of the last list update.

List_face table model#

The database table model describes the history of attaching faces to lists. If a face was attached to a list a new record appears.

Name Type Description
list_id varchar(36) List ID.
face_id varchar(36) Face ID.
last_update_time timestamp Date and time of the last linking of the face to the list.
link_key integer Sequence number of linking the face to the list.

The database table model describes the history of detaching faces from lists. If a face was detached from a list, a new record appears.

Name Type Description
unlink_key integer Sequence number of the face and the list unlinking.
list_id varchar(36) List ID.
face_id varchar(36) Face ID.
link_key integer Sequence number of linking of the face and the list.
update_time timestamp Date and time of the last detach of the face from the kist.

Sample table model#

The database table model describes links between samples and faces.

Name

Type

Description

sample_id

varchar(36)

Sample.

face_id

varchar(36)

Face ID related to the sample.

type

integer

Method of using the sample:

  • "1" β€” To extract descriptor.
  • "5" β€” To create basic attributes.

The database table model describes the history of deleting lists. If the list has been deleted, a new entry appears.

Name Type Description
list_id varchar(36) List ID.
account_id varchar(36) Account ID to which the list was attached.
deletion_time timestamp Date and time when the list was deleted.
create_time timestamp Date and time when the list was created.
deletion_id integer Deletion ID.

Requests_cache table model#

The database table model describes the cache of the maximum number of faces with associated descriptors or basic attributes for license requests.

Name Type Description
created_at timestamp Date and time of data caching.
value text Encrypted value cache.
name varchar(36) Unique cache name.

Luna-faces_migrations table model#

Name Type Description
version_num varchar(32) Parameter required for database migration.

Events database description#

This section describes the fields in the Events database.

For more information, see "Events service".

Events database schema
Events database schema

Event table model#

The database table model describes existing events. It includes information about created events and faces.

Name

Type

Description

id

bigint

Primary key of the table (digital).

account_id

uuid

Account ID to which the event belongs.

create_time

timestamp

Time code of the event occurrence in the video stream. The parameter is used for the real-time monitoring of events creation.

event_id

uuid

Event ID.

handler_id

uuid

Handler ID that created the event.

source

varchar(128)

Event source. The source is specified in the request for event creation.

face_id

uuid

Face ID of the face corresponding to the event.

gender

smallint

Result of gender estimation based on face image.

age

smallint

Result of age estimation based on face image.

emotion

smallint

Result of emotions estimation.

ethnic_group

smallint

Result of ethnic group estimation.

user_data

varchar(128)

User data for the face corresponding to the event. User data is specified in the request for event creation.

external_id

varchar(36)

External ID of the face corresponding to the event. External ID is specified in the request for event creation.

insert_time

timestamp

Date and time of the event creation.

top_matching_candidates_label

varchar(36)

Label of the group of the candidates used for matching.

top_similar_object_id

uuid

ID of the top similar object from matching results. Matching results are received when the "match_policy" of a handler is enabled.

top_similar_object_similarity

double precision

Similarity score of the top similar object from matching results. Matching results are received when the "match_policy" of a handler is enabled.

top_similar_object_type

smallint

Type of the top similar object:

  • "0" β€” Face
  • "1" β€” Event

mask

smallint

Result of medical mask estimation:

  • "1" β€” Missing
  • "2" β€” Medical mask
  • "3" β€” Occluded

track_id

varchar(36)

Track ID. The ID can be specified in the event generation request.

liveness

smallint

Result of Liveness check:

  • "0" β€” Spoof
  • "1" β€” Real
  • "2" β€” Unknown

end_time

timestamp

End time code of the event occurrence in the video stream. The parameter is used for the real-time monitoring of events creation. Set equal to "create_time" if not set.

top_similar_external_id

varchar(36)

External ID of the top similar object from matching results. Matching results are received when the "match_policy" of a handler is enabled.

apparent_age

smallint

Result of age estimation based on body image.

apparent_gender

smallint

Result of gender estimation based on body image:

  • "0" β€” Female
  • "1" β€” Male
  • "2" β€” Unknown

backpack_state

smallint

Result of backpack state estimation:

  • "0" β€” Absent
  • "1" β€” Present
  • "2" β€” Unknown

headwear_state

smallint

Result of headwear state estimation:

  • "0" β€” Absent
  • "1" β€” Present
  • "2" β€” Unknown

sleeve_length

smallint

Result of sleeve length estimation:

  • "0" β€” Short
  • "1" β€” Long
  • "2" β€” Undefined

upper_clothing_color

array[int]

Result of upper clothing color estimation:

  • "0" β€” Unknown
  • "1" β€” Black
  • "2" β€” Blue
  • "3" β€” Green
  • "4" β€” Gray
  • "5" β€” Orange
  • "6" β€” Purple
  • "7" β€” Red
  • "8" β€” White
  • "9" β€” Yellow
  • "10" β€” Pink
  • "11" β€” Brown
  • "12" β€” Beige
  • "13" β€” Khaki
  • "14" β€” Multicolored

headwear_apparent_color

smallint

Result of headwear apparent color estimation:

  • "0" β€” Unknown
  • "1" β€” White
  • "2" β€” Black
  • "3" β€” Other

lower_garment_type

smallint

Result of lower garment type estimation:

  • "0" β€” Unknown
  • "1" β€” Trousers
  • "2" β€” Shorts
  • "3" β€” Skirt

lower_garment_colors

array[int]

Result of lower garment colors estimation:

  • "0" β€” Unknown
  • "1" β€” Black
  • "2" β€” Blue
  • "3" β€” Green
  • "4" β€” Gray
  • "5" β€” Orange
  • "6" β€” Purple
  • "7" β€” Red
  • "8" β€” White
  • "9" β€” Yellow
  • "10" β€” Pink
  • "11" β€” Brown
  • "12" β€” Beige
  • "13" β€” Khaki
  • "14" β€” Multicolored

shoes_apparent_color

smallint

Result of shoes apparent color estimation:

  • "0" β€” Unknown
  • "1" β€” White
  • "2" β€” Black
  • "3" β€” Other

meta

jsonb

User meta-information.

deepfake

smallint

Result of Deepfake estimation:

  • "0" β€” Spoof
  • "1" β€” Real

Face_detect_result table model#

The database table model describes face detection.

Name Type Description
id bigint Primary key of the table (digital).
numeric_id integer Foreign key of an event.
rect_x smallint Top left corner coordinate of the face bounding rectangle by the "X" axis.
rect_y smallint Top left corner coordinate of the face bounding rectangle by the "Y" axis.
rect_w smallint Width of the face bounding rectangle.
rect_h smallint Height of the face bounding rectangle.
sample_id varchar(36) Sample ID.
detect_time timestamp Time of the face detection.
image_origin varchar(256) URL to the source image where the face has occurred.
detect_ts interval Time relative to something, such as relative to the beginning of a video file.

Body_detect_result table model#

The database table model describes face detection.

Name Type Description
id bigint Primary key of the table (digital).
numeric_id integer Foreign key of an event.
rect_x smallint Top left corner coordinate of the body bounding rectangle by the "X" axis.
rect_y smallint Top left corner coordinate of the body bounding rectangle by the "Y" axis.
rect_w smallint Width of the body bounding rectangle.
rect_h smallint Height of the body bounding rectangle.
sample_id varchar(36) Sample ID.
detect_time timestamp Time of the body detection.
image_origin varchar(256) URL to the source image where the body has occurred.
detect_ts interval Time relative to something, such as relative to the beginning of a video file.

Face_descriptor table model#

The database table model describes face descriptors stored in the database.

Name Type Description
id bigint Primary key of the table (digital).
numeric_id bigint Foreign key of the event.
descriptor bytea Binary face descriptor.
descriptor_version integer The version of NN that was used to extract the descriptor.
encryption_hash bytea Hash sum of the encryption key and algorithm. See "Descriptor encryption".

Body_descriptor table model#

The database table model describes body descriptors stored in the database.

Name Type Description
id bigint Primary key of the table (digital).
numeric_id bigint Foreign key of the event.
descriptor bytea Binary body descriptor.
descriptor_version integer The version of NN that was used to extract the descriptor.
encryption_hash bytea Hash sum of the encryption key and algorithm. See "Descriptor encryption"

Event_match_result table model#

The database table model describes matching results received using the matching policy of handler. Each record includes information about an event used for matching and the estimated similarity.

Name Type Description
id bigint Primary key of the table (digital).
numeric_id bigint Foreign key of the event.
label varchar(36) The label specified for the matching results.
similarity double precision The similarity score received after matching of the event descriptor with the given descriptor.
event_id uuid Event ID.
user_data varchar(128) User data associated with the event.
create_time timestamp Event creation time.
external_id varchar(36) External ID of the face created during event creation.
handler_id uuid ID used for the event creation .
source varchar(128) Event source.

Face_match_result table model#

The database table model describes matching results received using the matching policy of handler. Each record includes information about the face used for matching and the estimated similarity.

Name Type Description
id bigint Primary key of the table (digital).
numeric_id bigint Foreign key of the event.
label varchar(36) The label specified for the matching results.
similarity double precision The similarity score received after matching of the event descriptor with the given face descriptor.
face_id uuid Face ID.
user_data varchar(128) User data associated with the face.
create_time timestamp Face creation time.
external_id varchar(36) External ID of the face.

Location table model#

Name Type Description
id bigint Primary key of the table (digital).
numeric_id bigint Foreign key of the event.
city varchar(36) The city of event occurrence.
area varchar(36) The area of event occurrence.
district varchar(36) The district of event occurrence.
street varchar(128) The street of event occurrence.
house_number varchar(36) The house number where the event occurred.
geo_position geography Geographical coordinate of the event occurrence (longitude, latitude).

Tag table model#

The database table model describes tags for events. Tags are specified in an event creation request.

Name Type Description
id bigint Primary key of the table (digital).
numeric_id integer Foreign key of an event.
tag varchar(36) Event tag.

Attach_result table model#

The database table model describes the attachment of the face created from an event to a list. The face is created using "face_policy". The face is attached to a list using "link_to_lists_policy".

Name Type Description
id bigint Primary key of the table (digital).
numeric_id integer Foreign key of an event.
list_id uuid List to which the created face was attached.

Tasks database#

This section describes the fields in the Tasks database.

For more information, see "Tasks service".

Tasks database schema
Tasks database schema

Task table model#

The database table model describes the created tasks. It includes general information about a task and its content.

Name

Type

Description

task_id

integer

Task ID.

create_time

timestamp

Task creation time.

end_time

timestamp

Task end time.

last_update_time

timestamp

Task last update time.

task_type

integer

Task type:

  • "0" β€” Unknown
  • "1" β€” Linker
  • "2" β€” Clustering
  • "3" β€” Reporter
  • "4" β€” Garbage collection
  • "5" β€” Additional extraction
  • "6" β€” Cross-matching
  • "7" β€” ROC-curve calculating
  • "8" β€” Exporter
  • "9" β€” Estimator

task_status

integer

Task status:

  • "0" β€” Pending
  • "1" β€” In progress
  • "2" β€” Cancelled
  • "3" β€” Failed
  • "4" β€” Collect results
  • "5" β€” Done

result_id

varchar(36)

Task result ID.

account_id

varchar(36)

Account ID to which the task belongs.

count_task_parts_done

integer

Number of finished subtasks.

count_task_parts_all

integer

Total number of subtasks.

content

text

Filters and request parameters for the task.

description

varchar(128)

User-defined task description.

schedule_id

integer

Schedule ID.

Subtask table model#

The database table model includes information about created subtasks. Depending on a task type there may be one or several subtasks.

Name

Type

Description

subtask_id

integer

Subtask ID.

task_id

integer

ID of the corresponding task.

result_id

varchar(36)

ID of the subtask result.

create_time

timestamp

Subtask creation time.

end_time

timestamp

Subtask end time.

subtask_status

integer

Subtask status:

  • "0" β€” Pending
  • "1" β€” In progress
  • "2" β€” Cancelled
  • "3" β€” Failed
  • "4" β€” Collect results
  • "5" β€” Done

content

text

Filters and request parameters for a subtask processing.

Task_error table model#

The database table model includes information about errors occurred during task processing. Errors are added to the table by Tasks workers.

Name Type Description
error_id integer Task error ID.
task_id integer ID of the corresponding task.
error_code integer Error code.
description varchar(64) Error short description.
detail varchar(1024) Detailed description of the error.
additional_info varchar(128) Additional information about the error. It may include lost object IDs or any other useful information.
error_time timestamp Time when the error occurred.

Schedule table model#

The database table model includes information about the task execution schedule.

Name

Type

Description

schedule_id

integer

Schedule ID.

create_time

timestamp

Date the schedule was created.

last_update_time

timestamp

Date and time of the last schedule changes.

status

smallint

Schedule status:

  • "1" β€” Started
  • "2" β€” Stopped

trigger

varchar(128)

Cron expression.

trigger_timezone

varchar(16)

Time zone (UTC or LOCAL).

account_id

varchar(36)

Account ID that the schedule belongs to.

task_type

integer

Type of task that runs on a schedule.

content

text

Content of the scheduled task (filters, list, etc.)

next_run_at

timestamp

Time of the next task start.

Luna-tasks_migrations table model#

Name Type Description
version_num varchar(32) Parameter required for database migration.

Handlers database#

This section describes the fields in the Handlers database.

For more information about the Handlers service, see "Handlers service".

Handlers database schema
Handlers database schema

Handler table model#

Name

Type

Description

handler_id

varchar(36)

UUID4 standard handler ID in "xxxxxxxx-xxxx-4xxx-{8-9}xx-xxxxxxxxxxxx" format.

account_id

varchar(36)

Account ID in UUID4 format that the handler belongs to.

create_time

timestamp

Date and time of handler creation.

last_update_time

timestamp

Date and time of last change of the handler.

description

varchar(128)

Handler description provided by the user.

handler_type

smallint

Handler type:

  • "0" β€” Static
  • "1" β€” Dynamic
  • "2" β€” Lambda

lambda_id

smallint

Lambda ID.

policies

varchar(36)

Handler policies.

Verifier table model#

Name Type Description
account_id varchar Account ID in UUID4 format that the verifier belongs to.
create_time timestamp Date and time of verifier creation.
description varchar Verifier description provided by the user.
verifier_id varchar(36) UUID4 standard verifier ID in "xxxxxxxx-xxxx-4xxx-{8-9}xx-xxxxxxxxxxxx" format.
last_update_time timestamp Date and time of the latest handler modification.
policies varchar(2048) Verifier policies.
version integer Verifier version.

Luna-handlers_migrations table model#

Name Type Description
version_num varchar(32) Parameter required for database migration.

Configurator database#

This section describes the fields of the Configurator database.

For more information, see "Configurator service".

Configurator database schema
Configurator database schema

Limitation table model#

Name Type Description
limitation_name varchar(128) Name of the limitation.
validation_schema varchar Limitation validation schema.
services varchar List of services.
default_value varchar Default limitation value.
description varchar(128) Limitation description.

Settings table model#

Name Type Description
id integer Setting ID.
value varchar Setting value.
description varchar(128) Settings description.
create_time timestamp Setting creation time.
last_update_time timestamp Latest time of setting modification.
name varchar(128) Setting name.
is_default boolean Whether the setting is default.

Tag table model#

Name Type Description
id integer Setting ID.
name varchar(128) Setting name.
tag varchar(128) Setting tag string.

Group table model#

Name Type Description
group_name varchar(128) Group name.
description varchar(256) Group description.

Group_limitation table model#

Name Type Description
group_name varchar(128) Group name.
limitation_name varchar(128) Limitation name.

Configs_migration table model#

Name Type Description
revision varchar(36) Revision of settings migration.

Luna-conf_migrations table model#

Name Type Description
version_num varchar(32) Parameter required for database migration.

Backport3 database#

This section describes the fields of the Backport 3 database.

For more information, see "Backport 3 service".

Backport3 database schema
Backport3 database schema

Account table model#

Database table model for account.

Name Type Description
account_id varchar(36) UUID4 standard account ID.
active boolean Account status.

Account_token model table#

Name Type Description
token_id varchar(36) Token ID.
account_id varchar(36) Account ID, the token is linked to.
token_info varchar(128) A string with token data.

Person table model#

Name Type Description
person_id varchar(36) UUID4 standard person ID, in "xxxxxxxx-xxxx-4xxx-{8-9}xx-xxxxxxxxxxxx" format.
account_id varchar(36) UUID4 standard ID of the account to which the person belongs, "xxxxxxxx-xxxx-4xxx-{8-9}xx-xxxxxxxxxxxx" format.
user_data varchar(128) Person user data.
create_time timestamp Date and time of person creation.
external_id varchar(36) Person ID in external system.

Persons_list table model#

Name Type Description
list_id varchar(36) UUID4 standard list ID in "xxxxxxxx-xxxx-4xxx-{8-9}xx-xxxxxxxxxxxx" format.
account_id varchar(36) UUID4 standard account ID, in "xxxxxxxx-xxxx-4xxx-{8-9}xx-xxxxxxxxxxxx" format.
create_time timestamp Date and time of list creation.

Descriptors_list table model#

Name Type Description
list_id varchar(36) UUID4 standard list ID in "xxxxxxxx-xxxx-4xxx-{8-9}xx-xxxxxxxxxxxx" format.
account_id varchar(36) UUID4 standard account ID, the list belongs to, in "xxxxxxxx-xxxx-4xxx-{8-9}xx-xxxxxxxxxxxx" format.
create_time timestamp Date and time of list creation.

List_person table model#

Name Type Description
list_id varchar(36) UUID4 standard list ID in "xxxxxxxx-xxxx-4xxx-{8-9}xx-xxxxxxxxxxxx" format.
person_id varchar(36) UUID4 standard person ID, in "xxxxxxxx-xxxx-4xxx-{8-9}xx-xxxxxxxxxxxx" format.

Person_face table model#

Name Type Description
person_id varchar(36) UUID4 standard person ID, in "xxxxxxxx-xxxx-4xxx-{8-9}xx-xxxxxxxxxxxx" format.
face_id varchar(36) UUID4 standard face ID, in "xxxxxxxx-xxxx-4xxx-{8-9}xx-xxxxxxxxxxxx" format.

Luna-backport3_migrations table model#

Name Type Description
version_num varchar(32) Parameter required for database migration.

Handler table model#

Name Type Description
account_id varchar(36) UUID4 standard account ID, the handler belongs to, in "xxxxxxxx-xxxx-4xxx-{8-9}xx-xxxxxxxxxxxx" format.
type integer Handler type.
handler_id varchar(36) UUID4 standard handler ID in "xxxxxxxx-xxxx-4xxx-{8-9}xx-xxxxxxxxxxxx" format.
create_time timestamp Date and time of handler creation.
last_update_time timestamp Date and time of the latest handler modification.
policies varchar(2048) handler policies.
version integer Handler version.

Accounts database#

This section describes the fields in the Accounts database.

For more information, see "Accounts service".

Accounts database schema
Accounts database schema

Account table model#

Name

Type

Description

account_id

varchar(36)

Account ID in UUID4 format.

login

varchar(128)

Account login.

password

varchar(128)

Account password.

description

varchar(128)

Account description.

account_type

varchar(16)

Account type:

  • "user"
  • "advanced_user"
  • "admin"

create_time

timestamp

Date and time of account creation.

last_update_time

timestamp

Date and time of the latest account modification.

Token table model#

Name

Type

Description

token_id

varchar(36)

Token ID in UUID4 format.

permissions

varchar(128)

Token permissions.

expiration_time

varchar(128)

Token expiration time.

description

varchar(128)

Token description.

visibility_area

varchar(128)

Token visibility area:

  • "all"
  • "account"

account_id

varchar(16)

Account ID in UUID4 format to which the token is linked.

Luna-accounts_migration table model#

Name Type Description
version_num varchar(32) Parameter required for database migration.

Lambda database#

This section describes the fields of the Lambda database.

For more information, see "Lambda service".

Lambda DB schema
Lambda DB schema

Lambda table model#

Name

Type

Description

name

varchar(36)

Lambda name.

description

varchar(256)

Lambda description.

version

integer

Lambda version.

account_id

varchar(16)

Account ID in UUID4 format to which the lambda is linked.

status

smallint

Lambda creation status:

  • "running"
  • "waiting"
  • "terminated"
  • "not_found"

create_time

timestamp

Lambda creation time.

last_update_time

timestamp

Lambda last updated date and time.

user_commands

varchar

List of additional Docker commands for creating a lambda container.

lambda_type

varchar(10)

Lambda type:

  • "handlers"
  • "standalone"

id

varchar(36)

Lambda ID.

Luna-lambda_migration table model#

Name Type Description
version_num varchar(32) Parameter required for database migration.

Video Manager database#

This section provides a description of the fields in the Video Manager database.

For more details, see the "Video analytics services" section.

DB Structure of Video Manager
DB Structure of Video Manager

Stream table model#

Name

Type

Description

id

bigint

Internal stream identifier.

account_id

varchar(36)

UUID4 formatted account ID to which the stream is linked.

name

varchar(128)

Stream name.

description

varchar(512)

Stream description.

type

varchar(36)

Stream type β€” "videofile" or "stream".

reference

varchar(512)

Stream address.

rotation

smallint

Camera frame rotation angle.

status

smallint

Stream processing status:

  • "0" β€” Stream awaiting processing ("pending").
  • "1" β€” Stream processing in progress ("in_progress").
  • "2" β€” Stream processing completed ("done").
  • "3" β€” Stream processing reset by server ("restart").
  • "4" β€” Stream processing failed ("failure").
  • "5" β€” Stream processing stopped by user ("stop").

version

varchar(10)

Stream version.

create_time

timestamp

Stream creation time.

status_last_update_time

timestamp

Last status update time.

last_feedback_time

timestamp

Last feedback time.

stream_id

varchar(36)

Stream identifier.

Group table model#

This table contains information about the group.

Name Type Description
id bigint Internal group identifier.
group_name varchar(128) Group name.
account_id varchar(36) UUID4 formatted account ID to which the stream is linked.
description varchar(256) Group description.
create_time timestamp Group creation time.
group_id varchar(36) Group identifier.

Group_stream table model#

This table contains information about the relationship between groups and streams.

Name Type Description
group_id varchar(36) Group identifier.
group_name varchar(128) Group name.
stream_id varchar(36) Stream identifier.
id bigint Internal stream identifier.

Restart table model#

This table contains information about the automatic stream restart.

Name

Type

Description

restart

smallint

Is automatic stream restart enabled. "1" β€” enabled, "0" β€” disabled.

attempt_count

smallint

Number of attempts to be made for automatic restart.

delay

integer

Automatic restart delay.

current_attempt

smallint

Current number of restart attempts made.

last_attempt_time

timestamp

Last restart attempt time.

status

smallint

Automatic restart status:

  • "0" β€” Automatic restart disabled ("disabled").
  • "1" β€” Automatic restart enabled ("enabled").
  • "2" β€” Automatic restart in progress ("in_progress").
  • "3" β€” Automatic restart failed ("failed").

stream_id

varchar(36)

Stream identifier.

Stream_meta table model#

This table contains information about additional stream details set during its creation request.

Name Type Description
account_id varchar(36) UUID4 formatted account ID to which the stream is linked.
city varchar(36) City.
area varchar(36) Area.
district varchar(36) District.
street varchar(36) Street.
house_number varchar(36) House number.
geo_position geography Geographic coordinates (latitude, longitude).
stream_id varchar(36) Stream identifier.

Video_analytic table model#

This table contains information about video analytics.

Name Type Description
analytic_name varchar(36) Analytic name.
description varchar(512) Analytic description.
documentation bytea Documentation file.
version smallint Analytic version.
validation_schema varchar Validation schema.
default_parameters varchar Default analytic parameters.
account_id varchar(36) UUID4 formatted account ID to which the stream is linked.
create_time timestamp Analytic creation time.
last_update_time timestamp Last analytic update time.
analytic_id varchar(36) Analytic identifier.

Agent table model#

This table contains information about an agent.

Name

Type

Description

agent_name

varchar(128)

Agent name.

description

varchar(512)

Agent description.

status

smallint

Agent status:

  • "0" β€” Not ready ("not_ready").
  • "1" β€” Ready ("ready").

max_stream_count

smallint

Maximum number of streams the agent can process.

active_stream_count

smallint

Current number of streams processed by the agent.

account_id

varchar(36)

UUID4 formatted account ID to which the agent is linked.

create_time

timestamp

Agent creation time.

last_update_time

timestamp

Last agent update time.

last_feedback_time

timestamp

Last feedback time.

agent_id

varchar(36)

Agent identifier.

Stream_analytic table model#

This table contains information about the analytics required by a stream.

Name Type Description
analytic_id varchar(36) Analytic identifier.
stream_id varchar(36) Stream identifier.
analytic_name varchar(36) Analytic name.
analytic_parameters varchar Analytic parameters.
id bigint Internal analytic identifier.

Agent_analytic table model#

This table contains information about the analytics an agent can work with.

Name Type Description
agent_id varchar(36) Agent identifier.
analytic_id varchar(36) Analytic identifier.
analytic_name varchar(36) Analytic name.
id bigint Internal agent identifier.

Agent_stream table model#

Name Type Description
status smallint Internal agent status.
agent_id varchar(36) Agent identifier.
stream_id varchar(36) Stream identifier.
id bigint Internal identifier.

Log table model#

This table contains information about stream processing logs.

Name

Type

Description

stream_id

varchar(36)

Stream identifier.

time

timestamp

Log creation time.

error

varchar

Stream processing error description.

status

smallint

Stream processing status:

  • "0" β€” Stream awaiting processing ("pending").
  • "1" β€” Stream processing in progress ("in_progress").
  • "2" β€” Stream processing completed ("done").
  • "3" β€” Stream processing reset by server ("restart").
  • "4" β€” Stream processing failed ("failure").
  • "5" β€” Stream processing stopped by user ("stop").

status_last_update_time

timestamp

Last status update time.

meta

varchar

Currently unused parameter.

log_id

bigint

Log identifier.

Luna_video_migrations table model#

Name Type Description
version_num varchar(32) Parameter required for database migration.