Skip to content

Commit 710c68e

Browse files
committed
chore: fix Sdk package inclusion and Docker testing infrastructure
- Add RecurPixel.Notify.Sdk project to solution file - Add build configuration for Sdk meta-package - Update Dockerfile to use latest .NET SDK (supports .NET 10.0) - Verify all 35 packages pack successfully - Docker workflow validation complete
1 parent 326d039 commit 710c68e

15 files changed

Lines changed: 790 additions & 36 deletions

Directory.Build.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
<!-- NuGet package metadata -->
1010
<PropertyGroup>
1111
<!-- Versioning -->
12-
<Version>0.2.0-beta.2</Version>
12+
<Version>0.2.0</Version>
1313
<AssemblyVersion>0.2.0.0</AssemblyVersion>
1414
<FileVersion>0.2.0.0</FileVersion>
1515

Dockerfile.test

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# Test workflow locally - mimics GitHub Actions ubuntu-latest environment
2+
FROM mcr.microsoft.com/dotnet/sdk:latest
3+
4+
WORKDIR /workspace
5+
6+
# Copy entire project
7+
COPY . .
8+
9+
# Restore deps
10+
RUN dotnet restore
11+
12+
# Build Release
13+
RUN dotnet build --configuration Release --no-restore
14+
15+
# Run tests
16+
RUN dotnet test --configuration Release --no-build --verbosity normal
17+
18+
# Clean and pack NuGet packages
19+
RUN rm -rf ./nupkgs && mkdir -p ./nupkgs && \
20+
dotnet pack --configuration Release --no-restore --output ./nupkgs
21+
22+
# Verify all 35 packages were created
23+
RUN echo "📦 Checking packed packages..." && \
24+
nupkg_count=$(find ./nupkgs -name "*.nupkg" ! -name "*.snupkg" | wc -l) && \
25+
echo "Total .nupkg files: $nupkg_count" && \
26+
if [ "$nupkg_count" -ne 35 ]; then \
27+
echo "❌ ERROR: Expected 35 packages, found $nupkg_count" && \
28+
echo "" && \
29+
echo "Packages found:" && \
30+
find ./nupkgs -name "*.nupkg" ! -name "*.snupkg" | sort | nl && \
31+
exit 1; \
32+
fi && \
33+
echo "✅ All 35 packages present!" && \
34+
echo "" && \
35+
echo "📋 Final Package List:" && \
36+
find ./nupkgs -name "*.nupkg" ! -name "*.snupkg" -type f | sort | nl && \
37+
echo "" && \
38+
total_size=$(du -sh ./nupkgs | cut -f1) && \
39+
echo "📊 Total package size: $total_size"
40+
41+
# Keep container alive for inspection
42+
CMD ["/bin/bash"]

README.md

Lines changed: 54 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ A modular, DI-native NuGet notification library for ASP.NET Core. Drop it in. Br
55
[![NuGet](https://img.shields.io/nuget/v/RecurPixel.Notify.Sdk)](https://www.nuget.org/packages/RecurPixel.Notify.Sdk)
66
[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
77

8+
**✅ v0.2.0 STABLE** — Production-ready with 35+ adapters across 13+ channels
9+
810
---
911

1012
## What It Is
@@ -16,29 +18,9 @@ RecurPixel.Notify is a pure .NET library — not a platform, not SaaS, no extern
1618

1719
---
1820

19-
## Install
20-
21-
```bash
22-
# Full SDK — everything included
23-
dotnet add package RecurPixel.Notify.Sdk
24-
25-
# Or install only what you need
26-
dotnet add package RecurPixel.Notify
27-
dotnet add package RecurPixel.Notify.Email.SendGrid
28-
dotnet add package RecurPixel.Notify.Sms.Twilio
29-
```
30-
31-
[Getting Started](https://recurpixel.github.io/Notify/getting-started) · [Quick Start](https://recurpixel.github.io/Notify/quick-start) · [Usage Tiers](https://recurpixel.github.io/Notify/usage-tiers) · [Adapter Reference](https://recurpixel.github.io/Notify/adapters)
32-
33-
> **⚠️ Upgrading from v0.1.0-beta.1?**
34-
> v0.2.0 includes breaking changes: namespace reorganization, new meta-package structure, typed `TriggerResult` returns, and explicit `UseHandler` for InApp channels.
35-
> **→ See the [Migration Guide](https://recurpixel.github.io/Notify#migration-from-v010-beta1)** for step-by-step upgrade instructions.
36-
>
37-
> **Upgrading from v0.2.0-beta.1?** Install v0.2.0-beta.2 as a drop-in replacement — no API changes, CI fix only.
38-
39-
---
21+
## Adapter Coverage & Test Matrix
4022

41-
## Adapter Status
23+
All adapters are unit-tested. The table below shows which have integration testing (real API verification) and community usage. This matrix validates the **"stable" label** — you're not betting on guesses.
4224

4325
| Package | Provider | Channel | Unit Tested | Integration Tested | Community Approved |
4426
| ---------------------- | --------------------------------- | --------- | ----------- | ------------------ | ------------------ |
@@ -78,6 +60,26 @@ dotnet add package RecurPixel.Notify.Sms.Twilio
7860

7961
---
8062

63+
## Install
64+
65+
```bash
66+
# Full SDK — everything included
67+
dotnet add package RecurPixel.Notify.Sdk
68+
69+
# Or install only what you need
70+
dotnet add package RecurPixel.Notify
71+
dotnet add package RecurPixel.Notify.Email.SendGrid
72+
dotnet add package RecurPixel.Notify.Sms.Twilio
73+
```
74+
75+
[Getting Started](https://recurpixel.github.io/Notify/getting-started) · [Quick Start](https://recurpixel.github.io/Notify/quick-start) · [Usage Tiers](https://recurpixel.github.io/Notify/usage-tiers) · [Adapter Reference](https://recurpixel.github.io/Notify/adapters)
76+
77+
> **⚠️ Upgrading from v0.1.0-beta.1?**
78+
> v0.2.0 includes breaking changes: namespace reorganization, new meta-package structure, typed `TriggerResult` returns, and explicit `UseHandler` for InApp channels.
79+
> **→ See the [Migration Guide](https://recurpixel.github.io/Notify#migration-from-v010-beta1)** for step-by-step upgrade instructions.
80+
81+
---
82+
8183
## Design Principles
8284

8385
- **Zero infrastructure** — pure library, no platform to host or sign up for
@@ -89,6 +91,36 @@ dotnet add package RecurPixel.Notify.Sms.Twilio
8991

9092
---
9193

94+
## What's Coming in v0.3.0
95+
96+
### Dashboard Package (`RecurPixel.Notify.Dashboard`)
97+
98+
A new observability package for delivery tracking and troubleshooting, built with a **data-first approach**: data layer solidified first, REST API second, UI last.
99+
100+
**Key Features:**
101+
- **NotificationLog Entity & INotificationLogStore** — Pluggable persistence (SQL Server, PostgreSQL, SQLite, custom)
102+
- **OnDelivery Hook Integration** — Logs automatically captured for every delivery
103+
- **BulkBatchId Grouping** — Track all notifications in a bulk send as a unit (requires minor Orchestrator update to `BulkTriggerAsync`)
104+
- **REST API** — Query logs, filter by channel/status/date, retrieve retry history, view batch history
105+
- **Embedded HTML Dashboard** — Real-time logs table, channel status breakdown, failure histogram, live send testing
106+
107+
**Why This Order Matters:**
108+
Dashboard development follows strict phases — UI is built last, not first. Data accuracy is verified before any visualization. See [v0.3.0 implementation plan](changelogs/v0.3.0-DASHBOARD-PLAN.md) for detailed build order.
109+
110+
### Adapter Improvements
111+
112+
- **Circuit Breaker Pattern** — Auto-disable broken channels without code changes
113+
- **Community Adapter Approval** — Peer-reviewed providers earn 🟢 status
114+
- **Adapter Analytics** — Success/failure rate tracking per provider (feeds Dashboard)
115+
116+
### Developer Experience
117+
118+
- **Scheduled Send** — Send notifications at future times
119+
- **Template Engine** — Inline or database-backed notification templates
120+
- **OpenTelemetry Integration** — Full distributed tracing for all channels
121+
122+
---
123+
92124
## License
93125

94126
MIT — see [LICENSE](LICENSE).

RecurPixel.Notify.sln

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RecurPixel.Notify.Mattermos
7777
EndProject
7878
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RecurPixel.Notify.RocketChat", "src\RecurPixel.Notify.RocketChat\RecurPixel.Notify.RocketChat.csproj", "{CEC70B25-DF75-45EE-92EC-7E20ECA2E8F6}"
7979
EndProject
80+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RecurPixel.Notify.Sdk", "src\RecurPixel.Notify.Sdk\RecurPixel.Notify.Sdk.csproj", "{F1A2B3C4-D5E6-7890-ABCD-EF1234567891}"
81+
EndProject
8082
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RecurPixel.Notify.IntegrationTests", "tests\RecurPixel.Notify.IntegrationTests\RecurPixel.Notify.IntegrationTests.csproj", "{CBEEA7AA-DE71-4773-8A55-F3483184E647}"
8183
EndProject
8284
Global
@@ -497,6 +499,18 @@ Global
497499
{CEC70B25-DF75-45EE-92EC-7E20ECA2E8F6}.Release|x64.Build.0 = Release|Any CPU
498500
{CEC70B25-DF75-45EE-92EC-7E20ECA2E8F6}.Release|x86.ActiveCfg = Release|Any CPU
499501
{CEC70B25-DF75-45EE-92EC-7E20ECA2E8F6}.Release|x86.Build.0 = Release|Any CPU
502+
{F1A2B3C4-D5E6-7890-ABCD-EF1234567891}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
503+
{F1A2B3C4-D5E6-7890-ABCD-EF1234567891}.Debug|Any CPU.Build.0 = Debug|Any CPU
504+
{F1A2B3C4-D5E6-7890-ABCD-EF1234567891}.Debug|x64.ActiveCfg = Debug|Any CPU
505+
{F1A2B3C4-D5E6-7890-ABCD-EF1234567891}.Debug|x64.Build.0 = Debug|Any CPU
506+
{F1A2B3C4-D5E6-7890-ABCD-EF1234567891}.Debug|x86.ActiveCfg = Debug|Any CPU
507+
{F1A2B3C4-D5E6-7890-ABCD-EF1234567891}.Debug|x86.Build.0 = Debug|Any CPU
508+
{F1A2B3C4-D5E6-7890-ABCD-EF1234567891}.Release|Any CPU.ActiveCfg = Release|Any CPU
509+
{F1A2B3C4-D5E6-7890-ABCD-EF1234567891}.Release|Any CPU.Build.0 = Release|Any CPU
510+
{F1A2B3C4-D5E6-7890-ABCD-EF1234567891}.Release|x64.ActiveCfg = Release|Any CPU
511+
{F1A2B3C4-D5E6-7890-ABCD-EF1234567891}.Release|x64.Build.0 = Release|Any CPU
512+
{F1A2B3C4-D5E6-7890-ABCD-EF1234567891}.Release|x86.ActiveCfg = Release|Any CPU
513+
{F1A2B3C4-D5E6-7890-ABCD-EF1234567891}.Release|x86.Build.0 = Release|Any CPU
500514
{CBEEA7AA-DE71-4773-8A55-F3483184E647}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
501515
{CBEEA7AA-DE71-4773-8A55-F3483184E647}.Debug|Any CPU.Build.0 = Debug|Any CPU
502516
{CBEEA7AA-DE71-4773-8A55-F3483184E647}.Debug|x64.ActiveCfg = Debug|Any CPU
@@ -561,6 +575,7 @@ Global
561575
{2317CA65-B593-4F73-9C7C-C2D56B647F23} = {827E0CD3-B72D-47B6-A68D-7590B98EB39B}
562576
{CEC70B25-DF75-45EE-92EC-7E20ECA2E8F6} = {827E0CD3-B72D-47B6-A68D-7590B98EB39B}
563577
{A1B2C3D4-E5F6-7890-ABCD-EF1234567890} = {827E0CD3-B72D-47B6-A68D-7590B98EB39B}
578+
{F1A2B3C4-D5E6-7890-ABCD-EF1234567891} = {827E0CD3-B72D-47B6-A68D-7590B98EB39B}
564579
{CBEEA7AA-DE71-4773-8A55-F3483184E647} = {0AB3BF05-4346-4AA6-1389-037BE0695223}
565580
EndGlobalSection
566581
EndGlobal

WORKFLOW-TESTING.md

Lines changed: 118 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,118 @@
1+
# Workflow Testing Guide
2+
3+
## Local NuGet Publish Workflow Validation
4+
5+
Test the GitHub Actions workflow **locally in Docker** before pushing to GitHub and creating a release.
6+
7+
### What Gets Tested
8+
9+
-`.NET dependency restoration`
10+
-`Release build` with all 35 projects
11+
-`Unit tests` execution
12+
-**All 35 NuGet packages are created** (including the critical Sdk meta-package)
13+
- ✅ Package naming and versioning
14+
- ✅ Meta-package configuration (`<IncludeBuildOutput>`, `<IsPackable>`)
15+
16+
### Prerequisites
17+
18+
- **Docker Desktop** (Windows/Mac) or **Docker CLI** (Linux)
19+
- [Install Docker Desktop](https://www.docker.com/products/docker-desktop)
20+
21+
### How to Run
22+
23+
#### **Windows**
24+
```cmd
25+
.\test-workflow.bat
26+
```
27+
28+
#### **macOS / Linux**
29+
```bash
30+
chmod +x test-workflow.sh
31+
./test-workflow.sh
32+
```
33+
34+
### What Happens
35+
36+
1. **Builds** a Docker image based on Ubuntu with .NET 8 SDK
37+
2. **Restores** NuGet dependencies
38+
3. **Builds** the entire solution in Release mode
39+
4. **Runs** all unit tests
40+
5. **Packs** NuGet packages to `./nupkgs/`
41+
6. **Validates** that exactly 35 `.nupkg` files were created
42+
7. **Reports** final package list and total size
43+
44+
### Expected Output
45+
46+
```
47+
📦 Checking packed packages...
48+
Total .nupkg files: 35
49+
✅ All 35 packages present!
50+
51+
📋 Final Package List:
52+
1 RecurPixel.Notify.Core.0.2.0.nupkg
53+
2 RecurPixel.Notify.Orchestrator.0.2.0.nupkg
54+
3 RecurPixel.Notify.0.2.0.nupkg
55+
4 RecurPixel.Notify.Email.SendGrid.0.2.0.nupkg
56+
5 RecurPixel.Notify.Email.Smtp.0.2.0.nupkg
57+
...
58+
35 RecurPixel.Notify.Sdk.0.2.0.nupkg
59+
60+
✅ Docker build successful!
61+
📤 Workflow validation complete. Ready to publish!
62+
```
63+
64+
### If Tests Fail
65+
66+
**Missing packages?**
67+
- Check the `.csproj` files for `<IsPackable>true</IsPackable>` property
68+
- Verify project references in SDK meta-packages are correct
69+
- Run `dotnet list nuget-package` to inspect dependencies
70+
71+
**Build errors?**
72+
- Verify .NET 8 SDK is installed locally: `dotnet --version`
73+
- Check that all projects compile: `dotnet build --configuration Release`
74+
75+
**Test failures?**
76+
- Run tests locally first: `dotnet test --configuration Release`
77+
- Check GitHub Actions workflow logs for integration test requirements
78+
79+
### Inspecting Packages
80+
81+
After a successful test, inspect the generated packages:
82+
83+
**List packages:**
84+
```bash
85+
docker run --rm -v $(pwd)/nupkgs:/workspace/nupkgs recurpixel-notify-test:latest ls -lah nupkgs/
86+
```
87+
88+
**Extract and inspect a package:**
89+
```bash
90+
cd nupkgs
91+
unzip RecurPixel.Notify.Sdk.0.2.0.nupkg -d RecurPixel.Notify.Sdk.inspect
92+
cat RecurPixel.Notify.Sdk.inspect/.nuspec
93+
```
94+
95+
### Pre-Push Checklist
96+
97+
- [ ] Run `./test-workflow.bat` (or `.sh`)
98+
- [ ] All 35 packages created successfully
99+
- [ ] No build or test errors
100+
- [ ] Version number matches your release tag (e.g., `0.2.0`)
101+
- [ ] Review `./nupkgs/` directory for size anomalies
102+
103+
**Then:** Push to GitHub and create a release.
104+
105+
### GitHub Actions Workflow File
106+
107+
The actual CI/CD workflow is defined in:
108+
- [.github/workflows/publish-nuget.yml](../.github/workflows/publish-nuget.yml)
109+
110+
It uses:
111+
- 5-tier dependency ordering (Core → Orchestrator → Main → Adapters → SDK)
112+
- 120s waits between tiers for NuGet indexing
113+
- Automated GitHub Release asset uploads
114+
115+
---
116+
117+
**Questions?**
118+
See [PUBLISHING.md](./PUBLISHING.md) for the full release guide.

0 commit comments

Comments
 (0)