mirror of
https://github.com/soypat/lneto.git
synced 2026-07-26 10:38:47 +00:00
restructure package, rename module/repo
This commit is contained in:
@@ -1,14 +1,16 @@
|
||||
# tseq
|
||||
[](https://pkg.go.dev/github.com/soypat/tseq)
|
||||
[](https://goreportcard.com/report/github.com/soypat/tseq)
|
||||
[](https://codecov.io/gh/soypat/tseq)
|
||||
[](https://github.com/soypat/tseq/actions/workflows/go.yml)
|
||||
[](https://sourcegraph.com/github.com/soypat/tseq?badge)
|
||||
# lneto
|
||||
[](https://pkg.go.dev/github.com/soypat/lneto)
|
||||
[](https://goreportcard.com/report/github.com/soypat/lneto)
|
||||
[](https://codecov.io/gh/soypat/lneto)
|
||||
[](https://github.com/soypat/lneto/actions/workflows/go.yml)
|
||||
[](https://sourcegraph.com/github.com/soypat/lneto?badge)
|
||||
|
||||
Userspace networking primitives.
|
||||
Userspace networking primitives.
|
||||
|
||||
`lneto` is pronounced "L-net-oh", a.k.a. "El Neto"; a.k.a. "Don Networkio"; a.k.a "Neto, connector of worlds".
|
||||
|
||||
## Packages
|
||||
- `lneto`: Low-level Networking Operations, or "El Neto", the big networking package. Zero copy network frame marshalling and unmarshalling.
|
||||
- `lneto`: Low-level Networking Operations, or "El Neto", the networking package. Zero copy network frame marshalling and unmarshalling.
|
||||
- [`lneto/frames.go`](./lneto/frames.go): Ethernet, IPv4/IPv6, ARP, TCP, UDP packet marshalling/unmarshalling.
|
||||
|
||||
- [`lneto/tcp`](./lneto/ntp): TCP implementation and low level logic.
|
||||
@@ -20,7 +22,7 @@ Userspace networking primitives.
|
||||
## Install
|
||||
How to install package with newer versions of Go (+1.16):
|
||||
```sh
|
||||
go mod download github.com/soypat/tseq@latest
|
||||
go mod download github.com/soypat/lneto@latest
|
||||
```
|
||||
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ import (
|
||||
"fmt"
|
||||
"math"
|
||||
|
||||
"github.com/soypat/tseq/lneto/tcp"
|
||||
"github.com/soypat/lneto/tcp"
|
||||
)
|
||||
|
||||
// NewEthFrame returns a EthFrame with data set to buf.
|
||||
@@ -1,3 +1,3 @@
|
||||
module github.com/soypat/tseq
|
||||
module github.com/soypat/lneto
|
||||
|
||||
go 1.20
|
||||
|
||||
+1
-1
@@ -8,7 +8,7 @@ import (
|
||||
"unsafe"
|
||||
)
|
||||
|
||||
var errRingBufferFull = errors.New("tseq/ring: buffer full")
|
||||
var errRingBufferFull = errors.New("lneto/ring: buffer full")
|
||||
|
||||
// NewRing returns a new ring buffer ready for use.
|
||||
func NewRing(buf []byte) *Ring {
|
||||
|
||||
@@ -5,7 +5,7 @@ import (
|
||||
"math/rand"
|
||||
"testing"
|
||||
|
||||
"github.com/soypat/tseq/lneto/tcp"
|
||||
"github.com/soypat/lneto/tcp"
|
||||
)
|
||||
|
||||
func TestTCPMarshalUnmarshal(t *testing.T) {
|
||||
@@ -6,7 +6,7 @@ import (
|
||||
"math"
|
||||
"net"
|
||||
|
||||
"github.com/soypat/tseq/internal"
|
||||
"github.com/soypat/lneto/internal"
|
||||
)
|
||||
|
||||
// ControlBlock is a partial Transmission Control Block (TCB) implementation as
|
||||
@@ -4,7 +4,7 @@ import (
|
||||
"context"
|
||||
"log/slog"
|
||||
|
||||
"github.com/soypat/tseq/internal"
|
||||
"github.com/soypat/lneto/internal"
|
||||
)
|
||||
|
||||
func (tcb *ControlBlock) logenabled(lvl slog.Level) bool {
|
||||
@@ -5,8 +5,8 @@ import (
|
||||
"strconv"
|
||||
"testing"
|
||||
|
||||
"github.com/soypat/tseq/lneto"
|
||||
"github.com/soypat/tseq/lneto/tcp"
|
||||
"github.com/soypat/lneto"
|
||||
"github.com/soypat/lneto/tcp"
|
||||
)
|
||||
|
||||
const (
|
||||
@@ -4,7 +4,7 @@ import (
|
||||
"errors"
|
||||
"time"
|
||||
|
||||
"github.com/soypat/tseq/internal"
|
||||
"github.com/soypat/lneto/internal"
|
||||
)
|
||||
|
||||
func newRingTx(buf []byte, maxQueuedPackets int) *ringTx {
|
||||
Reference in New Issue
Block a user