fix(ci): Update CI workflows, build scripts, and export configuration

This commit is contained in:
2025-05-12 10:03:22 +00:00
parent e853b2d5e4
commit 9b63777a76
50 changed files with 7188 additions and 1823 deletions

View File

@ -0,0 +1,8 @@
/**
* autocreated commitinfo by @push.rocks/commitinfo
*/
export const commitinfo = {
name: '@push.rocks/smartlog-destination-clickhouse',
version: '1.0.14',
description: 'A library to integrate Smartlog logging with ClickHouse database for efficient log storage and querying.'
}

View File

@ -0,0 +1,30 @@
import * as plugins from './slclick.plugins.js';
export class SmartlogDestinationClickhouse implements plugins.smartlogInterfaces.ILogDestination {
// STATIC
public static async createAndStart(
optionsArg: plugins.smartclickhouse.IClickhouseConstructorOptions
) {
const destinationClickhouse = new SmartlogDestinationClickhouse(optionsArg);
await destinationClickhouse.start();
return destinationClickhouse;
}
// INSTANCE
private smartclickhouseDb: plugins.smartclickhouse.SmartClickHouseDb;
private logTable: plugins.smartclickhouse.TimeDataTable;
constructor(options: plugins.smartclickhouse.IClickhouseConstructorOptions) {
this.smartclickhouseDb = new plugins.smartclickhouse.SmartClickHouseDb(options);
}
public async start() {
await this.smartclickhouseDb.start();
this.logTable = await this.smartclickhouseDb.getTable('logs');
}
public async handleLog(
logPackage: plugins.smartlogInterfaces.ILogPackage<unknown>
): Promise<void> {
await this.logTable.addData(logPackage);
}
}

View File

@ -0,0 +1,5 @@
// pushrocks scope
import * as smartlogInterfaces from '../dist_ts_interfaces/index.js';
import * as smartclickhouse from '@push.rocks/smartclickhouse';
export { smartlogInterfaces, smartclickhouse };