Skip to content

Commit

Permalink
调整GC模式,修复交易所链接
Browse files Browse the repository at this point in the history
  • Loading branch information
ZhangYiQiu committed Sep 9, 2024
1 parent 80f4f8e commit 1f64934
Show file tree
Hide file tree
Showing 8 changed files with 15 additions and 9 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/dotnet-publish-prerelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
release_name: ${{ github.event.repository.name }} ${{ github.ref }}
draft: true
prerelease: true

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/dotnet-publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
release_name: ${{ github.event.repository.name }} ${{ github.ref }}
draft: true
prerelease: false

Expand Down
4 changes: 4 additions & 0 deletions src/TokenPay/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
using Serilog.Events;
using System.Globalization;
using System.Reflection;
using System.Runtime;
using System.Runtime.InteropServices;
using System.Text.Json;
using System.Text.Json.Serialization;
Expand All @@ -32,6 +33,9 @@
Log.Information("CPU CORE: {value}", Environment.ProcessorCount);
Log.Information("HostName: {value}", Environment.MachineName);
Log.Information("Version: {value}", Environment.OSVersion);
Log.Information("IsServerGC: {value}", GCSettings.IsServerGC);
Log.Information("IsConcurrent: {value}", GC.GetGCMemoryInfo().Concurrent);
Log.Information("LatencyMode: {value}", GCSettings.LatencyMode);
Log.Information("-------------{value}-------------", "System Info End");

var builder = WebApplication.CreateBuilder(args);
Expand Down
2 changes: 2 additions & 0 deletions src/TokenPay/TokenPay.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
<IncludeAllContentForSelfExtract>true</IncludeAllContentForSelfExtract>
<JsonSerializerIsReflectionEnabledByDefault>true</JsonSerializerIsReflectionEnabledByDefault>
<TrimMode>partial</TrimMode>
<ServerGarbageCollection>false</ServerGarbageCollection>
</PropertyGroup>

<ItemGroup>
Expand All @@ -21,6 +22,7 @@
<PackageReference Include="FreeSql.Repository" Version="3.2.833" />
<PackageReference Include="HDWallet.Tron" Version="0.7.0" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation" Version="8.0.8" />
<PackageReference Include="Microsoft.Data.Sqlite.Core" Version="8.0.8" />
<PackageReference Include="NokitaKaze.Base58Check" Version="0.4.2" />
<PackageReference Include="Serilog.AspNetCore" Version="8.0.2" />
<PackageReference Include="SkiaSharp.NativeAssets.Linux.NoDependencies" Version="2.88.8" />
Expand Down
4 changes: 2 additions & 2 deletions src/TokenPay/Views/Home/Pay.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ else
</div>
<div class="mt-4 text-start">
<div>区块链货币购买地址</div>
<div>1. 在 <a href="https://www.okx.com/[email protected](chain)/cny" target="_blank">OKX(欧易)</a> 购买 <span class="text-danger">@Model.Currency.ToCurrency(chain)</span></div>
<div>2. 在 <a href="https://p2p.binance.com/zh-CN/express/buy/@Model.Currency.ToCurrency(chain)/CNY" target="_blank">Binance(币安)</a> 购买 <span class="text-danger">@Model.Currency.ToCurrency(chain)</span></div>
<div>1. 在 <a href="https://www.okx.com/buy-crypto#sourceBase=@Model.Currency.ToCurrency(chain)" target="_blank">OKX(欧易)</a> 购买 <span class="text-danger">@Model.Currency.ToCurrency(chain)</span></div>
<div>2. 在 <a href="https://p2p.binance.com/express/buy/@Model.Currency.ToCurrency(chain)" target="_blank">Binance(币安)</a> 购买 <span class="text-danger">@Model.Currency.ToCurrency(chain)</span></div>
</div>
</div>
</div>
Expand Down
4 changes: 2 additions & 2 deletions src/TokenPay/Views/Home/Pay.en.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ else
</div>
<div class="mt-4 text-start">
<div>You can buy blockchain currency at</div>
<div>1. Buy <span class="text-danger">@Model.Currency.ToCurrency(chain)</span> on <a href="https://www.okx.com/[email protected](chain)/UDS" target="_blank">OKX</a></div>
<div>2. Buy <span class="text-danger">@Model.Currency.ToCurrency(chain)</span> on<a href="https://p2p.binance.com/zh-CN/express/buy/@Model.Currency.ToCurrency(chain)/USD" target="_blank">Binance</a></div>
<div>1. Buy <span class="text-danger">@Model.Currency.ToCurrency(chain)</span> on <a href="https://www.okx.com/buy-crypto#sourceBase=@Model.Currency.ToCurrency(chain)" target="_blank">OKX</a></div>
<div>2. Buy <span class="text-danger">@Model.Currency.ToCurrency(chain)</span> on<a href="https://p2p.binance.com/express/buy/@Model.Currency.ToCurrency(chain)" target="_blank">Binance</a></div>
</div>
</div>
</div>
Expand Down
4 changes: 2 additions & 2 deletions src/TokenPay/Views/Home/Pay.ru.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ else
</div>
<div class="mt-4 text-start">
<div>Купить валюту блокчейна на этих сайтах</div>
<div>1. Купить <span class="text-danger">@Model.Currency.ToCurrency(chain)</span> на <a href="https://www.okx.com/[email protected](chain)/cny" target="_blank">OKX</a></div>
<div>2. Купить <span class="text-danger">@Model.Currency.ToCurrency(chain)</span> на <a href="https://p2p.binance.com/zh-CN/express/buy/@Model.Currency.ToCurrency(chain)/CNY" target="_blank">Binance</a></div>
<div>1. Купить <span class="text-danger">@Model.Currency.ToCurrency(chain)</span> на <a href="https://www.okx.com/buy-crypto#sourceBase=@Model.Currency.ToCurrency(chain)" target="_blank">OKX</a></div>
<div>2. Купить <span class="text-danger">@Model.Currency.ToCurrency(chain)</span> на <a href="https://p2p.binance.com/express/buy/@Model.Currency.ToCurrency(chain)" target="_blank">Binance</a></div>
</div>
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion src/TokenPay/appsettings.Example.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
},
"AllowedHosts": "*",
"ConnectionStrings": {
"DB": "Data Source=TokenPay.db; Pooling=true;"
"DB": "Data Source=TokenPay.db;"
},
"TRON-PRO-API-KEY": "xxxxxx-xxxx-xxxx-xxxxxxxxxxxx", // 避免接口请求频繁被限制,此处申请 https://www.trongrid.io/dashboard/keys
"BaseCurrency": "CNY", //默认货币,支持 CNY、USD、EUR、GBP、AUD、HKD、TWD、SGD
Expand Down

0 comments on commit 1f64934

Please sign in to comment.