Skip to content

Commit

Permalink
AppClient使用Remoting新的客户端架构,代码量减半
Browse files Browse the repository at this point in the history
  • Loading branch information
nnhy committed Jun 25, 2024
1 parent 7559801 commit afeb50e
Show file tree
Hide file tree
Showing 17 changed files with 104 additions and 459 deletions.
14 changes: 7 additions & 7 deletions ClientTest/StarFactoryTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -45,13 +45,13 @@ public void Normal()
var dust = star.Service as AppClient;
Assert.NotNull(dust);

var filter = star.GetValue("_tokenFilter") as TokenHttpFilter;
Assert.NotNull(filter);
Assert.Equal(star.AppId, filter.UserName);
Assert.Equal(star.Secret, filter.Password);
Assert.Equal(filter, (tracer.Client as ApiHttpClient).Filter);
Assert.Equal(filter, (config.Client as ApiHttpClient).Filter);
Assert.Equal(filter, (dust as ApiHttpClient).Filter);
//var filter = star.GetValue("_tokenFilter") as TokenHttpFilter;
//Assert.NotNull(filter);
//Assert.Equal(star.AppId, filter.UserName);
//Assert.Equal(star.Secret, filter.Password);
//Assert.Equal(filter, (tracer.Client as ApiHttpClient).Filter);
//Assert.Equal(filter, (config.Client as ApiHttpClient).Filter);
//Assert.Equal(filter, (dust as ApiHttpClient).Filter);
}

[Fact]
Expand Down
2 changes: 1 addition & 1 deletion DeployAgent/DeployWorker.cs
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
using NewLife;
using NewLife.Model;
using NewLife.Remoting.Clients;
using NewLife.Serialization;
using Stardust;
using Stardust.Models;
using Stardust.Services;

namespace DeployAgent;

Expand Down
2 changes: 1 addition & 1 deletion Plugins/MySqlAgent/BinlogClear.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using NewLife;
using NewLife.Log;
using NewLife.Remoting.Clients;
using NewLife.Threading;
using Stardust.Services;

namespace MySqlAgent;

Expand Down
2 changes: 1 addition & 1 deletion Plugins/MySqlAgent/MySqlPlugin.cs
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
using System.ComponentModel;
using NewLife.Log;
using NewLife.Model;
using NewLife.Remoting.Clients;
using NewLife.Threading;
using Stardust.Plugins;
using Stardust.Services;

namespace MySqlAgent;

Expand Down
1 change: 1 addition & 0 deletions StarAgent/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
using NewLife.Model;
using NewLife.Reflection;
using NewLife.Remoting;
using NewLife.Remoting.Clients;
using NewLife.Serialization;
using NewLife.Threading;
using Stardust;
Expand Down
Loading

0 comments on commit afeb50e

Please sign in to comment.