Changeset View
Changeset View
Standalone View
Standalone View
swh/indexer/sql/30-swh-schema.sql
Show First 20 Lines • Show All 92 Lines • ▼ Show 20 Lines | create table content_fossology_license ( | ||||
indexer_configuration_id bigint not null | indexer_configuration_id bigint not null | ||||
); | ); | ||||
comment on table content_fossology_license is 'license associated to a raw content'; | comment on table content_fossology_license is 'license associated to a raw content'; | ||||
comment on column content_fossology_license.id is 'Raw content identifier'; | comment on column content_fossology_license.id is 'Raw content identifier'; | ||||
comment on column content_fossology_license.license_id is 'One of the content''s license identifier'; | comment on column content_fossology_license.license_id is 'One of the content''s license identifier'; | ||||
comment on column content_fossology_license.indexer_configuration_id is 'Tool used to compute the information'; | comment on column content_fossology_license.indexer_configuration_id is 'Tool used to compute the information'; | ||||
-- The table content_metadata provides a translation to files | |||||
-- identified as potentially containning metadata with a translation tool (indexer_configuration_id) | |||||
create table content_metadata( | |||||
id sha1 not null, | |||||
metadata jsonb not null, | |||||
indexer_configuration_id bigint not null | |||||
); | |||||
comment on table content_metadata is 'metadata semantically translated from a content file'; | |||||
comment on column content_metadata.id is 'sha1 of content file'; | |||||
comment on column content_metadata.metadata is 'result of translation with defined format'; | |||||
comment on column content_metadata.indexer_configuration_id is 'tool used for translation'; | |||||
-- The table revision_intrinsic_metadata provides a minimal set of intrinsic | -- The table revision_intrinsic_metadata provides a minimal set of intrinsic | ||||
-- metadata detected with the detection tool (indexer_configuration_id) and | -- metadata detected with the detection tool (indexer_configuration_id) | ||||
-- aggregated from the content_metadata translation. | |||||
create table revision_intrinsic_metadata( | create table revision_intrinsic_metadata( | ||||
id sha1_git not null, | id sha1_git not null, | ||||
metadata jsonb not null, | metadata jsonb not null, | ||||
indexer_configuration_id bigint not null, | indexer_configuration_id bigint not null, | ||||
mappings text array not null | mappings text array not null | ||||
); | ); | ||||
comment on table revision_intrinsic_metadata is 'metadata semantically detected and translated in a revision'; | comment on table revision_intrinsic_metadata is 'metadata semantically detected and translated in a revision'; | ||||
Show All 21 Lines |