function feeds_update_6009 in Feeds 7
Same name and namespace in other branches
- 6 feeds.install \feeds_update_6009()
Add feeds_push_subscriptions tables.
File
- ./
feeds.install, line 396 - Schema definitions install/update/uninstall hooks.
Code
function feeds_update_6009() {
$ret = array();
$table = array(
'description' => 'PubSubHubbub subscriptions.',
'fields' => array(
'domain' => array(
'type' => 'varchar',
'length' => 128,
'not null' => TRUE,
'default' => '',
'description' => 'Domain of the subscriber. Corresponds to an importer id.',
),
'subscriber_id' => array(
'type' => 'int',
'not null' => TRUE,
'default' => 0,
'unsigned' => TRUE,
'description' => 'ID of the subscriber. Corresponds to a feed nid.',
),
'timestamp' => array(
'type' => 'int',
'unsigned' => FALSE,
'default' => 0,
'not null' => TRUE,
'description' => 'Created timestamp.',
),
'hub' => array(
'type' => 'text',
'not null' => TRUE,
'description' => 'The URL of the hub endpoint of this subscription.',
),
'topic' => array(
'type' => 'text',
'not null' => TRUE,
'description' => 'The topic URL (feed URL) of this subscription.',
),
'secret' => array(
'type' => 'varchar',
'length' => 128,
'not null' => TRUE,
'default' => '',
'description' => 'Shared secret for message authentication.',
),
'status' => array(
'type' => 'varchar',
'length' => 64,
'not null' => TRUE,
'default' => '',
'description' => 'Status of subscription.',
),
'post_fields' => array(
'type' => 'text',
'not null' => FALSE,
'description' => 'Fields posted.',
'serialize' => TRUE,
),
),
'primary key' => array(
'domain',
'subscriber_id',
),
'indexes' => array(
'timestamp' => array(
'timestamp',
),
),
);
db_create_table($ret, 'feeds_push_subscriptions', $table);
return $ret;
}