repo stringlengths 6 47 | file_url stringlengths 77 269 | file_path stringlengths 5 186 | content stringlengths 0 32.8k | language stringclasses 1
value | license stringclasses 7
values | commit_sha stringlengths 40 40 | retrieved_at stringdate 2026-01-07 08:35:43 2026-01-07 08:55:24 | truncated bool 2
classes |
|---|---|---|---|---|---|---|---|---|
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/serf/serf/coalesce_member.go | vendor/github.com/hashicorp/serf/serf/coalesce_member.go | package serf
type coalesceEvent struct {
Type EventType
Member *Member
}
type memberEventCoalescer struct {
lastEvents map[string]EventType
latestEvents map[string]coalesceEvent
}
func (c *memberEventCoalescer) Handle(e Event) bool {
switch e.EventType() {
case EventMemberJoin:
return true
case EventMem... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/serf/serf/query.go | vendor/github.com/hashicorp/serf/serf/query.go | package serf
import (
"errors"
"fmt"
"math"
"math/rand"
"net"
"regexp"
"sync"
"time"
)
// QueryParam is provided to Query() to configure the parameters of the
// query. If not provided, sane defaults will be used.
type QueryParam struct {
// If provided, we restrict the nodes that should respond to those
//... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/serf/serf/event.go | vendor/github.com/hashicorp/serf/serf/event.go | package serf
import (
"fmt"
"net"
"sync"
"time"
)
// EventType are all the types of events that may occur and be sent
// along the Serf channel.
type EventType int
const (
EventMemberJoin EventType = iota
EventMemberLeave
EventMemberFailed
EventMemberUpdate
EventMemberReap
EventUser
EventQuery
)
func (t ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/serf/serf/internal_query.go | vendor/github.com/hashicorp/serf/serf/internal_query.go | package serf
import (
"encoding/base64"
"fmt"
"log"
"strings"
)
const (
// This is the prefix we use for queries that are internal to Serf.
// They are handled internally, and not forwarded to a client.
InternalQueryPrefix = "_serf_"
// pingQuery is run to check for reachability
pingQuery = "ping"
// conf... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/serf/serf/conflict_delegate.go | vendor/github.com/hashicorp/serf/serf/conflict_delegate.go | package serf
import (
"github.com/hashicorp/memberlist"
)
type conflictDelegate struct {
serf *Serf
}
func (c *conflictDelegate) NotifyConflict(existing, other *memberlist.Node) {
c.serf.handleNodeConflict(existing, other)
}
| go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/merge_delegate.go | vendor/github.com/hashicorp/memberlist/merge_delegate.go | package memberlist
// MergeDelegate is used to involve a client in
// a potential cluster merge operation. Namely, when
// a node does a TCP push/pull (as part of a join),
// the delegate is involved and allowed to cancel the join
// based on custom logic. The merge delegate is NOT invoked
// as part of the push-pull ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/memberlist.go | vendor/github.com/hashicorp/memberlist/memberlist.go | /*
memberlist is a library that manages cluster
membership and member failure detection using a gossip based protocol.
The use cases for such a library are far-reaching: all distributed systems
require membership, and memberlist is a re-usable solution to managing
cluster membership and node failure detection.
member... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/logging.go | vendor/github.com/hashicorp/memberlist/logging.go | package memberlist
import (
"fmt"
"net"
)
func LogAddress(addr net.Addr) string {
if addr == nil {
return "from=<unknown address>"
}
return fmt.Sprintf("from=%s", addr.String())
}
func LogStringAddress(addr string) string {
if addr == "" {
return "from=<unknown address>"
}
return fmt.Sprintf("from=%s",... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/broadcast.go | vendor/github.com/hashicorp/memberlist/broadcast.go | package memberlist
/*
The broadcast mechanism works by maintaining a sorted list of messages to be
sent out. When a message is to be broadcast, the retransmit count
is set to zero and appended to the queue. The retransmit count serves
as the "priority", ensuring that newer messages get sent first. Once
a message hits ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/ping_delegate.go | vendor/github.com/hashicorp/memberlist/ping_delegate.go | package memberlist
import "time"
// PingDelegate is used to notify an observer how long it took for a ping message to
// complete a round trip. It can also be used for writing arbitrary byte slices
// into ack messages. Note that in order to be meaningful for RTT estimates, this
// delegate does not apply to indirec... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/suspicion.go | vendor/github.com/hashicorp/memberlist/suspicion.go | package memberlist
import (
"math"
"sync/atomic"
"time"
)
// suspicion manages the suspect timer for a node and provides an interface
// to accelerate the timeout as we get more independent confirmations that
// a node is suspect.
type suspicion struct {
// n is the number of independent confirmations we've seen.... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/config.go | vendor/github.com/hashicorp/memberlist/config.go | package memberlist
import (
"fmt"
"io"
"log"
"net"
"os"
"strings"
"time"
"github.com/armon/go-metrics"
multierror "github.com/hashicorp/go-multierror"
)
type Config struct {
// The name of this node. This must be unique in the cluster.
Name string
// Transport is a hook for providing custom code to comm... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/mock_transport.go | vendor/github.com/hashicorp/memberlist/mock_transport.go | package memberlist
import (
"bytes"
"fmt"
"io"
"net"
"strconv"
"time"
)
// MockNetwork is used as a factory that produces MockTransport instances which
// are uniquely addressed and wired up to talk to each other.
type MockNetwork struct {
transportsByAddr map[string]*MockTransport
transportsByName map[string... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/net.go | vendor/github.com/hashicorp/memberlist/net.go | package memberlist
import (
"bufio"
"bytes"
"encoding/binary"
"fmt"
"hash/crc32"
"io"
"math"
"net"
"sync/atomic"
"time"
metrics "github.com/armon/go-metrics"
"github.com/hashicorp/go-msgpack/codec"
)
// This is the minimum and maximum protocol version that we can
// _understand_. We're allowed to speak a... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | true |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/state.go | vendor/github.com/hashicorp/memberlist/state.go | package memberlist
import (
"bytes"
"fmt"
"math"
"math/rand"
"net"
"strings"
"sync/atomic"
"time"
metrics "github.com/armon/go-metrics"
)
type NodeStateType int
const (
StateAlive NodeStateType = iota
StateSuspect
StateDead
StateLeft
)
// Node represents a node in the cluster.
type Node struct {
Name... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | true |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/delegate.go | vendor/github.com/hashicorp/memberlist/delegate.go | package memberlist
// Delegate is the interface that clients must implement if they want to hook
// into the gossip layer of Memberlist. All the methods must be thread-safe,
// as they can and generally will be called concurrently.
type Delegate interface {
// NodeMeta is used to retrieve meta-data about the current ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/util.go | vendor/github.com/hashicorp/memberlist/util.go | package memberlist
import (
"bytes"
"compress/lzw"
"encoding/binary"
"fmt"
"io"
"math"
"math/rand"
"net"
"strconv"
"strings"
"time"
"github.com/hashicorp/go-msgpack/codec"
"github.com/sean-/seed"
)
// pushPullScale is the minimum number of nodes
// before we start scaling the push/pull timing. The scale... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/peeked_conn.go | vendor/github.com/hashicorp/memberlist/peeked_conn.go | // Copyright 2017 Google Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/event_delegate.go | vendor/github.com/hashicorp/memberlist/event_delegate.go | package memberlist
// EventDelegate is a simpler delegate that is used only to receive
// notifications about members joining and leaving. The methods in this
// delegate may be called by multiple goroutines, but never concurrently.
// This allows you to reason about ordering.
type EventDelegate interface {
// Notify... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/security.go | vendor/github.com/hashicorp/memberlist/security.go | package memberlist
import (
"bytes"
"crypto/aes"
"crypto/cipher"
"crypto/rand"
"fmt"
"io"
)
/*
Encrypted messages are prefixed with an encryptionVersion byte
that is used for us to be able to properly encode/decode. We
currently support the following versions:
0 - AES-GCM 128, using PKCS7 padding
1 - AES-GC... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/keyring.go | vendor/github.com/hashicorp/memberlist/keyring.go | package memberlist
import (
"bytes"
"fmt"
"sync"
)
type Keyring struct {
// Keys stores the key data used during encryption and decryption. It is
// ordered in such a way where the first key (index 0) is the primary key,
// which is used for encrypting messages, and is the first key tried during
// message dec... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/awareness.go | vendor/github.com/hashicorp/memberlist/awareness.go | package memberlist
import (
"sync"
"time"
"github.com/armon/go-metrics"
)
// awareness manages a simple metric for tracking the estimated health of the
// local node. Health is primary the node's ability to respond in the soft
// real-time manner required for correct health checking of other nodes in the
// clust... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/net_transport.go | vendor/github.com/hashicorp/memberlist/net_transport.go | package memberlist
import (
"bytes"
"fmt"
"io"
"log"
"net"
"sync"
"sync/atomic"
"time"
"github.com/armon/go-metrics"
sockaddr "github.com/hashicorp/go-sockaddr"
)
const (
// udpPacketBufSize is used to buffer incoming packets during read
// operations.
udpPacketBufSize = 65536
// udpRecvBufSize is a l... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/transport.go | vendor/github.com/hashicorp/memberlist/transport.go | package memberlist
import (
"fmt"
"net"
"time"
)
// Packet is used to provide some metadata about incoming packets from peers
// over a packet connection, as well as the packet payload.
type Packet struct {
// Buf has the raw contents of the packet.
Buf []byte
// From has the address of the peer. This is an ac... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/alive_delegate.go | vendor/github.com/hashicorp/memberlist/alive_delegate.go | package memberlist
// AliveDelegate is used to involve a client in processing
// a node "alive" message. When a node joins, either through
// a UDP gossip or TCP push/pull, we update the state of
// that node via an alive message. This can be used to filter
// a node out and prevent it from being considered a peer
// ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/conflict_delegate.go | vendor/github.com/hashicorp/memberlist/conflict_delegate.go | package memberlist
// ConflictDelegate is a used to inform a client that
// a node has attempted to join which would result in a
// name conflict. This happens if two clients are configured
// with the same name but different addresses.
type ConflictDelegate interface {
// NotifyConflict is invoked when a name confli... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/label.go | vendor/github.com/hashicorp/memberlist/label.go | package memberlist
import (
"bufio"
"fmt"
"io"
"net"
)
// General approach is to prefix all packets and streams with the same structure:
//
// magic type byte (244): uint8
// length of label name: uint8 (because labels can't be longer than 255 bytes)
// label name: []uint8
// LabelMaxSize is the maxi... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/memberlist/queue.go | vendor/github.com/hashicorp/memberlist/queue.go | package memberlist
import (
"math"
"sync"
"github.com/google/btree"
)
// TransmitLimitedQueue is used to queue messages to broadcast to
// the cluster (via gossip) but limits the number of transmits per
// message. It also prioritizes messages with lower transmit counts
// (hence newer messages).
type TransmitLim... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/go-msgpack/codec/time.go | vendor/github.com/hashicorp/go-msgpack/codec/time.go | // Copyright (c) 2012, 2013 Ugorji Nwoke. All rights reserved.
// Use of this source code is governed by a BSD-style license found in the LICENSE file.
package codec
import (
"time"
)
var (
timeDigits = [...]byte{'0', '1', '2', '3', '4', '5', '6', '7', '8', '9'}
)
// EncodeTime encodes a time.Time as a []byte, in... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/go-msgpack/codec/0doc.go | vendor/github.com/hashicorp/go-msgpack/codec/0doc.go | // Copyright (c) 2012, 2013 Ugorji Nwoke. All rights reserved.
// Use of this source code is governed by a BSD-style license found in the LICENSE file.
/*
High Performance, Feature-Rich Idiomatic Go encoding library for msgpack and binc .
Supported Serialization formats are:
- msgpack: [https://github.com/msgpack/... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/go-msgpack/codec/rpc.go | vendor/github.com/hashicorp/go-msgpack/codec/rpc.go | // Copyright (c) 2012, 2013 Ugorji Nwoke. All rights reserved.
// Use of this source code is governed by a BSD-style license found in the LICENSE file.
package codec
import (
"bufio"
"io"
"net/rpc"
"sync"
)
// Rpc provides a rpc Server or Client Codec for rpc communication.
type Rpc interface {
ServerCodec(conn... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/go-msgpack/codec/helper.go | vendor/github.com/hashicorp/go-msgpack/codec/helper.go | // Copyright (c) 2012, 2013 Ugorji Nwoke. All rights reserved.
// Use of this source code is governed by a BSD-style license found in the LICENSE file.
package codec
// Contains code shared by both encode and decode.
import (
"encoding/binary"
"fmt"
"math"
"reflect"
"sort"
"strings"
"sync"
"time"
"unicode"
... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/go-msgpack/codec/msgpack.go | vendor/github.com/hashicorp/go-msgpack/codec/msgpack.go | // Copyright (c) 2012, 2013 Ugorji Nwoke. All rights reserved.
// Use of this source code is governed by a BSD-style license found in the LICENSE file.
/*
MSGPACK
Msgpack-c implementation powers the c, c++, python, ruby, etc libraries.
We need to maintain compatibility with it and how it encodes integer values
withou... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/go-msgpack/codec/helper_internal.go | vendor/github.com/hashicorp/go-msgpack/codec/helper_internal.go | // Copyright (c) 2012, 2013 Ugorji Nwoke. All rights reserved.
// Use of this source code is governed by a BSD-style license found in the LICENSE file.
package codec
// All non-std package dependencies live in this file,
// so porting to different environment is easy (just update functions).
import (
"errors"
"fmt... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/go-msgpack/codec/binc.go | vendor/github.com/hashicorp/go-msgpack/codec/binc.go | // Copyright (c) 2012, 2013 Ugorji Nwoke. All rights reserved.
// Use of this source code is governed by a BSD-style license found in the LICENSE file.
package codec
import (
"math"
// "reflect"
// "sync/atomic"
"time"
//"fmt"
)
const bincDoPrune = true // No longer needed. Needed before as C lib did not suppor... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/go-msgpack/codec/encode.go | vendor/github.com/hashicorp/go-msgpack/codec/encode.go | // Copyright (c) 2012, 2013 Ugorji Nwoke. All rights reserved.
// Use of this source code is governed by a BSD-style license found in the LICENSE file.
package codec
import (
"io"
"reflect"
)
const (
// Some tagging information for error messages.
msgTagEnc = "codec.encoder"
defEncByteBufSize = 1 << 6 /... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/go-msgpack/codec/simple.go | vendor/github.com/hashicorp/go-msgpack/codec/simple.go | // Copyright (c) 2012, 2013 Ugorji Nwoke. All rights reserved.
// Use of this source code is governed by a BSD-style license found in the LICENSE file.
package codec
import "math"
const (
_ uint8 = iota
simpleVdNil = 1
simpleVdFalse = 2
simpleVdTrue = 3
simpleVdFloat32 ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/hashicorp/go-msgpack/codec/decode.go | vendor/github.com/hashicorp/go-msgpack/codec/decode.go | // Copyright (c) 2012, 2013 Ugorji Nwoke. All rights reserved.
// Use of this source code is governed by a BSD-style license found in the LICENSE file.
package codec
import (
"io"
"reflect"
// "runtime/debug"
)
// Some tagging information for error messages.
const (
msgTagDec = "codec.decoder"
msgBa... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/cpuguy83/tar2go/index.go | vendor/github.com/cpuguy83/tar2go/index.go | package tar2go
import (
"archive/tar"
"errors"
"fmt"
"io"
"io/fs"
"sync"
)
var (
// ErrDelete should be returned by an UpdaterFn when the file should be deleted.
ErrDelete = errors.New("delete")
)
// Index is a tar index that can be used to read files from a tar.
type Index struct {
rdr *io.SectionReader
t... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/cpuguy83/tar2go/file.go | vendor/github.com/cpuguy83/tar2go/file.go | package tar2go
import (
"archive/tar"
"io"
"io/fs"
"time"
)
type file struct {
idx *indexReader
rdr *io.SectionReader
}
func newFile(idx *indexReader) *file {
return &file{idx: idx, rdr: io.NewSectionReader(idx.rdr, idx.offset, idx.size)}
}
type fileinfo struct {
h *tar.Header
}
func (f *fileinfo) Name() s... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/cpuguy83/tar2go/fs.go | vendor/github.com/cpuguy83/tar2go/fs.go | package tar2go
import (
"io/fs"
)
var (
_ fs.FS = &filesystem{}
_ fs.File = &file{}
)
type filesystem struct {
idx *Index
}
func (f *filesystem) Open(name string) (fs.File, error) {
idx, err := f.idx.indexWithLock(name)
if err != nil {
return nil, &fs.PathError{Path: name, Op: "open", Err: err}
}
return... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/gofrs/flock/flock_unix.go | vendor/github.com/gofrs/flock/flock_unix.go | // Copyright 2015 Tim Heckman. All rights reserved.
// Copyright 2018-2025 The Gofrs. All rights reserved.
// Use of this source code is governed by the BSD 3-Clause
// license that can be found in the LICENSE file.
//go:build darwin || dragonfly || freebsd || illumos || linux || netbsd || openbsd
package flock
impo... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/gofrs/flock/flock.go | vendor/github.com/gofrs/flock/flock.go | // Copyright 2015 Tim Heckman. All rights reserved.
// Copyright 2018-2025 The Gofrs. All rights reserved.
// Use of this source code is governed by the BSD 3-Clause
// license that can be found in the LICENSE file.
// Package flock implements a thread-safe interface for file locking.
// It also includes a non-blockin... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/gofrs/flock/flock_unix_fcntl.go | vendor/github.com/gofrs/flock/flock_unix_fcntl.go | // Copyright 2015 Tim Heckman. All rights reserved.
// Copyright 2018-2025 The Gofrs. All rights reserved.
// Use of this source code is governed by the BSD 3-Clause
// license that can be found in the LICENSE file.
// Copyright 2018 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/gofrs/flock/flock_windows.go | vendor/github.com/gofrs/flock/flock_windows.go | // Copyright 2015 Tim Heckman. All rights reserved.
// Copyright 2018-2025 The Gofrs. All rights reserved.
// Use of this source code is governed by the BSD 3-Clause
// license that can be found in the LICENSE file.
//go:build windows
package flock
import (
"errors"
"golang.org/x/sys/windows"
)
// Use of 0x00000... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/gofrs/flock/flock_others.go | vendor/github.com/gofrs/flock/flock_others.go | // Copyright 2015 Tim Heckman. All rights reserved.
// Copyright 2018-2025 The Gofrs. All rights reserved.
// Use of this source code is governed by the BSD 3-Clause
// license that can be found in the LICENSE file.
//go:build (!unix && !windows) || plan9
package flock
import (
"errors"
"io/fs"
)
func (f *Flock) ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/suite/stats.go | vendor/github.com/stretchr/testify/suite/stats.go | package suite
import "time"
// SuiteInformation stats stores stats for the whole suite execution.
type SuiteInformation struct {
Start, End time.Time
TestStats map[string]*TestInformation
}
// TestInformation stores information about the execution of each test.
type TestInformation struct {
TestName string
St... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/suite/interfaces.go | vendor/github.com/stretchr/testify/suite/interfaces.go | package suite
import "testing"
// TestingSuite can store and return the current *testing.T context
// generated by 'go test'.
type TestingSuite interface {
T() *testing.T
SetT(*testing.T)
SetS(suite TestingSuite)
}
// SetupAllSuite has a SetupSuite method, which will run before the
// tests in the suite are run.
... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/suite/suite.go | vendor/github.com/stretchr/testify/suite/suite.go | package suite
import (
"flag"
"fmt"
"os"
"reflect"
"regexp"
"runtime/debug"
"strings"
"sync"
"testing"
"time"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
)
var matchMethod = flag.String("testify.m", "", "regular expression to select tests of the testify suite to run")
// S... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/suite/doc.go | vendor/github.com/stretchr/testify/suite/doc.go | // Package suite contains logic for creating testing suite structs
// and running the methods on those structs as tests. The most useful
// piece of this package is that you can create setup/teardown methods
// on your testing suites, which will run before/after the whole suite
// or individual tests (depending on whi... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/require/require_forward.go | vendor/github.com/stretchr/testify/require/require_forward.go | // Code generated with github.com/stretchr/testify/_codegen; DO NOT EDIT.
package require
import (
assert "github.com/stretchr/testify/assert"
http "net/http"
url "net/url"
time "time"
)
// Condition uses a Comparison to assert a complex condition.
func (a *Assertions) Condition(comp assert.Comparison, msgAndArg... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | true |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/require/requirements.go | vendor/github.com/stretchr/testify/require/requirements.go | package require
// TestingT is an interface wrapper around *testing.T
type TestingT interface {
Errorf(format string, args ...interface{})
FailNow()
}
type tHelper = interface {
Helper()
}
// ComparisonAssertionFunc is a common function prototype when comparing two values. Can be useful
// for table driven tests... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/require/forward_requirements.go | vendor/github.com/stretchr/testify/require/forward_requirements.go | package require
// Assertions provides assertion methods around the
// TestingT interface.
type Assertions struct {
t TestingT
}
// New makes a new Assertions object for the specified TestingT.
func New(t TestingT) *Assertions {
return &Assertions{
t: t,
}
}
//go:generate sh -c "cd ../_codegen && go build && cd... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/require/require.go | vendor/github.com/stretchr/testify/require/require.go | // Code generated with github.com/stretchr/testify/_codegen; DO NOT EDIT.
package require
import (
assert "github.com/stretchr/testify/assert"
http "net/http"
url "net/url"
time "time"
)
// Condition uses a Comparison to assert a complex condition.
func Condition(t TestingT, comp assert.Comparison, msgAndArgs ..... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | true |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/require/doc.go | vendor/github.com/stretchr/testify/require/doc.go | // Package require implements the same assertions as the `assert` package but
// stops test execution when a test fails.
//
// # Example Usage
//
// The following is a complete example using require in a standard test function:
//
// import (
// "testing"
// "github.com/stretchr/testify/require"
// )
//
// func Tes... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/assert/assertion_format.go | vendor/github.com/stretchr/testify/assert/assertion_format.go | // Code generated with github.com/stretchr/testify/_codegen; DO NOT EDIT.
package assert
import (
http "net/http"
url "net/url"
time "time"
)
// Conditionf uses a Comparison to assert a complex condition.
func Conditionf(t TestingT, comp Comparison, msg string, args ...interface{}) bool {
if h, ok := t.(tHelper)... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | true |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/assert/assertion_forward.go | vendor/github.com/stretchr/testify/assert/assertion_forward.go | // Code generated with github.com/stretchr/testify/_codegen; DO NOT EDIT.
package assert
import (
http "net/http"
url "net/url"
time "time"
)
// Condition uses a Comparison to assert a complex condition.
func (a *Assertions) Condition(comp Comparison, msgAndArgs ...interface{}) bool {
if h, ok := a.t.(tHelper); ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | true |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/assert/forward_assertions.go | vendor/github.com/stretchr/testify/assert/forward_assertions.go | package assert
// Assertions provides assertion methods around the
// TestingT interface.
type Assertions struct {
t TestingT
}
// New makes a new Assertions object for the specified TestingT.
func New(t TestingT) *Assertions {
return &Assertions{
t: t,
}
}
//go:generate sh -c "cd ../_codegen && go build && cd ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/assert/errors.go | vendor/github.com/stretchr/testify/assert/errors.go | package assert
import (
"errors"
)
// AnError is an error instance useful for testing. If the code does not care
// about error specifics, and only needs to return the error for example, this
// error should be used to make the test code more readable.
var AnError = errors.New("assert.AnError general error for test... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/assert/assertion_compare.go | vendor/github.com/stretchr/testify/assert/assertion_compare.go | package assert
import (
"bytes"
"fmt"
"reflect"
"time"
)
// Deprecated: CompareType has only ever been for internal use and has accidentally been published since v1.6.0. Do not use it.
type CompareType = compareResult
type compareResult int
const (
compareLess compareResult = iota - 1
compareEqual
compareGre... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/assert/assertions.go | vendor/github.com/stretchr/testify/assert/assertions.go | package assert
import (
"bufio"
"bytes"
"encoding/json"
"errors"
"fmt"
"math"
"os"
"reflect"
"regexp"
"runtime"
"runtime/debug"
"strings"
"time"
"unicode"
"unicode/utf8"
"github.com/davecgh/go-spew/spew"
"github.com/pmezard/go-difflib/difflib"
// Wrapper around gopkg.in/yaml.v3
"github.com/stretch... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | true |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/assert/doc.go | vendor/github.com/stretchr/testify/assert/doc.go | // Package assert provides a set of comprehensive testing tools for use with the normal Go testing system.
//
// # Note
//
// All functions in this package return a bool value indicating whether the assertion has passed.
//
// # Example Usage
//
// The following is a complete example using assert in a standard test fun... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/assert/assertion_order.go | vendor/github.com/stretchr/testify/assert/assertion_order.go | package assert
import (
"fmt"
"reflect"
)
// isOrdered checks that collection contains orderable elements.
func isOrdered(t TestingT, object interface{}, allowedComparesResults []compareResult, failMessage string, msgAndArgs ...interface{}) bool {
objKind := reflect.TypeOf(object).Kind()
if objKind != reflect.Sli... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/assert/http_assertions.go | vendor/github.com/stretchr/testify/assert/http_assertions.go | package assert
import (
"fmt"
"net/http"
"net/http/httptest"
"net/url"
"strings"
)
// httpCode is a helper that returns HTTP code of the response. It returns -1 and
// an error if building a new request fails.
func httpCode(handler http.HandlerFunc, method, url string, values url.Values) (int, error) {
w := htt... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/assert/yaml/yaml_fail.go | vendor/github.com/stretchr/testify/assert/yaml/yaml_fail.go | //go:build testify_yaml_fail && !testify_yaml_custom && !testify_yaml_default
// Package yaml is an implementation of YAML functions that always fail.
//
// This implementation can be used at build time to replace the default implementation
// to avoid linking with [gopkg.in/yaml.v3]:
//
// go test -tags testify_yaml_... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/assert/yaml/yaml_custom.go | vendor/github.com/stretchr/testify/assert/yaml/yaml_custom.go | //go:build testify_yaml_custom && !testify_yaml_fail && !testify_yaml_default
// Package yaml is an implementation of YAML functions that calls a pluggable implementation.
//
// This implementation is selected with the testify_yaml_custom build tag.
//
// go test -tags testify_yaml_custom
//
// This implementation can... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/stretchr/testify/assert/yaml/yaml_default.go | vendor/github.com/stretchr/testify/assert/yaml/yaml_default.go | //go:build !testify_yaml_fail && !testify_yaml_custom
// Package yaml is just an indirection to handle YAML deserialization.
//
// This package is just an indirection that allows the builder to override the
// indirection with an alternative implementation of this package that uses
// another implementation of YAML de... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/go-actions-cache/readerat.go | vendor/github.com/tonistiigi/go-actions-cache/readerat.go | package actionscache
import (
"io"
)
type ReaderAtCloser interface {
io.ReaderAt
io.Closer
}
type readerAtCloser struct {
offset int64
rc io.ReadCloser
ra io.ReaderAt
open func(offset int64) (io.ReadCloser, error)
closed bool
}
func toReaderAtCloser(open func(offset int64) (io.ReadCloser, error)) ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/go-actions-cache/rest.go | vendor/github.com/tonistiigi/go-actions-cache/rest.go | package actionscache
import (
"context"
"encoding/json"
"net/http"
"net/url"
"strconv"
)
const (
apiURL = "https://api.github.com"
perPage = 100
)
type RestAPI struct {
repo string
token string
opt Opt
}
type CacheKey struct {
ID int `json:"id"`
Ref string `json:"ref"`
Key ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/go-actions-cache/cache.go | vendor/github.com/tonistiigi/go-actions-cache/cache.go | package actionscache
import (
"bytes"
"context"
"crypto/sha256"
"encoding/hex"
"encoding/json"
"fmt"
"io"
"net/http"
"net/url"
"os"
"os/exec"
"strconv"
"strings"
"sync"
"time"
"github.com/dimchansky/utfbom"
"github.com/golang-jwt/jwt/v5"
"github.com/pkg/errors"
"golang.org/x/sync/errgroup"
)
var U... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/go-actions-cache/retry.go | vendor/github.com/tonistiigi/go-actions-cache/retry.go | package actionscache
import (
"context"
"sync"
"time"
"github.com/pkg/errors"
)
const maxBackoff = time.Second * 90
const minBackoff = time.Second * 1
var defaultBackoffPool = &BackoffPool{}
type BackoffPool struct {
mu sync.Mutex
queue []chan struct{}
timer *time.Timer
backoff time.Duration
targ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/go-actions-cache/cache_v2.go | vendor/github.com/tonistiigi/go-actions-cache/cache_v2.go | package actionscache
import (
"bytes"
"context"
"encoding/json"
"io"
"net/http"
"strings"
"time"
"github.com/Azure/azure-sdk-for-go/sdk/azcore"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/policy"
"github.com/Azure/azure-sdk-for-go/sdk/storage/azblob/blob"
"github.com/Azure/azure-sdk-for-go/sdk/storage/az... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/tarwriter.go | vendor/github.com/tonistiigi/fsutil/tarwriter.go | package fsutil
import (
"archive/tar"
"context"
"io"
"os"
"path/filepath"
"strings"
"syscall"
"github.com/pkg/errors"
"github.com/tonistiigi/fsutil/types"
)
func WriteTar(ctx context.Context, fs FS, w io.Writer) error {
tw := tar.NewWriter(w)
err := fs.Walk(ctx, "/", func(path string, entry os.DirEntry, e... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/diskwriter_freebsd.go | vendor/github.com/tonistiigi/fsutil/diskwriter_freebsd.go | //go:build freebsd
// +build freebsd
package fsutil
import (
"github.com/tonistiigi/fsutil/types"
"golang.org/x/sys/unix"
)
func createSpecialFile(path string, mode uint32, stat *types.Stat) error {
return unix.Mknod(path, mode, mkdev(stat.Devmajor, stat.Devminor))
}
func mkdev(major int64, minor int64) uint64 {... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/diskwriter_windows.go | vendor/github.com/tonistiigi/fsutil/diskwriter_windows.go | //go:build windows
// +build windows
package fsutil
import (
"fmt"
iofs "io/fs"
"os"
"syscall"
"github.com/Microsoft/go-winio"
"github.com/pkg/errors"
"github.com/tonistiigi/fsutil/types"
)
func rewriteMetadata(p string, stat *types.Stat) error {
return chtimes(p, stat.ModTime)
}
// handleTarTypeBlockCharF... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/hardlinks.go | vendor/github.com/tonistiigi/fsutil/hardlinks.go | package fsutil
import (
"context"
"io"
gofs "io/fs"
"os"
"syscall"
"github.com/pkg/errors"
"github.com/tonistiigi/fsutil/types"
)
// Hardlinks validates that all targets for links were part of the changes
type Hardlinks struct {
seenFiles map[string]struct{}
}
func (v *Hardlinks) HandleChange(kind ChangeKi... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/chtimes_nolinux.go | vendor/github.com/tonistiigi/fsutil/chtimes_nolinux.go | //go:build !linux
// +build !linux
package fsutil
import (
"os"
"time"
"github.com/pkg/errors"
)
func chtimes(path string, un int64) error {
mtime := time.Unix(0, un)
fi, err := os.Lstat(path)
if err != nil {
return errors.WithStack(err)
}
if fi.Mode()&os.ModeSymlink != 0 {
return nil
}
return errors.... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/stat.go | vendor/github.com/tonistiigi/fsutil/stat.go | package fsutil
import (
"os"
"path/filepath"
"runtime"
"github.com/pkg/errors"
"github.com/tonistiigi/fsutil/types"
)
// constructs a Stat object. path is where the path can be found right
// now, relpath is the desired path to be recorded in the stat (so
// relative to whatever base dir is relevant). fi is the... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/filter.go | vendor/github.com/tonistiigi/fsutil/filter.go | package fsutil
import (
"context"
"io"
gofs "io/fs"
"os"
"path/filepath"
"strings"
"syscall"
"github.com/moby/patternmatcher"
"github.com/pkg/errors"
"github.com/tonistiigi/fsutil/types"
)
type FilterOpt struct {
// IncludePatterns requires that the path matches at least one of the
// specified patterns.... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/buffer.go | vendor/github.com/tonistiigi/fsutil/buffer.go | package fsutil
import (
"io"
)
const chunkSize = 32 * 1024
type buffer struct {
chunks [][]byte
}
func (b *buffer) alloc(n int) []byte {
if n > chunkSize {
buf := make([]byte, n)
b.chunks = append(b.chunks, buf)
return buf
}
if len(b.chunks) != 0 {
lastChunk := b.chunks[len(b.chunks)-1]
l := len(las... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/stat_unix.go | vendor/github.com/tonistiigi/fsutil/stat_unix.go | //go:build !windows
// +build !windows
package fsutil
import (
"os"
"strings"
"syscall"
"github.com/containerd/continuity/sysx"
"github.com/pkg/errors"
"github.com/tonistiigi/fsutil/types"
)
const xattrApplePrefix = "com.apple."
func loadXattr(origpath string, stat *types.Stat) error {
xattrs, err := sysx.L... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/validator.go | vendor/github.com/tonistiigi/fsutil/validator.go | package fsutil
import (
"os"
"path/filepath"
"sort"
"strings"
"syscall"
"github.com/pkg/errors"
)
type parent struct {
dir string
last string
}
type Validator struct {
parentDirs []parent
}
func (v *Validator) HandleChange(kind ChangeKind, p string, fi os.FileInfo, err error) (retErr error) {
if err != ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/receive.go | vendor/github.com/tonistiigi/fsutil/receive.go | // send.go and receive.go describe the fsutil file-transfer protocol, which
// allows transferring file trees across a network connection.
//
// The protocol operates as follows:
// - The client (the receiver) connects to the server (the sender).
// - The sender walks the target tree lexicographically and sends a serie... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/followlinks_windows.go | vendor/github.com/tonistiigi/fsutil/followlinks_windows.go | package fsutil
import (
"os"
"github.com/pkg/errors"
"golang.org/x/sys/windows"
)
func isNotFound(err error) bool {
if errors.Is(err, os.ErrNotExist) || errors.Is(err, windows.ERROR_INVALID_NAME) {
return true
}
return false
}
| go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/followlinks_unix.go | vendor/github.com/tonistiigi/fsutil/followlinks_unix.go | //go:build !windows
// +build !windows
package fsutil
import (
"os"
"github.com/pkg/errors"
)
func isNotFound(err error) bool {
return errors.Is(err, os.ErrNotExist)
}
| go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/diskwriter_unix.go | vendor/github.com/tonistiigi/fsutil/diskwriter_unix.go | //go:build !windows
// +build !windows
package fsutil
import (
"os"
"syscall"
"github.com/containerd/continuity/sysx"
"github.com/pkg/errors"
"github.com/tonistiigi/fsutil/types"
)
func rewriteMetadata(p string, stat *types.Stat) error {
for key, value := range stat.Xattrs {
sysx.Setxattr(p, key, value, 0)
... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/diff.go | vendor/github.com/tonistiigi/fsutil/diff.go | package fsutil
import (
"context"
"hash"
"os"
"github.com/pkg/errors"
"github.com/tonistiigi/fsutil/types"
)
type walkerFn func(ctx context.Context, pathC chan<- *currentPath) error
func Changes(ctx context.Context, a, b walkerFn, changeFn ChangeFunc) error {
return nil
}
type HandleChangeFn func(ChangeKind,... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/diskwriter_unixnobsd.go | vendor/github.com/tonistiigi/fsutil/diskwriter_unixnobsd.go | //go:build !windows && !freebsd
// +build !windows,!freebsd
package fsutil
import (
"github.com/tonistiigi/fsutil/types"
"golang.org/x/sys/unix"
)
func createSpecialFile(path string, mode uint32, stat *types.Stat) error {
return unix.Mknod(path, mode, mkdev(stat.Devmajor, stat.Devminor))
}
func mkdev(major int64... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/followlinks.go | vendor/github.com/tonistiigi/fsutil/followlinks.go | package fsutil
import (
"context"
gofs "io/fs"
"os"
"path/filepath"
"runtime"
"sort"
strings "strings"
"syscall"
"github.com/pkg/errors"
"github.com/tonistiigi/fsutil/types"
)
func FollowLinks(fs FS, paths []string) ([]string, error) {
r := &symlinkResolver{fs: fs, resolved: map[string]struct{}{}}
for _,... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/fs.go | vendor/github.com/tonistiigi/fsutil/fs.go | package fsutil
import (
"context"
"io"
gofs "io/fs"
"os"
"path"
"path/filepath"
"sort"
"strings"
"syscall"
"time"
"github.com/pkg/errors"
"github.com/tonistiigi/fsutil/types"
)
type FS interface {
Walk(context.Context, string, gofs.WalkDirFunc) error
Open(string) (io.ReadCloser, error)
}
// NewFS crea... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/send.go | vendor/github.com/tonistiigi/fsutil/send.go | package fsutil
import (
"context"
"io"
"os"
"path/filepath"
"sync"
"syscall"
"github.com/pkg/errors"
"github.com/tonistiigi/fsutil/types"
"golang.org/x/sync/errgroup"
)
var bufPool = sync.Pool{
New: func() interface{} {
buf := make([]byte, 32*1<<10)
return &buf
},
}
type Stream interface {
RecvMsg(i... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/chtimes_linux.go | vendor/github.com/tonistiigi/fsutil/chtimes_linux.go | //go:build linux
// +build linux
package fsutil
import (
"github.com/pkg/errors"
"golang.org/x/sys/unix"
)
func chtimes(path string, un int64) error {
var utimes [2]unix.Timespec
utimes[0] = unix.NsecToTimespec(un)
utimes[1] = utimes[0]
if err := unix.UtimesNanoAt(unix.AT_FDCWD, path, utimes[0:], unix.AT_SYML... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/diff_containerd.go | vendor/github.com/tonistiigi/fsutil/diff_containerd.go | package fsutil
import (
"bytes"
"context"
"io"
"os"
"path/filepath"
"strings"
"github.com/tonistiigi/fsutil/types"
"golang.org/x/sync/errgroup"
)
// Everything below is copied from containerd/fs. TODO: remove duplication @dmcgowan
// Const redefined because containerd/fs doesn't build on !linux
// ChangeKi... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/diskwriter.go | vendor/github.com/tonistiigi/fsutil/diskwriter.go | package fsutil
import (
"context"
"hash"
"io"
gofs "io/fs"
"os"
"path/filepath"
"strconv"
"sync"
"syscall"
"time"
"github.com/opencontainers/go-digest"
"github.com/pkg/errors"
"github.com/tonistiigi/fsutil/types"
"golang.org/x/sync/errgroup"
)
type WriteToFunc func(context.Context, string, io.WriteClos... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/stat_windows.go | vendor/github.com/tonistiigi/fsutil/stat_windows.go | //go:build windows
// +build windows
package fsutil
import (
"os"
"github.com/tonistiigi/fsutil/types"
)
func loadXattr(_ string, _ *types.Stat) error {
return nil
}
func setUnixOpt(_ os.FileInfo, _ *types.Stat, _ string, _ map[uint64]string) {
}
| go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/copy/mkdir_windows.go | vendor/github.com/tonistiigi/fsutil/copy/mkdir_windows.go | //go:build windows
// +build windows
package fs
import (
"fmt"
"os"
"syscall"
"time"
"github.com/Microsoft/go-winio"
"github.com/pkg/errors"
"golang.org/x/sys/windows"
)
const (
containerAdministratorSidString = "S-1-5-93-2-1"
)
func fixRootDirectory(p string) string {
if len(p) == len(`\\?\c:`) {
if os... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/copy/hardlink_unix.go | vendor/github.com/tonistiigi/fsutil/copy/hardlink_unix.go | //go:build !windows
// +build !windows
package fs
import (
"os"
"syscall"
)
func getLinkInfo(fi os.FileInfo) (uint64, bool) {
s, ok := fi.Sys().(*syscall.Stat_t)
if !ok {
return 0, false
}
return uint64(s.Ino), !fi.IsDir() && s.Nlink > 1
}
| go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/copy/copy_nowindows.go | vendor/github.com/tonistiigi/fsutil/copy/copy_nowindows.go | //go:build !windows
// +build !windows
package fs
import (
"os"
"syscall"
"github.com/pkg/errors"
"github.com/containerd/continuity/sysx"
)
// copyXAttrs requires xeh to be non-nil
func copyXAttrs(dst, src string, xeh XAttrErrorHandler) error {
xattrKeys, err := sysx.LListxattr(src)
if err != nil {
return ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/copy/copy_otherbsd.go | vendor/github.com/tonistiigi/fsutil/copy/copy_otherbsd.go | //go:build openbsd || netbsd
// +build openbsd netbsd
package fs
import (
"io"
"os"
"github.com/pkg/errors"
"golang.org/x/sys/unix"
)
func copyFile(source, target string) error {
src, err := os.Open(source)
if err != nil {
return errors.Wrapf(err, "failed to open source %s", source)
}
defer src.Close()
t... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/vendor/github.com/tonistiigi/fsutil/copy/copy.go | vendor/github.com/tonistiigi/fsutil/copy/copy.go | package fs
import (
"context"
"os"
"path"
"path/filepath"
"runtime"
"slices"
"strings"
"sync"
"time"
"github.com/containerd/continuity/fs"
"github.com/moby/patternmatcher"
"github.com/pkg/errors"
mode "github.com/tonistiigi/dchapes-mode"
"github.com/tonistiigi/fsutil"
)
const defaultDirectoryMode = 075... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.