You are here

public static function S3FileMap::schema in Acquia Content Hub 8.2

Database table scheme for acquia_contenthub_s3.

Return value

array The table schema.

1 call to S3FileMap::schema()
acquia_contenthub_s3_schema in modules/acquia_contenthub_s3/acquia_contenthub_s3.install
Implements hook_schema().

File

modules/acquia_contenthub_s3/src/S3FileMap.php, line 46

Class

S3FileMap
Responsible for storing information about file s3 source.

Namespace

Drupal\acquia_contenthub_s3

Code

public static function schema() : array {
  return [
    'description' => 'Stores information of file source.',
    'fields' => [
      'file_uuid' => [
        'description' => 'The uuid of the file entity.',
        'type' => 'varchar',
        'length' => 128,
        'not null' => TRUE,
        'default' => '',
      ],
      'bucket' => [
        'description' => 'S3 bucket name of the origin.',
        'type' => 'varchar',
        'length' => 255,
        'not null' => TRUE,
        'default' => '',
      ],
      'root_folder' => [
        'description' => 'The s3 root key prefix of the origin',
        'type' => 'varchar',
        'length' => 255,
        'not null' => TRUE,
        'default' => '',
      ],
      'origin_uuid' => [
        'description' => 'The origin site uuid.',
        'type' => 'varchar',
        'length' => 128,
        'not null' => TRUE,
        'default' => '',
      ],
    ],
    'primary key' => [
      'file_uuid',
    ],
    'collation' => 'utf8_bin',
  ];
}