mirror of
https://gitee.com/wujiawei1207537021/wu-lazy-cloud-network.git
synced 2026-02-04 15:05:54 +08:00
[add] 删除namespace规则
This commit is contained in:
@@ -83,12 +83,9 @@ public class NettyHttpProxyHandler extends ChannelInboundHandlerAdapter {
|
||||
|
||||
|
||||
ProxyRoute route = RouteContext.getRoute(originHost, String.valueOf(originPort));
|
||||
String namespace = route.getNamespace();
|
||||
proxyMsg.setVisitorId(visitorId);
|
||||
proxyMsg.setData(bytes);
|
||||
|
||||
proxyMsg.setNamespace(namespace);
|
||||
|
||||
if(ObjectUtils.isEmpty(route)){
|
||||
// 本地代理
|
||||
proxyMsg.setType(ProxyMessageType.HTTP_LOCAL_PROXY);
|
||||
|
||||
@@ -69,8 +69,6 @@ public class NettySocks5CommandRequestHandler extends SimpleChannelInboundHandle
|
||||
proxyMsg.setTargetIp(originHost);
|
||||
proxyMsg.setTargetPort(originPort);
|
||||
}else {
|
||||
String namespace = route.getNamespace();
|
||||
proxyMsg.setNamespace(namespace);
|
||||
// 其他路由代理
|
||||
String targetIp = route.getTargetIp();
|
||||
String targetPort = NormalUsedString.ASTERISK.equals(route.getTargetPort())?String.valueOf(originPort):route.getTargetPort();
|
||||
|
||||
@@ -24,10 +24,7 @@ public class ClientProxyRoute implements ProxyRoute{
|
||||
* 虚拟端口
|
||||
*/
|
||||
private String virtualPort;
|
||||
/**
|
||||
* 命名空间
|
||||
*/
|
||||
private String namespace;
|
||||
|
||||
|
||||
/**
|
||||
*
|
||||
|
||||
@@ -6,8 +6,6 @@ package org.framework.lazy.cloud.network.heartbeat.protocol.route;
|
||||
public interface ProxyRoute {
|
||||
|
||||
|
||||
String getNamespace();
|
||||
|
||||
|
||||
String getVirtualIp();
|
||||
|
||||
|
||||
@@ -10,10 +10,6 @@ import lombok.Data;
|
||||
public class ServerProxyRoute implements ProxyRoute {
|
||||
|
||||
|
||||
/**
|
||||
* 命名空间
|
||||
*/
|
||||
private String namespace;
|
||||
|
||||
/**
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user