{"table_name":"cfr2_offload_status","full_table_name":"wp_cfr2_offload_status","description":"Stores analytics or statistics data.","detection_method":"static","confidence":"medium","create_sql":"CREATE TABLE wp_cfr2_offload_status ( id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT, attachment_id BIGINT UNSIGNED NOT NULL, r2_key VARCHAR(500) NOT NULL, r2_url VARCHAR(500) NOT NULL, local_path VARCHAR(500) NOT NULL, local_exists TINYINT(1) DEFAULT 1, file_size BIGINT UNSIGNED DEFAULT 0, offloaded_at DATETIME DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (id), UNIQUE KEY idx_attachment (attachment_id), KEY idx_r2_key (r2_key(191)) ) $charset_collate;\"; // Queue table. $sql_queue = \"CREATE TABLE wp_cfr2_offload_queue ( id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT, attachment_id BIGINT UNSIGNED NOT NULL, action ENUM('offload', 'restore', 'delete_local') NOT NULL, status ENUM('pending', 'processing', 'completed', 'failed', 'cancelled') DEFAULT 'pending', error_message TEXT, created_at DATETIME DEFAULT CURRENT_TIMESTAMP, processed_at DATETIME, PRIMARY KEY (id), KEY idx_status (status), KEY idx_attachment (attachment_id) ) $charset_collate;\"; // Stats table. $sql_stats = \"CREATE TABLE wp_cfr2_stats ( id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT, date DATE NOT NULL, transformations INT UNSIGNED DEFAULT 0, bandwidth_bytes BIGINT UNSIGNED DEFAULT 0, PRIMARY KEY (id), UNIQUE KEY idx_date (date) ) $charset_collate;\"; dbDelta( $sql_status );","columns":[{"name":"id","type":"BIGINT UNSIGNED","nullable":false,"primary_key":true},{"name":"attachment_id","type":"BIGINT UNSIGNED","nullable":false,"primary_key":false},{"name":"r2_key","type":"VARCHAR(500)","nullable":false,"primary_key":false},{"name":"r2_url","type":"VARCHAR(500)","nullable":false,"primary_key":false},{"name":"local_path","type":"VARCHAR(500)","nullable":false,"primary_key":false},{"name":"local_exists","type":"TINYINT(1)","nullable":true,"primary_key":false},{"name":"file_size","type":"BIGINT UNSIGNED","nullable":true,"primary_key":false},{"name":"offloaded_at","type":"DATETIME","nullable":true,"primary_key":false},{"name":"attachment_id","type":"BIGINT UNSIGNED","nullable":false,"primary_key":false},{"name":"action","type":"ENUM('offload', 'restore', 'delete_local')","nullable":false,"primary_key":false},{"name":"status","type":"ENUM('pending', 'processing', 'completed', 'failed', 'cancelled')","nullable":true,"primary_key":false},{"name":"error_message","type":"TEXT","nullable":true,"primary_key":false},{"name":"created_at","type":"DATETIME","nullable":true,"primary_key":false},{"name":"processed_at","type":"DATETIME","nullable":true,"primary_key":false},{"name":"date","type":"DATE","nullable":false,"primary_key":false},{"name":"transformations","type":"INT UNSIGNED","nullable":true,"primary_key":false},{"name":"bandwidth_bytes","type":"BIGINT UNSIGNED","nullable":true,"primary_key":false}],"plugin":{"slug":"tp-media-offload-edge-cdn","name":"TP Media Offload & Edge CDN","active_installs":0,"version":"1.0.5","wp_org_url":"https://wordpress.org/plugins/tp-media-offload-edge-cdn/"}}