Compare commits

..

No commits in common. "dad8d46e9bdad6e7451db32aba9ba42bca7ee778" and "c0c9b7c9b41b0c7582a5ca25fa28b4042190f498" have entirely different histories.

55 changed files with 330 additions and 378 deletions

View file

@ -33,8 +33,8 @@ static Napi::Object RowIterator(const Napi::CallbackInfo& args) {
static Napi::Object Init(Napi::Env env, Napi::Object exports) {
exports["initSQLite"] = Napi::Function::New(env, _InitSQLite);
exports["rowIterator"] = Napi::Function::New(env, RowIterator);
exports["InitSQLite"] = Napi::Function::New(env, _InitSQLite);
exports["RowIterator"] = Napi::Function::New(env, RowIterator);
return exports;
}

View file

@ -4,18 +4,17 @@ package main
// #include <stdio.h>
import "C"
import (
"fmt"
"strings"
"unsafe"
"l12.xyz/x/dal/pkg/facade"
"github.com/nesterow/dal/pkg/facade"
_ "github.com/mattn/go-sqlite3"
)
var (
iterators = make(map[int]*facade.RowsIter)
itersize = make(map[int]C.int)
)
var iterators = make(map[int]*facade.RowsIter)
var itersize = make(map[int]C.int)
//export InitSQLite
func InitSQLite(pragmas string) {
@ -29,6 +28,7 @@ func CreateRowIterator(input []byte) C.int {
it.Exec(input)
ptr := C.int(len(iterators))
iterators[len(iterators)] = it
defer fmt.Println(ptr)
return ptr
}

View file

@ -2,14 +2,32 @@ module binding
go 1.22.6
replace l12.xyz/x/dal => ../
replace github.com/nesterow/dal/pkg/adapter => ../pkg/adapter
replace github.com/nesterow/dal/pkg/proto => ../pkg/proto
replace github.com/nesterow/dal/pkg/builder => ../pkg/builder
replace github.com/nesterow/dal/pkg/filters => ../pkg/filters
replace github.com/nesterow/dal/pkg/utils => ../pkg/utils
replace github.com/nesterow/dal/pkg/handler => ../pkg/handler
replace github.com/nesterow/dal/pkg/facade => ../pkg/facade
require (
github.com/mattn/go-sqlite3 v1.14.22
l12.xyz/x/dal v0.0.0
github.com/nesterow/dal/pkg/facade v0.0.0-20240820230908-3f75eedbfcb1
)
require (
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181 // indirect
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181 // indirect
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181 // indirect
github.com/nesterow/dal/pkg/handler v0.0.0-20240823050743-ae641b7ee894 // indirect
github.com/nesterow/dal/pkg/proto v0.0.0-20240820230328-f8e28d2a2e42 // indirect
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 // indirect
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/tinylib/msgp v1.2.0 // indirect

View file

@ -1,91 +0,0 @@
/* Code generated by cmd/cgo; DO NOT EDIT. */
/* package command-line-arguments */
#line 1 "cgo-builtin-export-prolog"
#include <stddef.h>
#ifndef GO_CGO_EXPORT_PROLOGUE_H
#define GO_CGO_EXPORT_PROLOGUE_H
#ifndef GO_CGO_GOSTRING_TYPEDEF
typedef struct { const char *p; ptrdiff_t n; } _GoString_;
#endif
#endif
/* Start of preamble from import "C" comments. */
#line 3 "main.go"
#include <stdlib.h>
#include <stdio.h>
#line 1 "cgo-generated-wrapper"
/* End of preamble from import "C" comments. */
/* Start of boilerplate cgo prologue. */
#line 1 "cgo-gcc-export-header-prolog"
#ifndef GO_CGO_PROLOGUE_H
#define GO_CGO_PROLOGUE_H
typedef signed char GoInt8;
typedef unsigned char GoUint8;
typedef short GoInt16;
typedef unsigned short GoUint16;
typedef int GoInt32;
typedef unsigned int GoUint32;
typedef long long GoInt64;
typedef unsigned long long GoUint64;
typedef GoInt64 GoInt;
typedef GoUint64 GoUint;
typedef size_t GoUintptr;
typedef float GoFloat32;
typedef double GoFloat64;
#ifdef _MSC_VER
#include <complex.h>
typedef _Fcomplex GoComplex64;
typedef _Dcomplex GoComplex128;
#else
typedef float _Complex GoComplex64;
typedef double _Complex GoComplex128;
#endif
/*
static assertion to make sure the file is being used on architecture
at least with matching size of GoInt.
*/
typedef char _check_for_64_bit_pointer_matching_GoInt[sizeof(void*)==64/8 ? 1:-1];
#ifndef GO_CGO_GOSTRING_TYPEDEF
typedef _GoString_ GoString;
#endif
typedef void *GoMap;
typedef void *GoChan;
typedef struct { void *t; void *v; } GoInterface;
typedef struct { void *data; GoInt len; GoInt cap; } GoSlice;
#endif
/* End of boilerplate cgo prologue. */
#ifdef __cplusplus
extern "C" {
#endif
extern void InitSQLite(char* params);
extern int CreateRowIterator(char* data, int size);
extern void* NextRow(int itid);
extern int GetLen(int idx);
extern void Cleanup(int itid);
extern void Free(void* ptr);
#ifdef __cplusplus
}
#endif

View file

@ -1,16 +0,0 @@
module l12.xyz/x/dal/clib
go 1.22.6
require (
github.com/mattn/go-sqlite3 v1.14.22
l12.xyz/x/dal v0.0.0
)
require (
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/tinylib/msgp v1.2.0 // indirect
)
replace l12.xyz/x/dal => ../

View file

@ -1,8 +0,0 @@
github.com/mattn/go-sqlite3 v1.14.22 h1:2gZY6PC6kBnID23Tichd1K+Z0oS6nE/XwU+Vz/5o4kU=
github.com/mattn/go-sqlite3 v1.14.22/go.mod h1:Uh1q+B4BYcTPb+yiD3kU8Ct7aC0hY9fxUwlHK0RXw+Y=
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 h1:jYi87L8j62qkXzaYHAQAhEapgukhenIMZRBKTNRLHJ4=
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986/go.mod h1:RqIHx9QI14HlwKwm98g9Re5prTQ6LdeRQn+gXJFxsJM=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/tinylib/msgp v1.2.0 h1:0uKB/662twsVBpYUPbokj4sTSKhWFKB7LopO2kWK8lY=
github.com/tinylib/msgp v1.2.0/go.mod h1:2vIGs3lcUo8izAATNobrCHevYZC/LMsJtw4JPiYPHro=

View file

@ -1,74 +0,0 @@
package main
// #include <stdlib.h>
// #include <stdio.h>
import "C"
import (
"fmt"
"strings"
"unsafe"
"l12.xyz/x/dal/pkg/facade"
_ "github.com/mattn/go-sqlite3"
)
var (
iterators = make(map[int]*facade.RowsIter)
itersize = make(map[int]C.int)
)
//export InitSQLite
func InitSQLite(params *C.char) {
pragmas := C.GoString(params)
pragmasArray := strings.Split(pragmas, ";")
facade.InitSQLite(pragmasArray)
}
//export CreateRowIterator
func CreateRowIterator(data *C.char, size C.int) C.int {
var it = &facade.RowsIter{}
input := C.GoBytes(unsafe.Pointer(data), size)
fmt.Println("input", input)
it.Exec(input)
ptr := C.int(len(iterators))
iterators[len(iterators)] = it
return ptr
}
//export NextRow
func NextRow(itid C.int) unsafe.Pointer {
it := iterators[int(itid)]
if it.Result != nil {
itersize[int(itid)] = C.int(len(it.Result))
return C.CBytes(it.Result)
}
data := it.Next()
if data == nil {
return nil
}
itersize[int(itid)] = C.int(len(data))
res := C.CBytes(data)
return res
}
//export GetLen
func GetLen(idx C.int) C.int {
return itersize[int(idx)]
}
//export Cleanup
func Cleanup(itid C.int) {
it := iterators[int(itid)]
it.Close()
delete(iterators, int(itid))
delete(itersize, int(itid))
}
//export Free
func Free(ptr unsafe.Pointer) {
C.free(ptr)
}
func main() {}

View file

@ -5,7 +5,7 @@ type RowIterator = {
free: () => void;
};
type SQLite = {
initSQLite: (pragmas: Buffer) => void;
rowIterator: (input: Buffer) => RowIterator;
InitSQLite: (pragmas: Buffer) => void;
RowIterator: (input: Buffer) => RowIterator;
};
export default require("../build/Release/dal.node") as SQLite;

View file

@ -1,68 +0,0 @@
/**
* This file is responsible for binding the C library to the Bun runtime.
*/
import { dlopen, FFIType, suffix, ptr, toBuffer } from "bun:ffi";
const libname = `lib/clib.${suffix}`;
const libpath = libname;
const {
symbols: { InitSQLite, CreateRowIterator, NextRow, GetLen, Free, Cleanup },
} = dlopen(libpath, {
InitSQLite: {
args: [FFIType.cstring],
returns: FFIType.void,
},
CreateRowIterator: {
args: [FFIType.cstring, FFIType.i32],
returns: FFIType.i32,
},
NextRow: {
args: [FFIType.i32],
returns: FFIType.ptr,
},
GetLen: {
args: [FFIType.i32],
returns: FFIType.i32,
},
Free: {
args: [FFIType.ptr],
returns: FFIType.void,
},
Cleanup: {
args: [FFIType.i32],
returns: FFIType.void,
},
});
function initSQLite(pragmas: string) {
const buf = Buffer.from(pragmas);
InitSQLite(ptr(buf));
}
function rowIterator(buf: Buffer) {
const iter = CreateRowIterator(ptr(buf), buf.length);
const next = () => {
const pointer = NextRow(iter);
if (pointer === null) {
return null;
}
const buf = toBuffer(pointer, 0, GetLen(iter));
//Free(pointer) //should be resolved by GC;
return buf;
};
const cleanup = () => {
Cleanup(iter);
};
return {
next,
cleanup,
};
}
export default {
initSQLite,
rowIterator,
};

View file

@ -35,10 +35,12 @@ total: ${Mb(this.avg_heapTotal)} Mb`);
}
}
const stats = new Stats();
let prevMem = process.memoryUsage();
stats.add(prevMem);
function MEM(when = "") {
const mem = process.memoryUsage();
stats.add(mem);
@ -50,6 +52,7 @@ buffers: ${Mb(mem.heapUsed)} Mb [delta> ${mem.heapUsed - prevMem.heapUsed}]
total: ${Mb(mem.heapTotal)} Mb [delta> ${mem.heapTotal - prevMem.heapTotal}]`);
}
console.time("Time to end");
MEM("START");

View file

@ -2,14 +2,19 @@ module srv
go 1.22.6
replace l12.xyz/x/dal => ../../../
replace github.com/nesterow/dal/pkg/handler => ../../../pkg/handler
require (
github.com/mattn/go-sqlite3 v1.14.22
l12.xyz/x/dal v0.0.0
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181
github.com/nesterow/dal/pkg/handler v0.0.0-20240820192515-7a408c994181
)
require (
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181 // indirect
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181 // indirect
github.com/nesterow/dal/pkg/proto v0.0.0-20240820192515-7a408c994181 // indirect
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 // indirect
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/tinylib/msgp v1.2.0 // indirect

View file

@ -1,5 +1,15 @@
github.com/mattn/go-sqlite3 v1.14.22 h1:2gZY6PC6kBnID23Tichd1K+Z0oS6nE/XwU+Vz/5o4kU=
github.com/mattn/go-sqlite3 v1.14.22/go.mod h1:Uh1q+B4BYcTPb+yiD3kU8Ct7aC0hY9fxUwlHK0RXw+Y=
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181 h1:wwWMAG/Uu/layF1wu6dJiUej0zisaVQRfyTNqjJpxac=
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181/go.mod h1:TCkoNn14Hgl+iVENr73GHaDVEuAg8KizH0oXaV2qMKs=
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181 h1:Ex2XjUB7o4IRSWcgh8qgac8JQ2gbn6M+jUfom4zZccY=
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181/go.mod h1:mVt1QOFEeGLdi+ZbMLzVw3LVtFB2tYWxZRouhkOThJU=
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181 h1:Vi6v1T68/oayGfoX8k/FpgvfMsCUqxMsowTHKXY70VE=
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181/go.mod h1:6aUr+2+D+184FTSXgziW6r1bvcKTY+Ie3TW4iET0g6I=
github.com/nesterow/dal/pkg/proto v0.0.0-20240820192515-7a408c994181 h1:HcGM9fagbbGa0r/6TRrg+lzRbW79sOr6yTczYkO1miw=
github.com/nesterow/dal/pkg/proto v0.0.0-20240820192515-7a408c994181/go.mod h1:MUS8KEmlNqjUuhNyK4TOkUwjT9893jmNm++ukVz2hzU=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 h1:b/D2uq18D6CzAh+NUyD1cM7s/q/aQZEpXy57iKyzg8k=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181/go.mod h1:0XWmrxZfyoEAZoCOxP3quEOP7ZNK2Lhvtpeux8C74mw=
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 h1:jYi87L8j62qkXzaYHAQAhEapgukhenIMZRBKTNRLHJ4=
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986/go.mod h1:RqIHx9QI14HlwKwm98g9Re5prTQ6LdeRQn+gXJFxsJM=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=

View file

@ -7,8 +7,8 @@ import (
"os/signal"
"syscall"
"l12.xyz/x/dal/pkg/adapter"
"l12.xyz/x/dal/pkg/handler"
"github.com/nesterow/dal/pkg/adapter"
"github.com/nesterow/dal/pkg/handler"
_ "github.com/mattn/go-sqlite3"
)

View file

@ -1,65 +0,0 @@
import Builder from "./Builder";
import Bunding from "./Bunding";
import { encodeRequest, decodeRows, decodeResponse } from "./Protocol";
import type { ExecResult } from "./Protocol";
type Options = {
database: string;
};
/**
* Allows to use SQLite databases in BunJS
*/
export default class CBuilder<
I extends abstract new (...args: any) => any,
> extends Builder<I> {
constructor(opts: Options) {
super({ database: opts.database, url: "" });
}
/**
* TODO: handle responses
*/
async *Rows<T = InstanceType<I>>(): AsyncGenerator<T> {
this.formatRequest();
const req = Buffer.from(encodeRequest(this.request));
const iter = Bunding.rowIterator(req);
for (;;) {
const response = iter.next();
if (response === null) {
iter.cleanup();
break;
}
const rows = decodeRows(response);
if (rows.length === 0) {
iter.cleanup();
break;
}
for (const row of rows) {
if (this.headerRow === null) {
this.headerRow = row.r;
continue;
}
yield this.formatRow(row.r);
}
}
}
async Query<T = InstanceType<I>>(): Promise<T[]> {
const rows = this.Rows();
const result: T[] = [];
for await (const row of rows) {
result.push(row);
}
return result;
}
async Exec(): Promise<ExecResult> {
this.formatRequest();
const req = Buffer.from(encodeRequest(this.request));
const iter = Bunding.rowIterator(req);
const response = iter.next();
if (response === null) {
iter.cleanup();
throw new Error("No response");
}
return decodeResponse(response);
}
}

41
dal/bun.ffi.ts Normal file
View file

@ -0,0 +1,41 @@
import { dlopen, FFIType, suffix, ptr } from "bun:ffi";
import { join } from "node:path";
import fs from "node:fs";
// TODO: build a shared library compatible with cffi
const libname = `libdal-arm64.${suffix}`;
const libpath = join(__dirname, '..', 'lib', libname);
const {
symbols: {
InitSQLite,
CreateRowIterator,
NextRow,
GetLen,
FreeIter,
},
} = dlopen(
libpath,
{
InitSQLite: {
args: [ FFIType.cstring ],
returns: FFIType.void,
},
CreateRowIterator: {
args: [ FFIType.cstring ],
returns: FFIType.i32,
},
NextRow: {
args: [FFIType.i32],
returns: FFIType.cstring,
},
GetLen: {
args: [FFIType.i32],
returns: FFIType.i32,
},
FreeIter : {
args: [FFIType.i32],
returns: FFIType.void,
},
},
);

View file

@ -9,6 +9,7 @@ type Options = {
/**
* Allows to use SQLite databases in a NodeJS process.
* It is less memory-efficient than a seaparate server, and uses absolute path for database name.
*/
export default class CBuilder<
I extends abstract new (...args: any) => any,
@ -22,7 +23,7 @@ export default class CBuilder<
async *Rows<T = InstanceType<I>>(): AsyncGenerator<T> {
this.formatRequest();
const req = Buffer.from(encodeRequest(this.request));
const iter = Binding.rowIterator(req);
const iter = Binding.RowIterator(req);
for (;;) {
const response = iter.next();
const rows = decodeRows(response);
@ -50,7 +51,7 @@ export default class CBuilder<
async Exec(): Promise<ExecResult> {
this.formatRequest();
const req = Buffer.from(encodeRequest(this.request));
const iter = Binding.rowIterator(req);
const iter = Binding.RowIterator(req);
const response = iter.next();
return decodeResponse(response);
}

22
go.mod
View file

@ -1,11 +1,19 @@
module l12.xyz/x/dal
module github.com/nesterow/dal
go 1.22.6
require (
github.com/mattn/go-sqlite3 v1.14.22
github.com/pkg/errors v0.9.1
github.com/tinylib/msgp v1.2.0
)
require github.com/nesterow/dal/pkg/facade v0.0.0-20240823050743-ae641b7ee894
require github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 // indirect
require github.com/mattn/go-sqlite3 v1.14.22
require (
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181 // indirect
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181 // indirect
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181 // indirect
github.com/nesterow/dal/pkg/handler v0.0.0-20240823050743-ae641b7ee894 // indirect
github.com/nesterow/dal/pkg/proto v0.0.0-20240820230328-f8e28d2a2e42 // indirect
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 // indirect
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/tinylib/msgp v1.2.0 // indirect
)

14
go.sum
View file

@ -1,5 +1,19 @@
github.com/mattn/go-sqlite3 v1.14.22 h1:2gZY6PC6kBnID23Tichd1K+Z0oS6nE/XwU+Vz/5o4kU=
github.com/mattn/go-sqlite3 v1.14.22/go.mod h1:Uh1q+B4BYcTPb+yiD3kU8Ct7aC0hY9fxUwlHK0RXw+Y=
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181 h1:wwWMAG/Uu/layF1wu6dJiUej0zisaVQRfyTNqjJpxac=
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181/go.mod h1:TCkoNn14Hgl+iVENr73GHaDVEuAg8KizH0oXaV2qMKs=
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181 h1:Ex2XjUB7o4IRSWcgh8qgac8JQ2gbn6M+jUfom4zZccY=
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181/go.mod h1:mVt1QOFEeGLdi+ZbMLzVw3LVtFB2tYWxZRouhkOThJU=
github.com/nesterow/dal/pkg/facade v0.0.0-20240823050743-ae641b7ee894 h1:MkHuizDCwVhyvVa/9sSBFsX7MiWZQAeOODS50GTe9nU=
github.com/nesterow/dal/pkg/facade v0.0.0-20240823050743-ae641b7ee894/go.mod h1:MKaLSkZocQXy/wFqBzl+Bu7lb4xSCeItbTC7vjOPE0Q=
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181 h1:Vi6v1T68/oayGfoX8k/FpgvfMsCUqxMsowTHKXY70VE=
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181/go.mod h1:6aUr+2+D+184FTSXgziW6r1bvcKTY+Ie3TW4iET0g6I=
github.com/nesterow/dal/pkg/handler v0.0.0-20240823050743-ae641b7ee894 h1:nPlCoVDXzpFGX4cmInLOKoAB7cTpcnjGDevCahF1Db8=
github.com/nesterow/dal/pkg/handler v0.0.0-20240823050743-ae641b7ee894/go.mod h1:aUueTAR2yb5ZCcXqgm4euJTTlScTCqTyT187oNQN5zY=
github.com/nesterow/dal/pkg/proto v0.0.0-20240820230328-f8e28d2a2e42 h1:bUnae1O6MEYWEZepd2ir3iSkydfX9/8DLRoH0U+EWHM=
github.com/nesterow/dal/pkg/proto v0.0.0-20240820230328-f8e28d2a2e42/go.mod h1:YGGcF6rUmoknTFR3csZyLjJhpuFBw9S+DQa61P8B8kY=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 h1:b/D2uq18D6CzAh+NUyD1cM7s/q/aQZEpXy57iKyzg8k=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181/go.mod h1:0XWmrxZfyoEAZoCOxP3quEOP7ZNK2Lhvtpeux8C74mw=
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 h1:jYi87L8j62qkXzaYHAQAhEapgukhenIMZRBKTNRLHJ4=
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986/go.mod h1:RqIHx9QI14HlwKwm98g9Re5prTQ6LdeRQn+gXJFxsJM=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=

View file

@ -1,8 +1,9 @@
package main
import (
"github.com/nesterow/dal/pkg/facade"
_ "github.com/mattn/go-sqlite3"
"l12.xyz/x/dal/pkg/facade"
)
func main() {

View file

@ -1,7 +1,7 @@
{
"name": "@nesterow/dal",
"version": "0.0.2",
"repository": "https://l12.xyz/x/dal.git",
"repository": "https://github.com/nesterow/dal.git",
"publishConfig": {
"registry": "https://npm.pkg.github.com"
},

View file

@ -4,7 +4,7 @@ import (
"fmt"
"testing"
"l12.xyz/x/dal/pkg/adapter"
"github.com/nesterow/dal/pkg/adapter"
_ "github.com/mattn/go-sqlite3"
)

View file

@ -4,8 +4,8 @@ import (
"fmt"
"testing"
"l12.xyz/x/dal/pkg/adapter"
"l12.xyz/x/dal/pkg/builder"
"github.com/nesterow/dal/pkg/adapter"
"github.com/nesterow/dal/pkg/builder"
_ "github.com/mattn/go-sqlite3"
)

View file

@ -2,15 +2,19 @@ module pkg/tests
go 1.22.6
replace l12.xyz/x/dal => ../../
require (
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181
github.com/nesterow/dal/pkg/proto v0.0.0-20240820192515-7a408c994181
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 // indirect
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 // indirect
github.com/tinylib/msgp v1.2.0 // indirect
l12.xyz/x/dal v0.0.0
)
require (
github.com/mattn/go-sqlite3 v1.14.22
github.com/pkg/errors v0.9.1 // indirect
)
require github.com/nesterow/dal/pkg/builder v0.0.0-20240820191021-7dcd046e6ca0
require github.com/nesterow/dal/pkg/filters v0.0.0-20240820191021-7dcd046e6ca0 // indirect

View file

@ -1,5 +1,15 @@
github.com/mattn/go-sqlite3 v1.14.22 h1:2gZY6PC6kBnID23Tichd1K+Z0oS6nE/XwU+Vz/5o4kU=
github.com/mattn/go-sqlite3 v1.14.22/go.mod h1:Uh1q+B4BYcTPb+yiD3kU8Ct7aC0hY9fxUwlHK0RXw+Y=
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181 h1:wwWMAG/Uu/layF1wu6dJiUej0zisaVQRfyTNqjJpxac=
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181/go.mod h1:TCkoNn14Hgl+iVENr73GHaDVEuAg8KizH0oXaV2qMKs=
github.com/nesterow/dal/pkg/builder v0.0.0-20240820191021-7dcd046e6ca0 h1:S37CEWRRLdeLA3V8J4XEa8CmmO4Z+auifYf1GfNRo64=
github.com/nesterow/dal/pkg/builder v0.0.0-20240820191021-7dcd046e6ca0/go.mod h1:EmozdaZEPYE2+4qpK1cw0eIS8yx9LcrVRKstvq2dgCg=
github.com/nesterow/dal/pkg/filters v0.0.0-20240820191021-7dcd046e6ca0 h1:2CDPDKwR+PSGCI6dMbSqI5Zf8Ugg9nY2CMN87BDZ1Xg=
github.com/nesterow/dal/pkg/filters v0.0.0-20240820191021-7dcd046e6ca0/go.mod h1:1wKJbE/13P756EjkLU8xzbdhR+dJYfn6Vlw4J2jFJaA=
github.com/nesterow/dal/pkg/proto v0.0.0-20240820192515-7a408c994181 h1:HcGM9fagbbGa0r/6TRrg+lzRbW79sOr6yTczYkO1miw=
github.com/nesterow/dal/pkg/proto v0.0.0-20240820192515-7a408c994181/go.mod h1:MUS8KEmlNqjUuhNyK4TOkUwjT9893jmNm++ukVz2hzU=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 h1:b/D2uq18D6CzAh+NUyD1cM7s/q/aQZEpXy57iKyzg8k=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181/go.mod h1:0XWmrxZfyoEAZoCOxP3quEOP7ZNK2Lhvtpeux8C74mw=
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 h1:jYi87L8j62qkXzaYHAQAhEapgukhenIMZRBKTNRLHJ4=
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986/go.mod h1:RqIHx9QI14HlwKwm98g9Re5prTQ6LdeRQn+gXJFxsJM=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=

View file

@ -5,8 +5,8 @@ import (
"os"
"testing"
"l12.xyz/x/dal/pkg/adapter"
"l12.xyz/x/dal/pkg/proto"
"github.com/nesterow/dal/pkg/adapter"
"github.com/nesterow/dal/pkg/proto"
_ "github.com/mattn/go-sqlite3"
)

View file

@ -4,7 +4,7 @@ import (
"strconv"
"strings"
"l12.xyz/x/dal/pkg/utils"
"github.com/nesterow/dal/pkg/utils"
)
/*

7
pkg/adapter/go.mod Normal file
View file

@ -0,0 +1,7 @@
module github.com/nesterow/dal/pkg/adapter
go 1.22.6
require github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181
require github.com/pkg/errors v0.9.1 // indirect

4
pkg/adapter/go.sum Normal file
View file

@ -0,0 +1,4 @@
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 h1:b/D2uq18D6CzAh+NUyD1cM7s/q/aQZEpXy57iKyzg8k=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181/go.mod h1:0XWmrxZfyoEAZoCOxP3quEOP7ZNK2Lhvtpeux8C74mw=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=

View file

@ -4,7 +4,7 @@ import (
"fmt"
"strings"
"l12.xyz/x/dal/pkg/utils"
"github.com/nesterow/dal/pkg/utils"
)
func convertConflict(ctx Dialect, fields ...string) string {

View file

@ -4,7 +4,7 @@ import (
"fmt"
"strings"
"l12.xyz/x/dal/pkg/filters"
"github.com/nesterow/dal/pkg/filters"
)
type Values = []interface{}

View file

@ -4,7 +4,7 @@ import (
"fmt"
"strings"
"l12.xyz/x/dal/pkg/utils"
"github.com/nesterow/dal/pkg/utils"
)
func convertGroup(ctx Dialect, keys []string) string {

11
pkg/builder/go.mod Normal file
View file

@ -0,0 +1,11 @@
module github.com/nesterow/dal/pkg/builder
go 1.22.6
require (
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181
)
require github.com/pkg/errors v0.9.1 // indirect

8
pkg/builder/go.sum Normal file
View file

@ -0,0 +1,8 @@
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181 h1:wwWMAG/Uu/layF1wu6dJiUej0zisaVQRfyTNqjJpxac=
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181/go.mod h1:TCkoNn14Hgl+iVENr73GHaDVEuAg8KizH0oXaV2qMKs=
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181 h1:Vi6v1T68/oayGfoX8k/FpgvfMsCUqxMsowTHKXY70VE=
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181/go.mod h1:6aUr+2+D+184FTSXgziW6r1bvcKTY+Ie3TW4iET0g6I=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 h1:b/D2uq18D6CzAh+NUyD1cM7s/q/aQZEpXy57iKyzg8k=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181/go.mod h1:0XWmrxZfyoEAZoCOxP3quEOP7ZNK2Lhvtpeux8C74mw=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=

View file

@ -1,8 +1,8 @@
package builder
import (
"l12.xyz/x/dal/pkg/adapter"
"l12.xyz/x/dal/pkg/filters"
"github.com/nesterow/dal/pkg/adapter"
"github.com/nesterow/dal/pkg/filters"
)
type RawSql = map[string]interface{}

View file

@ -4,8 +4,8 @@ import (
"database/sql"
"reflect"
"l12.xyz/x/dal/pkg/adapter"
"l12.xyz/x/dal/pkg/proto"
"github.com/nesterow/dal/pkg/adapter"
"github.com/nesterow/dal/pkg/proto"
)
var db adapter.DBAdapter

View file

@ -6,8 +6,8 @@ import (
"os"
"strings"
"l12.xyz/x/dal/pkg/adapter"
"l12.xyz/x/dal/pkg/handler"
"github.com/nesterow/dal/pkg/adapter"
"github.com/nesterow/dal/pkg/handler"
)
type SQLiteServer struct {

18
pkg/facade/go.mod Normal file
View file

@ -0,0 +1,18 @@
module github.com/nesterow/dal/pkg/facade
go 1.22.6
require (
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181
github.com/nesterow/dal/pkg/handler v0.0.0-20240823050743-ae641b7ee894
github.com/nesterow/dal/pkg/proto v0.0.0-20240820230328-f8e28d2a2e42
)
require (
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181 // indirect
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181 // indirect
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 // indirect
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/tinylib/msgp v1.2.0 // indirect
)

20
pkg/facade/go.sum Normal file
View file

@ -0,0 +1,20 @@
github.com/mattn/go-sqlite3 v1.14.22 h1:2gZY6PC6kBnID23Tichd1K+Z0oS6nE/XwU+Vz/5o4kU=
github.com/mattn/go-sqlite3 v1.14.22/go.mod h1:Uh1q+B4BYcTPb+yiD3kU8Ct7aC0hY9fxUwlHK0RXw+Y=
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181 h1:wwWMAG/Uu/layF1wu6dJiUej0zisaVQRfyTNqjJpxac=
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181/go.mod h1:TCkoNn14Hgl+iVENr73GHaDVEuAg8KizH0oXaV2qMKs=
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181 h1:Ex2XjUB7o4IRSWcgh8qgac8JQ2gbn6M+jUfom4zZccY=
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181/go.mod h1:mVt1QOFEeGLdi+ZbMLzVw3LVtFB2tYWxZRouhkOThJU=
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181 h1:Vi6v1T68/oayGfoX8k/FpgvfMsCUqxMsowTHKXY70VE=
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181/go.mod h1:6aUr+2+D+184FTSXgziW6r1bvcKTY+Ie3TW4iET0g6I=
github.com/nesterow/dal/pkg/handler v0.0.0-20240823050743-ae641b7ee894 h1:nPlCoVDXzpFGX4cmInLOKoAB7cTpcnjGDevCahF1Db8=
github.com/nesterow/dal/pkg/handler v0.0.0-20240823050743-ae641b7ee894/go.mod h1:aUueTAR2yb5ZCcXqgm4euJTTlScTCqTyT187oNQN5zY=
github.com/nesterow/dal/pkg/proto v0.0.0-20240820230328-f8e28d2a2e42 h1:bUnae1O6MEYWEZepd2ir3iSkydfX9/8DLRoH0U+EWHM=
github.com/nesterow/dal/pkg/proto v0.0.0-20240820230328-f8e28d2a2e42/go.mod h1:YGGcF6rUmoknTFR3csZyLjJhpuFBw9S+DQa61P8B8kY=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 h1:b/D2uq18D6CzAh+NUyD1cM7s/q/aQZEpXy57iKyzg8k=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181/go.mod h1:0XWmrxZfyoEAZoCOxP3quEOP7ZNK2Lhvtpeux8C74mw=
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 h1:jYi87L8j62qkXzaYHAQAhEapgukhenIMZRBKTNRLHJ4=
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986/go.mod h1:RqIHx9QI14HlwKwm98g9Re5prTQ6LdeRQn+gXJFxsJM=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/tinylib/msgp v1.2.0 h1:0uKB/662twsVBpYUPbokj4sTSKhWFKB7LopO2kWK8lY=
github.com/tinylib/msgp v1.2.0/go.mod h1:2vIGs3lcUo8izAATNobrCHevYZC/LMsJtw4JPiYPHro=

View file

@ -3,7 +3,7 @@ package filters
import (
"fmt"
"l12.xyz/x/dal/pkg/utils"
"github.com/nesterow/dal/pkg/utils"
)
type Between struct {

View file

@ -4,7 +4,7 @@ import (
"fmt"
"strings"
"l12.xyz/x/dal/pkg/utils"
"github.com/nesterow/dal/pkg/utils"
)
type In struct {

View file

@ -3,7 +3,7 @@ package filters
import (
"fmt"
"l12.xyz/x/dal/pkg/utils"
"github.com/nesterow/dal/pkg/utils"
)
type NotBetween struct {

View file

@ -4,7 +4,7 @@ import (
"fmt"
"strings"
"l12.xyz/x/dal/pkg/utils"
"github.com/nesterow/dal/pkg/utils"
)
type NotIn struct {

10
pkg/filters/go.mod Normal file
View file

@ -0,0 +1,10 @@
module github.com/nesterow/dal/pkg/filters
go 1.22.6
require github.com/pkg/errors v0.9.1 // indirect
require (
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181
)

6
pkg/filters/go.sum Normal file
View file

@ -0,0 +1,6 @@
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181 h1:wwWMAG/Uu/layF1wu6dJiUej0zisaVQRfyTNqjJpxac=
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181/go.mod h1:TCkoNn14Hgl+iVENr73GHaDVEuAg8KizH0oXaV2qMKs=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 h1:b/D2uq18D6CzAh+NUyD1cM7s/q/aQZEpXy57iKyzg8k=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181/go.mod h1:0XWmrxZfyoEAZoCOxP3quEOP7ZNK2Lhvtpeux8C74mw=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=

View file

@ -1,6 +1,6 @@
package filters
import "l12.xyz/x/dal/pkg/adapter"
import "github.com/nesterow/dal/pkg/adapter"
type DialectOpts = adapter.DialectOpts
type Dialect = adapter.Dialect

View file

@ -4,7 +4,7 @@ import (
"fmt"
"testing"
"l12.xyz/x/dal/pkg/adapter"
"github.com/nesterow/dal/pkg/adapter"
)
type SQLiteContext = adapter.CommonDialect

22
pkg/handler/go.mod Normal file
View file

@ -0,0 +1,22 @@
module github.com/nesterow/dal/pkg/handler
go 1.22.6
require (
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181
github.com/nesterow/dal/pkg/proto v0.0.0-20240820192515-7a408c994181
)
require (
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181 // indirect
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181 // indirect
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 // indirect
)
require (
github.com/mattn/go-sqlite3 v1.14.22
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/tinylib/msgp v1.2.0 // indirect
)

18
pkg/handler/go.sum Normal file
View file

@ -0,0 +1,18 @@
github.com/mattn/go-sqlite3 v1.14.22 h1:2gZY6PC6kBnID23Tichd1K+Z0oS6nE/XwU+Vz/5o4kU=
github.com/mattn/go-sqlite3 v1.14.22/go.mod h1:Uh1q+B4BYcTPb+yiD3kU8Ct7aC0hY9fxUwlHK0RXw+Y=
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181 h1:wwWMAG/Uu/layF1wu6dJiUej0zisaVQRfyTNqjJpxac=
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181/go.mod h1:TCkoNn14Hgl+iVENr73GHaDVEuAg8KizH0oXaV2qMKs=
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181 h1:Ex2XjUB7o4IRSWcgh8qgac8JQ2gbn6M+jUfom4zZccY=
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181/go.mod h1:mVt1QOFEeGLdi+ZbMLzVw3LVtFB2tYWxZRouhkOThJU=
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181 h1:Vi6v1T68/oayGfoX8k/FpgvfMsCUqxMsowTHKXY70VE=
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181/go.mod h1:6aUr+2+D+184FTSXgziW6r1bvcKTY+Ie3TW4iET0g6I=
github.com/nesterow/dal/pkg/proto v0.0.0-20240820192515-7a408c994181 h1:HcGM9fagbbGa0r/6TRrg+lzRbW79sOr6yTczYkO1miw=
github.com/nesterow/dal/pkg/proto v0.0.0-20240820192515-7a408c994181/go.mod h1:MUS8KEmlNqjUuhNyK4TOkUwjT9893jmNm++ukVz2hzU=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 h1:b/D2uq18D6CzAh+NUyD1cM7s/q/aQZEpXy57iKyzg8k=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181/go.mod h1:0XWmrxZfyoEAZoCOxP3quEOP7ZNK2Lhvtpeux8C74mw=
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 h1:jYi87L8j62qkXzaYHAQAhEapgukhenIMZRBKTNRLHJ4=
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986/go.mod h1:RqIHx9QI14HlwKwm98g9Re5prTQ6LdeRQn+gXJFxsJM=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/tinylib/msgp v1.2.0 h1:0uKB/662twsVBpYUPbokj4sTSKhWFKB7LopO2kWK8lY=
github.com/tinylib/msgp v1.2.0/go.mod h1:2vIGs3lcUo8izAATNobrCHevYZC/LMsJtw4JPiYPHro=

View file

@ -5,8 +5,8 @@ import (
"net/http"
"reflect"
"l12.xyz/x/dal/pkg/adapter"
"l12.xyz/x/dal/pkg/proto"
"github.com/nesterow/dal/pkg/adapter"
"github.com/nesterow/dal/pkg/proto"
)
/*

View file

@ -10,8 +10,8 @@ import (
_ "github.com/mattn/go-sqlite3"
"l12.xyz/x/dal/pkg/adapter"
"l12.xyz/x/dal/pkg/proto"
"github.com/nesterow/dal/pkg/adapter"
"github.com/nesterow/dal/pkg/proto"
)
func TestQueryHandler(t *testing.T) {

14
pkg/proto/go.mod Normal file
View file

@ -0,0 +1,14 @@
module github.com/nesterow/dal/pkg/proto
go 1.22.6
require (
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181 // indirect
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/tinylib/msgp v1.2.0
)
require github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 // indirect

14
pkg/proto/go.sum Normal file
View file

@ -0,0 +1,14 @@
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181 h1:wwWMAG/Uu/layF1wu6dJiUej0zisaVQRfyTNqjJpxac=
github.com/nesterow/dal/pkg/adapter v0.0.0-20240820192515-7a408c994181/go.mod h1:TCkoNn14Hgl+iVENr73GHaDVEuAg8KizH0oXaV2qMKs=
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181 h1:Ex2XjUB7o4IRSWcgh8qgac8JQ2gbn6M+jUfom4zZccY=
github.com/nesterow/dal/pkg/builder v0.0.0-20240820192515-7a408c994181/go.mod h1:mVt1QOFEeGLdi+ZbMLzVw3LVtFB2tYWxZRouhkOThJU=
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181 h1:Vi6v1T68/oayGfoX8k/FpgvfMsCUqxMsowTHKXY70VE=
github.com/nesterow/dal/pkg/filters v0.0.0-20240820192515-7a408c994181/go.mod h1:6aUr+2+D+184FTSXgziW6r1bvcKTY+Ie3TW4iET0g6I=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181 h1:b/D2uq18D6CzAh+NUyD1cM7s/q/aQZEpXy57iKyzg8k=
github.com/nesterow/dal/pkg/utils v0.0.0-20240820192515-7a408c994181/go.mod h1:0XWmrxZfyoEAZoCOxP3quEOP7ZNK2Lhvtpeux8C74mw=
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986 h1:jYi87L8j62qkXzaYHAQAhEapgukhenIMZRBKTNRLHJ4=
github.com/philhofer/fwd v1.1.3-0.20240612014219-fbbf4953d986/go.mod h1:RqIHx9QI14HlwKwm98g9Re5prTQ6LdeRQn+gXJFxsJM=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/tinylib/msgp v1.2.0 h1:0uKB/662twsVBpYUPbokj4sTSKhWFKB7LopO2kWK8lY=
github.com/tinylib/msgp v1.2.0/go.mod h1:2vIGs3lcUo8izAATNobrCHevYZC/LMsJtw4JPiYPHro=

View file

@ -6,8 +6,8 @@ import (
"slices"
"strings"
"l12.xyz/x/dal/pkg/adapter"
"l12.xyz/x/dal/pkg/builder"
"github.com/nesterow/dal/pkg/adapter"
"github.com/nesterow/dal/pkg/builder"
)
//go:generate msgp

5
pkg/utils/go.mod Normal file
View file

@ -0,0 +1,5 @@
module github.com/nesterow/dal/pkg/utils
go 1.22.6
require github.com/pkg/errors v0.9.1

2
pkg/utils/go.sum Normal file
View file

@ -0,0 +1,2 @@
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=