Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
103 commits
Select commit Hold shift + click to select a range
7d17a58
feat: add Services.Core, config manager, Lua scripting project and te…
tgiachi Jun 22, 2026
4f65c84
feat(udp): make UDP server observable with OnDatagramReceived and tar…
tgiachi Jun 22, 2026
5568534
feat(udp): add UdpSessionManager with per-endpoint sessions and idle-…
tgiachi Jun 22, 2026
882c132
test(udp): add loopback integration test for UDP session lifecycle
tgiachi Jun 22, 2026
4b2f396
feat: add SquidStd bootstrap options
tgiachi Jun 22, 2026
8f0e595
feat: register logger config section
tgiachi Jun 22, 2026
cc29938
feat: add SquidStd bootstrap orchestrator
tgiachi Jun 22, 2026
3c03f22
feat: configure bootstrap logging sinks
tgiachi Jun 22, 2026
017934c
fix(lua): align script engine lifecycle contract
tgiachi Jun 22, 2026
7773146
refactor(bootstrap): align SquidStdBootstrap with code conventions
tgiachi Jun 22, 2026
652ebcc
refactor(lua): replace dynamic constructor wrapper
tgiachi Jun 22, 2026
902a4a5
chore: ignore CodeGraph index
tgiachi Jun 22, 2026
bff33a4
refactor(services): align core and lua services with code conventions
tgiachi Jun 22, 2026
6f66f01
feat(metrics): add core metrics collection service
tgiachi Jun 22, 2026
1daf366
feat(storage): add YAML storage and encrypted secrets
tgiachi Jun 22, 2026
11f6b8d
refactor(bootstrap): simplify SquidStdBootstrap flow
tgiachi Jun 22, 2026
032985c
ci: add Dependabot config and CodeQL code scanning workflow
tgiachi Jun 22, 2026
47f27e3
ci: run CodeQL on develop instead of main
tgiachi Jun 22, 2026
181d04a
ci: bump codeql-action to v4
tgiachi Jun 22, 2026
a8370a8
refactor(bootstrap): use ILogger alias and async log flush on dispose
tgiachi Jun 22, 2026
78bfcf2
feat(messaging): add messaging abstractions (contracts, options, no-o…
tgiachi Jun 22, 2026
89c0cad
feat(messaging): add SquidStd.Messaging project with JSON serializer
tgiachi Jun 22, 2026
4e8ddea
feat(messaging): add MessagingMetricsProvider bridging IMessagingMetr…
tgiachi Jun 22, 2026
583fa26
feat(messaging): add in-memory queue provider with round-robin, retry…
tgiachi Jun 22, 2026
179bce3
feat(messaging): add typed MessageQueue facade over the byte-level pr…
tgiachi Jun 22, 2026
3ce9333
feat(bootstrap): support external DryIoc containers
tgiachi Jun 22, 2026
df3bda0
build(aspnetcore): add SquidStd ASP.NET Core bridge project
tgiachi Jun 22, 2026
74a9e37
feat(messaging): add AddInMemoryMessaging DI registration
tgiachi Jun 22, 2026
321f7a1
feat(aspnetcore): add SquidStd hosted service
tgiachi Jun 22, 2026
ad7cda5
feat(aspnetcore): add WebApplicationBuilder bridge
tgiachi Jun 22, 2026
ec3346f
docs: list SquidStd ASP.NET Core package
tgiachi Jun 22, 2026
3ee159f
Merge branch 'feat/aspnetcore-bridge' into develop
tgiachi Jun 22, 2026
08268cc
feat(database): add SquidStd.Database.Abstractions project skeleton
tgiachi Jun 22, 2026
d9856e9
feat(database): add DatabaseProviderType, BaseEntity and DatabaseConfig
tgiachi Jun 22, 2026
e5b5162
feat(database): add PagedResultData DTO with paging metadata
tgiachi Jun 22, 2026
5b05964
feat(database): add IDataAccess contract
tgiachi Jun 22, 2026
d5f9117
feat(core): add ReplaceEnv regex env-substitution extension
tgiachi Jun 22, 2026
b6b7eab
feat(config): substitute $ENV_VAR tokens in string config values on load
tgiachi Jun 22, 2026
5a2eadf
feat(database): add SquidStd.Database project with FreeSql and ZLinq
tgiachi Jun 22, 2026
8649240
feat(database): add connection-string parser and FreeSql database ser…
tgiachi Jun 22, 2026
676ce91
feat(database): add ZLinq in-memory result helpers
tgiachi Jun 22, 2026
f6db123
chore(solution): organize solution folders
tgiachi Jun 22, 2026
4a73a59
feat(database): add FreeSql data access with bulk ops and transaction…
tgiachi Jun 22, 2026
56a1f61
feat(database): add RegisterDatabase DI extension
tgiachi Jun 22, 2026
a289fef
ci(database): publish SquidStd.Database packages on release
tgiachi Jun 22, 2026
10265e6
ci(database): discover publishable projects via <PublishNuget> property
tgiachi Jun 22, 2026
6aae1cc
Merge branch 'feature/database': FreeSql data layer, IDataAccess, Rep…
tgiachi Jun 22, 2026
bf4f680
refactor(messaging): move shared facade/serializer/metrics into Abstr…
tgiachi Jun 22, 2026
b83bff0
feat(messaging): add scheme-based MessagingConnectionString and in-me…
tgiachi Jun 22, 2026
f3deddb
feat(messaging): add RabbitMq queue provider and registration
tgiachi Jun 22, 2026
48eda72
test(messaging): add RabbitMq integration tests with Testcontainers
tgiachi Jun 22, 2026
4c5b909
docs(convention): use string.Empty instead of "" (align with project …
tgiachi Jun 22, 2026
b296b61
refactor(database): move IDatabaseService under Interfaces/Services n…
tgiachi Jun 22, 2026
bfbebd4
refactor(messaging): organize types into Data.Config/Services/Extensi…
tgiachi Jun 22, 2026
e857bb1
Merge branch 'develop' into feat/messaging-rabbitmq
tgiachi Jun 22, 2026
6510f95
build: adjust NuGet packaging and trim FreeSql providers
tgiachi Jun 22, 2026
b592516
refactor(network): move Dispose/DisposeAsync to end of class per conv…
tgiachi Jun 22, 2026
91d66ce
refactor(messaging-rabbitmq): move RabbitMqOptions into Data.Config n…
tgiachi Jun 22, 2026
ee81bfe
fix(messaging): repair stale usings left by rabbitmq merge (build was…
tgiachi Jun 22, 2026
8a53272
feat(scheduling): add Cronos dependency, ICronScheduler and config/DT…
tgiachi Jun 22, 2026
f9bdafe
test(scheduling): add FakeTimerService and ManualJobSystem test doubles
tgiachi Jun 22, 2026
d43c53e
feat(scheduling): add TimerWheelPumpService to advance the wheel
tgiachi Jun 22, 2026
41e8d07
feat(scheduling): add CronSchedulerService with one-shot rescheduling
tgiachi Jun 22, 2026
a8c05a9
test(scheduling): cover overlap skip, unschedule and handler-exceptio…
tgiachi Jun 22, 2026
aa7574c
test(scheduling): integration test driving the real timer wheel
tgiachi Jun 22, 2026
06dbfac
feat(scheduling): add RegisterSchedulerServices DI extension
tgiachi Jun 22, 2026
3559648
refactor(messaging-rabbitmq): move provider and registration into Ser…
tgiachi Jun 22, 2026
3c6f66d
build: opt projects with a README.md into PackageReadmeFile
tgiachi Jun 22, 2026
fde57c1
docs(core): add NuGet package README
tgiachi Jun 22, 2026
303abfb
docs(abstractions): add NuGet package README
tgiachi Jun 22, 2026
c3f4c1c
docs(services-core): add NuGet package README
tgiachi Jun 22, 2026
7e117f6
docs(network): add NuGet package README
tgiachi Jun 22, 2026
6c44c56
docs(plugin-abstractions): add NuGet package README
tgiachi Jun 22, 2026
1d0ea39
docs(aspnetcore): add NuGet package README
tgiachi Jun 22, 2026
09b7a1b
docs(database-abstractions): add NuGet package README
tgiachi Jun 22, 2026
e87ad01
docs(database): add NuGet package README
tgiachi Jun 22, 2026
571c3c3
feat(packaging): publish Messaging, Messaging.Abstractions, Messaging…
tgiachi Jun 22, 2026
89b9a1c
docs: add full packages index (12 packages) to root README
tgiachi Jun 22, 2026
8bbcdeb
feat(core): add IDataSerializer/IDataDeserializer with JsonDataSerial…
tgiachi Jun 22, 2026
a2bfb0d
refactor(messaging): use unified Core IDataSerializer/IDataDeserializer
tgiachi Jun 22, 2026
8e25a93
feat(caching): add Caching.Abstractions interfaces, options and conne…
tgiachi Jun 22, 2026
3cf20ac
docs(messaging): fix README inaccuracies
tgiachi Jun 22, 2026
81f6276
feat(caching): add CacheMetricsProvider and NoOpCacheMetrics
tgiachi Jun 22, 2026
2b3d0bf
feat(caching): add typed CacheService facade with cache-aside
tgiachi Jun 22, 2026
cde6ea6
feat(caching): add in-memory cache provider and registration
tgiachi Jun 22, 2026
4fdc868
feat(caching): add Redis cache provider and registration
tgiachi Jun 22, 2026
d56818d
test(caching): add Redis integration tests with Testcontainers
tgiachi Jun 22, 2026
3e9ce52
Merge branch 'feat/caching' into develop
tgiachi Jun 22, 2026
ea6d00c
docs(site): scaffold DocFX project (config, images, gitignore)
tgiachi Jun 22, 2026
d238e4b
docs(site): add landing page, top navigation and API intro
tgiachi Jun 22, 2026
4160401
docs(site): add API reference intro page
tgiachi Jun 22, 2026
0086ac9
docs(site): add custom teal theme from the logo palette
tgiachi Jun 22, 2026
055daa2
docs(site): add getting-started and per-package articles (reusing REA…
tgiachi Jun 22, 2026
c2792e1
ci(docs): build and deploy DocFX site to GitHub Pages on main
tgiachi Jun 22, 2026
2e90437
docs(caching): add NuGet package READMEs for the cache module
tgiachi Jun 22, 2026
2aef00b
docs: write a real Overview highlighting bundled utilities (hashing, …
tgiachi Jun 22, 2026
d8c81cc
Merge branch 'feature/docfx-docs': DocFX documentation site + Pages w…
tgiachi Jun 22, 2026
a6fd733
docs(core,network): replace leftover Orion references with SquidStd e…
tgiachi Jun 22, 2026
6ddf606
build(messaging-rabbitmq): bump RabbitMQ.Client to 7.2.1
tgiachi Jun 22, 2026
e47ea3b
docs: expand root README
tgiachi Jun 22, 2026
6159e6c
docs: fix XML doc comment warnings (unqualified StartAsync crefs, dup…
tgiachi Jun 22, 2026
8cd514a
docs(site): add Caching package articles to the DocFX site
tgiachi Jun 22, 2026
9ed263b
docs: add SquidStd.Caching to Quick Start install (snippet verified t…
tgiachi Jun 22, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
version: 2
updates:
- package-ecosystem: "nuget"
directory: "/"
schedule:
interval: "weekly"
open-pull-requests-limit: 10
commit-message:
prefix: "build"
include: "scope"
groups:
dotnet:
patterns:
- "*"

- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
open-pull-requests-limit: 10
commit-message:
prefix: "ci"
include: "scope"
groups:
actions:
patterns:
- "*"
39 changes: 39 additions & 0 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: CodeQL

on:
push:
branches: [ develop ]
pull_request:
branches: [ develop ]
schedule:
- cron: "27 3 * * 1"
workflow_dispatch:

concurrency:
group: codeql-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

permissions:
contents: read
security-events: write

jobs:
analyze:
name: Analyze (C#)
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v5

- name: Initialize CodeQL
uses: github/codeql-action/init@v4
with:
languages: csharp
build-mode: none
queries: security-and-quality

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v4
with:
category: "/language:csharp"
47 changes: 47 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Docs

on:
push:
branches: [ main ]
workflow_dispatch:

permissions:
contents: read
pages: write
id-token: write

concurrency:
group: pages
cancel-in-progress: true

jobs:
build-deploy:
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deploy.outputs.page_url }}
steps:
- uses: actions/checkout@v5

- name: Setup .NET
uses: actions/setup-dotnet@v5
with:
dotnet-version: '10.0.x'

- name: Install DocFX
run: dotnet tool update -g docfx

- name: Build site
run: docfx docs/docfx.json

- name: Configure Pages
uses: actions/configure-pages@v5

- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: docs/_site

- name: Deploy to GitHub Pages
id: deploy
uses: actions/deploy-pages@v4
12 changes: 5 additions & 7 deletions .github/workflows/nuget-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,11 @@ jobs:
- name: Pack publishable packages
run: |
set -euo pipefail
packages=(
"src/SquidStd.Abstractions/SquidStd.Abstractions.csproj"
"src/SquidStd.Core/SquidStd.Core.csproj"
"src/SquidStd.Network/SquidStd.Network.csproj"
"src/SquidStd.Plugin.Abstractions/SquidStd.Plugin.Abstractions.csproj"
"src/SquidStd.Services.Core/SquidStd.Services.Core.csproj"
)
# Discover every project opted-in with <PublishNuget>true</PublishNuget>.
mapfile -t packages < <(grep -ril --include='*.csproj' '<PublishNuget>true</PublishNuget>' src | sort)
if [[ ${#packages[@]} -eq 0 ]]; then
echo "No project has <PublishNuget>true</PublishNuget>"; exit 1
fi
for project in "${packages[@]}"; do
echo "Packing ${project}"
dotnet pack "${project}" -c Release --no-build
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -589,3 +589,6 @@ definitions.lua

dist/
benchmarks/.compare

# CodeGraph local index
.codegraph/
4 changes: 2 additions & 2 deletions CODE_CONVENTION.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ public enum DirectoryType { Scripts, Logs, Plugins, Configs }

## 7. Strings

- Always use `""` instead of `string.Empty`.
- Always use `string.Empty` instead of `""`.

## 8. Logging

Expand Down Expand Up @@ -201,7 +201,7 @@ tests/SquidStd.Tests/Support/FakeSourcePlugin.cs → namespace SquidStd.Tests
- No TODO comments without a tracked follow-up.
- No inconsistent naming across domains.
- Keep warnings under control; do not normalize noisy warnings.
- No `string.Empty` — use `""`.
- No literal `""` — use `string.Empty`.
- No primary constructors.
- No expression-bodied constructors.

Expand Down
8 changes: 8 additions & 0 deletions Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -72,4 +72,12 @@
<None Include="$(MSBuildThisFileDirectory)assets/icon.png" Pack="true" PackagePath="" Visible="false" />
</ItemGroup>

<!-- Package Readme (opt-in per project that ships a README.md) -->
<PropertyGroup Condition="Exists('$(MSBuildProjectDirectory)/README.md')">
<PackageReadmeFile>README.md</PackageReadmeFile>
</PropertyGroup>
<ItemGroup Condition="Exists('$(MSBuildProjectDirectory)/README.md')">
<None Include="README.md" Pack="true" PackagePath="\" Visible="false" />
</ItemGroup>

</Project>
117 changes: 107 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
<p align="center">
<img src="assets/icon.png" alt="SquidStd" width="128" height="128" />
<img src="assets/icon.png" alt="squid-std" width="128" height="128" />
</p>

<h1 align="center">SquidStd</h1>
<h1 align="center">squid-std</h1>

<p align="center">
<img src="https://img.shields.io/badge/.NET-10.0-512BD4.svg" alt=".NET 10" />
<a href="https://github.com/tgiachi/SquidStd/actions/workflows/ci.yml"><img src="https://github.com/tgiachi/SquidStd/actions/workflows/ci.yml/badge.svg" alt="CI" /></a>
<img src="https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/tgiachi/SquidStd/gh-pages/badges/tests.json" alt="tests" />
<img src="https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/tgiachi/SquidStd/gh-pages/badges/coverage.json" alt="coverage" />
Expand All @@ -13,17 +14,96 @@

## Overview

Short description goes here.
**squid-std** is a batteries-included standard library for .NET, distilled from years and years
of building real-world server software. Instead of re-solving the same problems on every project,
it bundles the foundations you reach for again and again behind small, well-defined contracts:

- **Security & hashing** — password hashing and verification (`HashUtils`), AES-GCM secret
protection and a pluggable secret store (`ISecretProtector` / `ISecretStore`).
- **Configuration** — a YAML-backed config manager with section registration and environment-variable expansion.
- **Serialization** — unified JSON/YAML utilities (`JsonUtils`, `YamlUtils`) and a shared `IDataSerializer` / `IDataDeserializer`.
- **String & platform helpers** — case converters (camel/kebab/snake/pascal/…), network, version, platform and resource utilities.
- **Runtime services** — DI bootstrap, event bus, job system, timer/cron scheduler, metrics and storage.
- **Infrastructure modules** — messaging (in-memory + RabbitMQ), caching (in-memory + Redis),
database access, networking (TCP/UDP) and Lua scripting.

Everything is modular: take only the packages you need, each behind a clean abstraction with an
in-memory implementation for tests and an external backend for production.

## Requirements

- [.NET 10 SDK](https://dotnet.microsoft.com/download)
- [Docker](https://www.docker.com/) — only for running the integration tests (Testcontainers spin up RabbitMQ and Redis).

## Quick Start

```bash
dotnet add package SquidStd.Services.Core
dotnet add package SquidStd.Caching
```

```csharp
using SquidStd.Caching.Abstractions.Interfaces;
using SquidStd.Caching.Extensions;
using SquidStd.Services.Core.Services.Bootstrap;

// Create the bootstrapper (registers the core services), then opt into the modules you need.
var bootstrap = SquidStdBootstrap.Create()
.ConfigureServices(container => container.AddInMemoryCache());

await bootstrap.StartAsync();

var cache = bootstrap.Resolve<ICacheService>();
await cache.SetAsync("answer", 42, TimeSpan.FromMinutes(5));
var answer = await cache.GetAsync<int>("answer");

await bootstrap.StopAsync();
```

`SquidStdBootstrap` owns a DryIoc container, wires the core services, and drives the
`StartAsync` / `StopAsync` lifecycle of every registered `ISquidStdService`. Use `RunAsync` to
block until cancellation for long-running hosts.

## Packages

| Package | Version | Downloads |
|---------|---------|-----------|
| `SquidStd.Abstractions` | [![NuGet](https://img.shields.io/nuget/v/SquidStd.Abstractions.svg)](https://www.nuget.org/packages/SquidStd.Abstractions/) | ![Downloads](https://img.shields.io/nuget/dt/SquidStd.Abstractions.svg) |
| `SquidStd.Core` | [![NuGet](https://img.shields.io/nuget/v/SquidStd.Core.svg)](https://www.nuget.org/packages/SquidStd.Core/) | ![Downloads](https://img.shields.io/nuget/dt/SquidStd.Core.svg) |
| `SquidStd.Network` | [![NuGet](https://img.shields.io/nuget/v/SquidStd.Network.svg)](https://www.nuget.org/packages/SquidStd.Network/) | ![Downloads](https://img.shields.io/nuget/dt/SquidStd.Network.svg) |
| `SquidStd.Plugin.Abstractions` | [![NuGet](https://img.shields.io/nuget/v/SquidStd.Plugin.Abstractions.svg)](https://www.nuget.org/packages/SquidStd.Plugin.Abstractions/) | ![Downloads](https://img.shields.io/nuget/dt/SquidStd.Plugin.Abstractions.svg) |
| `SquidStd.Services.Core` | [![NuGet](https://img.shields.io/nuget/v/SquidStd.Services.Core.svg)](https://www.nuget.org/packages/SquidStd.Services.Core/) | ![Downloads](https://img.shields.io/nuget/dt/SquidStd.Services.Core.svg) |
| Package | Description | Links |
|---------|-------------|-------|
| `SquidStd.Core` | Foundational contracts & utilities (config, event bus, jobs, metrics, storage, YAML/JSON, Serilog sink). | [readme](src/SquidStd.Core/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.Core.svg)](https://www.nuget.org/packages/SquidStd.Core/) |
| `SquidStd.Abstractions` | DI registration plumbing (`ISquidStdService`, `RegisterStdService`, `RegisterConfigSection`). | [readme](src/SquidStd.Abstractions/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.Abstractions.svg)](https://www.nuget.org/packages/SquidStd.Abstractions/) |
| `SquidStd.Services.Core` | Concrete services: config, event bus, jobs, timer/cron scheduler, dispatcher, metrics, storage. | [readme](src/SquidStd.Services.Core/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.Services.Core.svg)](https://www.nuget.org/packages/SquidStd.Services.Core/) |
| `SquidStd.AspNetCore` | ASP.NET Core host integration for the SquidStd service stack. | [readme](src/SquidStd.AspNetCore/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.AspNetCore.svg)](https://www.nuget.org/packages/SquidStd.AspNetCore/) |
| `SquidStd.Network` | TCP/UDP servers & clients, sessions, framing/middleware pipeline, span readers/writers. | [readme](src/SquidStd.Network/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.Network.svg)](https://www.nuget.org/packages/SquidStd.Network/) |
| `SquidStd.Plugin.Abstractions` | Plugin contracts (`ISquidStdPlugin`, metadata, context). | [readme](src/SquidStd.Plugin.Abstractions/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.Plugin.Abstractions.svg)](https://www.nuget.org/packages/SquidStd.Plugin.Abstractions/) |
| `SquidStd.Database.Abstractions` | Provider-agnostic data-access contracts (`IDataAccess<T>`, `BaseEntity`, `PagedResultData`). | [readme](src/SquidStd.Database.Abstractions/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.Database.Abstractions.svg)](https://www.nuget.org/packages/SquidStd.Database.Abstractions/) |
| `SquidStd.Database` | FreeSql-backed data access (CRUD/bulk/paging, URI connection strings, ZLinq helpers). | [readme](src/SquidStd.Database/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.Database.svg)](https://www.nuget.org/packages/SquidStd.Database/) |
| `SquidStd.Messaging.Abstractions` | Messaging contracts (`IMessageQueue`, `IQueueProvider`, serializer/metrics, listeners). | [readme](src/SquidStd.Messaging.Abstractions/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.Messaging.Abstractions.svg)](https://www.nuget.org/packages/SquidStd.Messaging.Abstractions/) |
| `SquidStd.Messaging` | In-memory messaging transport (`AddInMemoryMessaging`). | [readme](src/SquidStd.Messaging/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.Messaging.svg)](https://www.nuget.org/packages/SquidStd.Messaging/) |
| `SquidStd.Messaging.RabbitMq` | RabbitMQ messaging transport (`AddRabbitMqMessaging`). | [readme](src/SquidStd.Messaging.RabbitMq/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.Messaging.RabbitMq.svg)](https://www.nuget.org/packages/SquidStd.Messaging.RabbitMq/) |
| `SquidStd.Caching.Abstractions` | Caching contracts (`ICacheService`, `ICacheProvider`, `CacheService` facade, metrics, connection string). | [readme](src/SquidStd.Caching.Abstractions/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.Caching.Abstractions.svg)](https://www.nuget.org/packages/SquidStd.Caching.Abstractions/) |
| `SquidStd.Caching` | In-memory cache backend (`AddInMemoryCache`). | [readme](src/SquidStd.Caching/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.Caching.svg)](https://www.nuget.org/packages/SquidStd.Caching/) |
| `SquidStd.Caching.Redis` | Redis cache backend (`AddRedisCache`). | [readme](src/SquidStd.Caching.Redis/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.Caching.Redis.svg)](https://www.nuget.org/packages/SquidStd.Caching.Redis/) |
| `SquidStd.Scripting.Lua` | Lua scripting engine with attribute-based modules and event bridging. | [readme](src/SquidStd.Scripting.Lua/README.md) · [![NuGet](https://img.shields.io/nuget/v/SquidStd.Scripting.Lua.svg)](https://www.nuget.org/packages/SquidStd.Scripting.Lua/) |

## Architecture

squid-std follows a few consistent principles across every module:

- **KISS** — small, focused types; one class / record / enum per file.
- **Abstractions first** — each capability is split into an `*.Abstractions` package (interfaces,
DTOs, shared facade) plus one or more provider packages. Consumers depend on the abstraction.
- **In-memory + external provider** — every infrastructure module ships an in-memory provider
(great for tests and local dev) and a production backend behind the same interface
(messaging: in-memory / RabbitMQ; caching: in-memory / Redis).
- **DI-driven** — services are registered with DryIoc through `AddXxx(...)` extensions and resolved
through `SquidStdBootstrap`, which manages the `ISquidStdService` lifecycle.
- **Convention over restructure** — interfaces under `Interfaces`, DTOs under `Data`, enums under
`Types`, internals under `Internal`. See [`CODE_CONVENTION.md`](CODE_CONVENTION.md).

## Documentation

Full API documentation is published with DocFX to GitHub Pages:
**[tgiachi.github.io/SquidStd](https://tgiachi.github.io/SquidStd/)**. Each package also ships its
own README (linked in the table above).

## Build

Expand All @@ -37,6 +117,23 @@ dotnet build SquidStd.slnx
dotnet test SquidStd.slnx
```

Integration tests (RabbitMQ, Redis) need Docker running; they use Testcontainers to start
disposable containers automatically.

## Contributing

- Work happens on `develop`; `main` holds released code.
- Use [Conventional Commits](https://www.conventionalcommits.org/) for messages
(`feat:`, `fix:`, `refactor:`, `docs:`, `build:`, `test:`).
- Follow the project conventions in [`CODE_CONVENTION.md`](CODE_CONVENTION.md).
- Add tests for new behaviour and keep the suite green before opening a PR.

## Versioning & Releases

Releases are automated with [semantic-release](https://semantic-release.gitbook.io/): version
numbers and the changelog are derived from the conventional-commit history, and the NuGet packages
are published on release. Package versions follow [Semantic Versioning](https://semver.org/).

## License

MIT - see [LICENSE](LICENSE).
26 changes: 20 additions & 6 deletions SquidStd.slnx
Original file line number Diff line number Diff line change
@@ -1,8 +1,22 @@
<Solution>
<Project Path="src/SquidStd.Abstractions/SquidStd.Abstractions.csproj" />
<Project Path="src/SquidStd.Core/SquidStd.Core.csproj" />
<Project Path="src/SquidStd.Network/SquidStd.Network.csproj" />
<Project Path="src/SquidStd.Plugin.Abstractions/SquidStd.Plugin.Abstractions.csproj" />
<Project Path="src/SquidStd.Services.Core/SquidStd.Services.Core.csproj" />
<Project Path="tests/SquidStd.Tests/SquidStd.Tests.csproj" />
<Folder Name="/src/">
<Project Path="src/SquidStd.Abstractions/SquidStd.Abstractions.csproj" />
<Project Path="src/SquidStd.AspNetCore/SquidStd.AspNetCore.csproj" />
<Project Path="src/SquidStd.Caching.Abstractions/SquidStd.Caching.Abstractions.csproj" />
<Project Path="src/SquidStd.Caching.Redis/SquidStd.Caching.Redis.csproj" />
<Project Path="src/SquidStd.Caching/SquidStd.Caching.csproj" />
<Project Path="src/SquidStd.Core/SquidStd.Core.csproj" />
<Project Path="src/SquidStd.Database.Abstractions/SquidStd.Database.Abstractions.csproj" />
<Project Path="src/SquidStd.Database/SquidStd.Database.csproj" />
<Project Path="src/SquidStd.Messaging.Abstractions/SquidStd.Messaging.Abstractions.csproj" />
<Project Path="src/SquidStd.Messaging.RabbitMq/SquidStd.Messaging.RabbitMq.csproj" />
<Project Path="src/SquidStd.Messaging/SquidStd.Messaging.csproj" />
<Project Path="src/SquidStd.Network/SquidStd.Network.csproj" />
<Project Path="src/SquidStd.Plugin.Abstractions/SquidStd.Plugin.Abstractions.csproj" />
<Project Path="src/SquidStd.Scripting.Lua/SquidStd.Scripting.Lua.csproj" />
<Project Path="src/SquidStd.Services.Core/SquidStd.Services.Core.csproj" />
</Folder>
<Folder Name="/tests/">
<Project Path="tests/SquidStd.Tests/SquidStd.Tests.csproj" />
</Folder>
</Solution>
4 changes: 4 additions & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
_site/
api/*.yml
api/.manifest
obj/
5 changes: 5 additions & 0 deletions docs/api/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# API Reference

Auto-generated reference for all published SquidStd packages, grouped by namespace. Use the sidebar to
browse types and members. Each package's purpose and a usage example are in its
[article](../articles/getting-started.md).
1 change: 1 addition & 0 deletions docs/articles/abstractions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[!include[](../../src/SquidStd.Abstractions/README.md)]
1 change: 1 addition & 0 deletions docs/articles/aspnetcore.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[!include[](../../src/SquidStd.AspNetCore/README.md)]
1 change: 1 addition & 0 deletions docs/articles/caching-abstractions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[!include[](../../src/SquidStd.Caching.Abstractions/README.md)]
1 change: 1 addition & 0 deletions docs/articles/caching-redis.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[!include[](../../src/SquidStd.Caching.Redis/README.md)]
1 change: 1 addition & 0 deletions docs/articles/caching.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[!include[](../../src/SquidStd.Caching/README.md)]
1 change: 1 addition & 0 deletions docs/articles/core.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[!include[](../../src/SquidStd.Core/README.md)]
1 change: 1 addition & 0 deletions docs/articles/database-abstractions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[!include[](../../src/SquidStd.Database.Abstractions/README.md)]
1 change: 1 addition & 0 deletions docs/articles/database.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[!include[](../../src/SquidStd.Database/README.md)]
20 changes: 20 additions & 0 deletions docs/articles/getting-started.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Getting Started

Install the package(s) you need and bootstrap the core services.

```bash
dotnet add package SquidStd.Services.Core
```

```csharp
using DryIoc;
using SquidStd.Services.Core.Extensions;

var container = new Container();

// config manager + event bus + jobs + timer wheel + dispatcher + metrics + storage + secrets
container.RegisterCoreServices("squidstd", Directory.GetCurrentDirectory());
```

From here, add focused packages as needed — see the per-package guides in the sidebar and the
[API reference](../api/index.md).
1 change: 1 addition & 0 deletions docs/articles/messaging-abstractions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[!include[](../../src/SquidStd.Messaging.Abstractions/README.md)]
1 change: 1 addition & 0 deletions docs/articles/messaging-rabbitmq.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[!include[](../../src/SquidStd.Messaging.RabbitMq/README.md)]
1 change: 1 addition & 0 deletions docs/articles/messaging.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[!include[](../../src/SquidStd.Messaging/README.md)]
Loading