You are here

function s3fs_update_7000 in S3 File System 7.2

Same name and namespace in other branches
  1. 7.3 s3fs.install \s3fs_update_7000()
  2. 7 s3fs.install \s3fs_update_7000()

Allow large filesize values in the S3 File Metadata cache.

File

./s3fs.install, line 191
Install, update and uninstall functions for the S3 File System module.

Code

function s3fs_update_7000() {
  $spec = array(
    'description' => 'The size of the file in bytes.',
    'size' => 'big',
    'type' => 'int',
    'unsigned' => TRUE,
    'not null' => TRUE,
    'default' => 0,
  );
  db_change_field('s3fs_file', 'filesize', 'filesize', $spec);
  $config = _s3fs_get_config();
  if (!empty($config['bucket']) && !empty($config['region'])) {
    _s3fs_refresh_cache($config);
  }
  else {
    drupal_set_message(t('S3 bucket name or region unknown. Unable to refresh metadata cache table.'), 'error');
  }
}