move tunnel/resolver into network
This commit is contained in:
parent
44f281f8d9
commit
d60d85de5c
@ -18,14 +18,14 @@ import (
|
|||||||
pb "github.com/micro/go-micro/v3/network/mucp/proto"
|
pb "github.com/micro/go-micro/v3/network/mucp/proto"
|
||||||
"github.com/micro/go-micro/v3/proxy"
|
"github.com/micro/go-micro/v3/proxy"
|
||||||
"github.com/micro/go-micro/v3/registry/noop"
|
"github.com/micro/go-micro/v3/registry/noop"
|
||||||
"github.com/micro/go-micro/v3/resolver/dns"
|
"github.com/micro/go-micro/v3/network/resolver/dns"
|
||||||
"github.com/micro/go-micro/v3/router"
|
"github.com/micro/go-micro/v3/router"
|
||||||
"github.com/micro/go-micro/v3/server"
|
"github.com/micro/go-micro/v3/server"
|
||||||
smucp "github.com/micro/go-micro/v3/server/mucp"
|
smucp "github.com/micro/go-micro/v3/server/mucp"
|
||||||
"github.com/micro/go-micro/v3/transport"
|
"github.com/micro/go-micro/v3/transport"
|
||||||
"github.com/micro/go-micro/v3/tunnel"
|
"github.com/micro/go-micro/v3/network/tunnel"
|
||||||
bun "github.com/micro/go-micro/v3/tunnel/broker"
|
bun "github.com/micro/go-micro/v3/network/tunnel/broker"
|
||||||
tun "github.com/micro/go-micro/v3/tunnel/transport"
|
tun "github.com/micro/go-micro/v3/network/tunnel/transport"
|
||||||
"github.com/micro/go-micro/v3/util/backoff"
|
"github.com/micro/go-micro/v3/util/backoff"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -6,8 +6,8 @@ import (
|
|||||||
"github.com/micro/go-micro/v3/proxy/mucp"
|
"github.com/micro/go-micro/v3/proxy/mucp"
|
||||||
"github.com/micro/go-micro/v3/router"
|
"github.com/micro/go-micro/v3/router"
|
||||||
regRouter "github.com/micro/go-micro/v3/router/registry"
|
regRouter "github.com/micro/go-micro/v3/router/registry"
|
||||||
"github.com/micro/go-micro/v3/tunnel"
|
"github.com/micro/go-micro/v3/network/tunnel"
|
||||||
tmucp "github.com/micro/go-micro/v3/tunnel/mucp"
|
tmucp "github.com/micro/go-micro/v3/network/tunnel/mucp"
|
||||||
)
|
)
|
||||||
|
|
||||||
type Option func(*Options)
|
type Option func(*Options)
|
||||||
|
@ -5,7 +5,7 @@ import (
|
|||||||
"context"
|
"context"
|
||||||
"net"
|
"net"
|
||||||
|
|
||||||
"github.com/micro/go-micro/v3/resolver"
|
"github.com/micro/go-micro/v3/network/resolver"
|
||||||
"github.com/miekg/dns"
|
"github.com/miekg/dns"
|
||||||
)
|
)
|
||||||
|
|
@ -5,7 +5,7 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
"net"
|
"net"
|
||||||
|
|
||||||
"github.com/micro/go-micro/v3/resolver"
|
"github.com/micro/go-micro/v3/network/resolver"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Resolver is a DNS network resolve
|
// Resolver is a DNS network resolve
|
@ -8,7 +8,7 @@ import (
|
|||||||
"net/http"
|
"net/http"
|
||||||
"net/url"
|
"net/url"
|
||||||
|
|
||||||
"github.com/micro/go-micro/v3/resolver"
|
"github.com/micro/go-micro/v3/network/resolver"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Resolver is a HTTP network resolver
|
// Resolver is a HTTP network resolver
|
@ -2,7 +2,7 @@
|
|||||||
package noop
|
package noop
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/micro/go-micro/v3/resolver"
|
"github.com/micro/go-micro/v3/network/resolver"
|
||||||
)
|
)
|
||||||
|
|
||||||
type Resolver struct{}
|
type Resolver struct{}
|
@ -4,7 +4,7 @@ package registry
|
|||||||
import (
|
import (
|
||||||
"github.com/micro/go-micro/v3/registry"
|
"github.com/micro/go-micro/v3/registry"
|
||||||
"github.com/micro/go-micro/v3/registry/mdns"
|
"github.com/micro/go-micro/v3/registry/mdns"
|
||||||
"github.com/micro/go-micro/v3/resolver"
|
"github.com/micro/go-micro/v3/network/resolver"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Resolver is a registry network resolver
|
// Resolver is a registry network resolver
|
@ -2,7 +2,7 @@
|
|||||||
package static
|
package static
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/micro/go-micro/v3/resolver"
|
"github.com/micro/go-micro/v3/network/resolver"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Resolver returns a static list of nodes. In the event the node list
|
// Resolver returns a static list of nodes. In the event the node list
|
@ -6,8 +6,8 @@ import (
|
|||||||
|
|
||||||
"github.com/micro/go-micro/v3/broker"
|
"github.com/micro/go-micro/v3/broker"
|
||||||
"github.com/micro/go-micro/v3/transport"
|
"github.com/micro/go-micro/v3/transport"
|
||||||
"github.com/micro/go-micro/v3/tunnel"
|
"github.com/micro/go-micro/v3/network/tunnel"
|
||||||
"github.com/micro/go-micro/v3/tunnel/mucp"
|
"github.com/micro/go-micro/v3/network/tunnel/mucp"
|
||||||
)
|
)
|
||||||
|
|
||||||
type tunBroker struct {
|
type tunBroker struct {
|
@ -6,7 +6,7 @@ import (
|
|||||||
"crypto/rand"
|
"crypto/rand"
|
||||||
"crypto/sha256"
|
"crypto/sha256"
|
||||||
|
|
||||||
"github.com/micro/go-micro/v3/tunnel"
|
"github.com/micro/go-micro/v3/network/tunnel"
|
||||||
"github.com/oxtoacart/bpool"
|
"github.com/oxtoacart/bpool"
|
||||||
)
|
)
|
||||||
|
|
@ -5,7 +5,7 @@ import (
|
|||||||
"sync"
|
"sync"
|
||||||
|
|
||||||
"github.com/micro/go-micro/v3/logger"
|
"github.com/micro/go-micro/v3/logger"
|
||||||
"github.com/micro/go-micro/v3/tunnel"
|
"github.com/micro/go-micro/v3/network/tunnel"
|
||||||
)
|
)
|
||||||
|
|
||||||
type tunListener struct {
|
type tunListener struct {
|
@ -10,7 +10,7 @@ import (
|
|||||||
"github.com/google/uuid"
|
"github.com/google/uuid"
|
||||||
"github.com/micro/go-micro/v3/logger"
|
"github.com/micro/go-micro/v3/logger"
|
||||||
"github.com/micro/go-micro/v3/transport"
|
"github.com/micro/go-micro/v3/transport"
|
||||||
"github.com/micro/go-micro/v3/tunnel"
|
"github.com/micro/go-micro/v3/network/tunnel"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
@ -7,7 +7,7 @@ import (
|
|||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/micro/go-micro/v3/transport"
|
"github.com/micro/go-micro/v3/transport"
|
||||||
"github.com/micro/go-micro/v3/tunnel"
|
"github.com/micro/go-micro/v3/network/tunnel"
|
||||||
)
|
)
|
||||||
|
|
||||||
func testBrokenTunAccept(t *testing.T, tun tunnel.Tunnel, wait chan bool, wg *sync.WaitGroup) {
|
func testBrokenTunAccept(t *testing.T, tun tunnel.Tunnel, wait chan bool, wg *sync.WaitGroup) {
|
@ -9,7 +9,7 @@ import (
|
|||||||
|
|
||||||
"github.com/micro/go-micro/v3/logger"
|
"github.com/micro/go-micro/v3/logger"
|
||||||
"github.com/micro/go-micro/v3/transport"
|
"github.com/micro/go-micro/v3/transport"
|
||||||
"github.com/micro/go-micro/v3/tunnel"
|
"github.com/micro/go-micro/v3/network/tunnel"
|
||||||
)
|
)
|
||||||
|
|
||||||
// session is our pseudo session for transport.Socket
|
// session is our pseudo session for transport.Socket
|
@ -2,7 +2,7 @@ package transport
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/micro/go-micro/v3/transport"
|
"github.com/micro/go-micro/v3/transport"
|
||||||
"github.com/micro/go-micro/v3/tunnel"
|
"github.com/micro/go-micro/v3/network/tunnel"
|
||||||
)
|
)
|
||||||
|
|
||||||
type tunListener struct {
|
type tunListener struct {
|
@ -5,8 +5,8 @@ import (
|
|||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/micro/go-micro/v3/transport"
|
"github.com/micro/go-micro/v3/transport"
|
||||||
"github.com/micro/go-micro/v3/tunnel"
|
"github.com/micro/go-micro/v3/network/tunnel"
|
||||||
"github.com/micro/go-micro/v3/tunnel/mucp"
|
"github.com/micro/go-micro/v3/network/tunnel/mucp"
|
||||||
)
|
)
|
||||||
|
|
||||||
type tunTransport struct {
|
type tunTransport struct {
|
Loading…
Reference in New Issue
Block a user