Skip to content

More config, more tests#5

Merged
jsneedles merged 1 commit into
mainfrom
more_config
Apr 13, 2026
Merged

More config, more tests#5
jsneedles merged 1 commit into
mainfrom
more_config

Conversation

@jsneedles

Copy link
Copy Markdown
Member

Some more config options (mainly for local/staging development)

  • Allows overriding the hcti.io default host with an environment variable .... but again, nobody should do this 😄
  • Adds a new DI extension for using an already injected service when configuring the HCTI options
  • Cleans up the repetitive validation in the DI extensions
  • Adds more tests for the changed host url stuff

@github-actions

github-actions Bot commented Apr 13, 2026

Copy link
Copy Markdown

Test results

89 tests   89 ✅  0s ⏱️
 1 suites   0 💤
 1 files     0 ❌

Results for commit 099be88.

♻️ This comment has been updated with latest results.

@github-actions

Copy link
Copy Markdown

Benchmark Results

HtmlCssToImage.Benchmarks.Benchmarks.HmacBenchmark


BenchmarkDotNet v0.15.8, Linux Ubuntu 24.04.4 LTS (Noble Numbat)
AMD EPYC 7763 2.45GHz, 1 CPU, 4 logical and 2 physical cores
.NET SDK 10.0.201
  [Host]  : .NET 10.0.5 (10.0.5, 10.0.526.15411), X64 RyuJIT x86-64-v3
  .NET 10 : .NET 10.0.5 (10.0.5, 10.0.526.15411), X64 RyuJIT x86-64-v3

Job=.NET 10  EnvironmentVariables=DOTNET_TieredPGO=0  Runtime=.NET 10.0  
Server=True  MaxIterationCount=20  MaxWarmupIterationCount=5  
MinWarmupIterationCount=2  

Method Mean Error StdDev Ratio Gen0 Allocated Alloc Ratio
Hmac_Standard_Instance 2.049 μs 0.0099 μs 0.0087 μs 1.00 0.0648 696 B 1.00
HCTI_HmacToken_Optimized 1.831 μs 0.0035 μs 0.0029 μs 0.89 0.0191 152 B 0.22

HtmlCssToImage.Benchmarks.Benchmarks.MakeAuthHeaderBenchmark


BenchmarkDotNet v0.15.8, Linux Ubuntu 24.04.4 LTS (Noble Numbat)
AMD EPYC 7763 2.45GHz, 1 CPU, 4 logical and 2 physical cores
.NET SDK 10.0.201
  [Host]  : .NET 10.0.5 (10.0.5, 10.0.526.15411), X64 RyuJIT x86-64-v3
  .NET 10 : .NET 10.0.5 (10.0.5, 10.0.526.15411), X64 RyuJIT x86-64-v3

Job=.NET 10  EnvironmentVariables=DOTNET_TieredPGO=0  Runtime=.NET 10.0  
Server=True  MaxIterationCount=20  MaxWarmupIterationCount=5  
MinWarmupIterationCount=2  

Method Mean Error StdDev Ratio RatioSD Gen0 Allocated Alloc Ratio
AuthHeader_Standard_StringFormat 90.23 ns 1.224 ns 1.085 ns 1.00 0.02 0.0366 376 B 1.00
HCTI_AuthHeader_Optimized 82.44 ns 0.823 ns 0.770 ns 0.91 0.01 0.0221 168 B 0.45

HtmlCssToImage.Benchmarks.Benchmarks.QueryStringEncoderBenchmark


BenchmarkDotNet v0.15.8, Linux Ubuntu 24.04.4 LTS (Noble Numbat)
AMD EPYC 7763 2.45GHz, 1 CPU, 4 logical and 2 physical cores
.NET SDK 10.0.201
  [Host]  : .NET 10.0.5 (10.0.5, 10.0.526.15411), X64 RyuJIT x86-64-v3
  .NET 10 : .NET 10.0.5 (10.0.5, 10.0.526.15411), X64 RyuJIT x86-64-v3

Job=.NET 10  EnvironmentVariables=DOTNET_TieredPGO=0  Runtime=.NET 10.0  
Server=True  MaxIterationCount=20  MaxWarmupIterationCount=5  
MinWarmupIterationCount=2  

Method Mean Error StdDev Ratio Gen0 Allocated Alloc Ratio
BuiltIn_HttpUtility 1.165 μs 0.0104 μs 0.0097 μs 1.00 0.2937 2976 B 1.00
HCTI_QueryStringEncoder 1.107 μs 0.0095 μs 0.0089 μs 0.95 0.1450 744 B 0.25

HtmlCssToImage.Benchmarks.Benchmarks.TemplateListUrlBenchmark


BenchmarkDotNet v0.15.8, Linux Ubuntu 24.04.4 LTS (Noble Numbat)
AMD EPYC 7763 2.45GHz, 1 CPU, 4 logical and 2 physical cores
.NET SDK 10.0.201
  [Host]  : .NET 10.0.5 (10.0.5, 10.0.526.15411), X64 RyuJIT x86-64-v3
  .NET 10 : .NET 10.0.5 (10.0.5, 10.0.526.15411), X64 RyuJIT x86-64-v3

Job=.NET 10  EnvironmentVariables=DOTNET_TieredPGO=0  Runtime=.NET 10.0  
Server=True  MaxIterationCount=20  MaxWarmupIterationCount=5  
MinWarmupIterationCount=2  

Method templateId nextPageStart Mean Error StdDev Ratio Gen0 Allocated Alloc Ratio
Basic ? ? 69.14 ns 0.253 ns 0.211 ns 1.00 0.0168 128 B 1.00
Optimized ? ? 24.38 ns 0.065 ns 0.058 ns 0.35 0.0084 64 B 0.50
Basic t-daa(...)2efe6 [38] ? 87.75 ns 0.363 ns 0.303 ns 1.00 0.0389 312 B 1.00
Optimized t-daa(...)2efe6 [38] ? 28.80 ns 0.595 ns 0.528 ns 0.33 0.0140 144 B 0.46
Basic t-daa(...)2efe6 [38] 1735689600 81.00 ns 0.308 ns 0.273 ns 1.00 0.0290 296 B 1.00
Optimized t-daa(...)2efe6 [38] 1735689600 41.54 ns 0.304 ns 0.285 ns 0.51 0.0186 192 B 0.65

@jsneedles jsneedles merged commit dafa6ab into main Apr 13, 2026
9 checks passed
@jsneedles jsneedles deleted the more_config branch April 13, 2026 19:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant