Skip to content

Commit 3953f33

Browse files
authored
Revert "- Add Run MCP tool server (#1207)"
This reverts commit fdf9388.
1 parent 69db380 commit 3953f33

File tree

2 files changed

+0
-106
lines changed

2 files changed

+0
-106
lines changed

dotnet/src/dotnetcore/GxNetCoreStartup/RunUtils.cs

Lines changed: 0 additions & 72 deletions
This file was deleted.

dotnet/src/dotnetcore/GxNetCoreStartup/Startup.cs

Lines changed: 0 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -65,9 +65,6 @@ public static void Main(string[] args)
6565
LocatePhysicalLocalPath();
6666

6767
}
68-
69-
MCPTools.ServerStart(Startup.VirtualPath, Startup.LocalPath, schema);
70-
7168
if (port == DEFAULT_PORT)
7269
{
7370
BuildWebHost(null).Run();
@@ -867,37 +864,6 @@ public void Apply(ApplicationModel application)
867864
}
868865
}
869866

870-
static class MCPTools
871-
{
872-
public static void ServerStart(string virtualPath, string workingDir, string schema)
873-
{
874-
IGXLogger log = GXLoggerFactory.GetLogger(typeof(CustomBadRequestObjectResult).FullName);
875-
bool isMpcServer = false;
876-
try
877-
{
878-
List<string> L = Directory.GetFiles(Path.Combine(workingDir,"bin"), "*mcp_service.dll").ToList<string>();
879-
isMpcServer = L.Count > 0;
880-
if (isMpcServer)
881-
{
882-
GXLogging.Info(log, "Start MCP Server");
883-
884-
GxRunner.RunAsync("GxMcpStartup.exe", Path.Combine(workingDir,"bin"), virtualPath, schema, onExit: exitCode =>
885-
{
886-
if (exitCode == 0)
887-
Console.WriteLine("Process completed successfully.");
888-
else
889-
Console.Error.WriteLine($"Process failed (exit code {exitCode})");
890-
});
891-
}
892-
}
893-
catch (Exception ex)
894-
{
895-
GXLogging.Error(log, "Error starting MCP Server", ex);
896-
}
897-
}
898-
}
899-
900-
901867
internal class HomeControllerConvention : IApplicationModelConvention
902868
{
903869
private static bool FindAndStoreDefaultFile()

0 commit comments

Comments
 (0)