#feature: add AI log analysis & some bugfix
This commit is contained in:
@@ -0,0 +1,39 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('log_analysis_reports', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->timestamp('from_time');
|
||||
$table->timestamp('to_time');
|
||||
$table->string('query', 1000)->nullable();
|
||||
$table->string('mode', 20);
|
||||
$table->integer('total_logs');
|
||||
$table->json('results');
|
||||
$table->json('metadata')->nullable();
|
||||
$table->string('status', 20)->default('completed');
|
||||
$table->text('error_message')->nullable();
|
||||
$table->timestamps();
|
||||
|
||||
$table->index(['from_time', 'to_time']);
|
||||
$table->index('status');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('log_analysis_reports');
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user