Search Options

Results per page
Sort
Preferred Languages
Advance

Results 931 - 940 of 1,179 for _func (0.04 sec)

  1. docs/debugging/healing-bin/main.go

    package main
    
    import (
    	"archive/zip"
    	"bytes"
    	"encoding/json"
    	"fmt"
    	"io"
    	"log"
    	"os"
    	"strings"
    
    	"github.com/minio/cli"
    	"github.com/tinylib/msgp/msgp"
    )
    
    func main() {
    	app := cli.NewApp()
    	app.Copyright = "MinIO, Inc."
    	app.Usage = "healing.bin to JSON"
    	app.HideVersion = true
    	app.HideHelpCommand = true
    	app.CustomAppHelpTemplate = `NAME:
      {{.Name}} - {{.Usage}}
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Sep 19 18:05:16 UTC 2022
    - 3.2K bytes
    - Viewed (0)
  2. internal/deadlineconn/deadlineconn_test.go

    package deadlineconn
    
    import (
    	"bufio"
    	"io"
    	"net"
    	"sync"
    	"testing"
    	"time"
    )
    
    // Test deadlineconn handles read timeout properly by reading two messages beyond deadline.
    func TestBuffConnReadTimeout(t *testing.T) {
    	l, err := net.Listen("tcp", "localhost:0")
    	if err != nil {
    		t.Fatalf("unable to create listener. %v", err)
    	}
    	defer l.Close()
    	serverAddr := l.Addr().String()
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sat Nov 05 18:09:21 UTC 2022
    - 3K bytes
    - Viewed (0)
  3. internal/amztime/parse.go

    // if the timeStr is invalid.
    func ParseHeader(timeStr string) (time.Time, error) {
    	for _, dateFormat := range httpTimeFormats {
    		t, err := time.Parse(dateFormat, timeStr)
    		if err == nil {
    			return t, nil
    		}
    	}
    	return time.Time{}, ErrMalformedDate
    }
    
    // ParseReplicationTS parse http.TimeFormat first
    // will try time.RFC3339Nano when parse http.TimeFormat failed
    func ParseReplicationTS(str string) (time.Time, error) {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Jan 18 07:03:17 UTC 2024
    - 2.5K bytes
    - Viewed (0)
  4. internal/crypto/header.go

    	xhttp "github.com/minio/minio/internal/http"
    )
    
    // RemoveSensitiveHeaders removes confidential encryption
    // information - e.g. the SSE-C key - from the HTTP headers.
    // It has the same semantics as RemoveSensitiveEntries.
    func RemoveSensitiveHeaders(h http.Header) {
    	h.Del(xhttp.AmzServerSideEncryptionCustomerKey)
    	h.Del(xhttp.AmzServerSideEncryptionCopyCustomerKey)
    	h.Del(xhttp.AmzMetaUnencryptedContentLength)
    	h.Del(xhttp.AmzMetaUnencryptedContentMD5)
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Feb 22 06:26:06 UTC 2024
    - 2.9K bytes
    - Viewed (0)
  5. callbacks/callmethod.go

    package callbacks
    
    import (
    	"reflect"
    
    	"gorm.io/gorm"
    )
    
    func callMethod(db *gorm.DB, fc func(value interface{}, tx *gorm.DB) bool) {
    	tx := db.Session(&gorm.Session{NewDB: true})
    	if called := fc(db.Statement.ReflectValue.Interface(), tx); !called {
    		switch db.Statement.ReflectValue.Kind() {
    		case reflect.Slice, reflect.Array:
    			db.Statement.CurDestIndex = 0
    			for i := 0; i < db.Statement.ReflectValue.Len(); i++ {
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Sat Feb 18 01:20:29 UTC 2023
    - 846 bytes
    - Viewed (0)
  6. internal/s3select/select_test.go

    	statusCode int
    	response   []byte
    }
    
    func (w *testResponseWriter) Header() http.Header {
    	return nil
    }
    
    func (w *testResponseWriter) Write(p []byte) (int, error) {
    	w.response = append(w.response, p...)
    	return len(p), nil
    }
    
    func (w *testResponseWriter) WriteHeader(statusCode int) {
    	w.statusCode = statusCode
    }
    
    func (w *testResponseWriter) Flush() {
    }
    
    func TestJSONQueries(t *testing.T) {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sat Dec 23 07:19:11 UTC 2023
    - 76.2K bytes
    - Viewed (0)
  7. internal/config/certs_test.go

    		}
    		if len(certs) != testCase.expectedResultLen {
    			t.Fatalf("certs: expected = %v, got = %v", testCase.expectedResultLen, len(certs))
    		}
    	}
    }
    
    func TestLoadX509KeyPair(t *testing.T) {
    	t.Cleanup(func() {
    		os.Unsetenv(EnvCertPassword)
    	})
    	for i, testCase := range loadX509KeyPairTests {
    		privateKey, err := createTempFile("private.key", testCase.privateKey)
    		if err != nil {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Sep 19 18:05:16 UTC 2022
    - 21.6K bytes
    - Viewed (0)
  8. internal/disk/stat_linux.go

    				}
    			}
    		}
    	}
    
    	return info, nil
    }
    
    // GetDriveStats returns IO stats of the drive by its major:minor
    func GetDriveStats(major, minor uint32) (iostats IOStats, err error) {
    	return readDriveStats(fmt.Sprintf("/sys/dev/block/%v:%v/stat", major, minor))
    }
    
    func readDriveStats(statsFile string) (iostats IOStats, err error) {
    	stats, err := readStat(statsFile)
    	if err != nil {
    		return IOStats{}, err
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Feb 26 19:34:50 UTC 2024
    - 4.8K bytes
    - Viewed (0)
  9. cmd/authtype_string.go

    // Code generated by "stringer -type=authType -trimprefix=authType auth-handler.go"; DO NOT EDIT.
    
    package cmd
    
    import "strconv"
    
    func _() {
    	// An "invalid array index" compiler error signifies that the constant values have changed.
    	// Re-run the stringer command to generate them again.
    	var x [1]struct{}
    	_ = x[authTypeUnknown-0]
    	_ = x[authTypeAnonymous-1]
    	_ = x[authTypePresigned-2]
    	_ = x[authTypePresignedV2-3]
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sat May 06 02:53:12 UTC 2023
    - 1.1K bytes
    - Viewed (0)
  10. cmd/os-rename_nolinux.go

    // along with this program.  If not, see <http://www.gnu.org/licenses/>.
    
    package cmd
    
    import (
    	"os"
    )
    
    // RenameSys is low level call in case of non-Linux this just uses os.Rename()
    func RenameSys(src, dst string) (err error) {
    	return os.Rename(src, dst)
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Feb 15 01:09:38 UTC 2024
    - 985 bytes
    - Viewed (0)
Back to top