Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 42 for Writer (0.19 sec)

  1. internal/ioutil/ioutil.go

    // executes at least one write operation if it is closed.
    //
    // This can be useful within the context of HTTP. At least
    // one write operation must happen to send the HTTP headers
    // to the peer.
    type WriteOnCloser struct {
    	io.Writer
    	hasWritten bool
    }
    
    func (w *WriteOnCloser) Write(p []byte) (int, error) {
    	w.hasWritten = true
    	return w.Writer.Write(p)
    }
    
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Fri Apr 19 11:26:59 GMT 2024
    - 10.3K bytes
    - Viewed (0)
  2. cmd/metacache-walk.go

    // On success a sorted meta cache stream will be returned.
    // Metadata has data stripped, if any.
    func (s *xlStorage) WalkDir(ctx context.Context, opts WalkDirOptions, wr io.Writer) (err error) {
    	legacyFS := !(s.fsType == xfs || s.fsType == ext4)
    
    	s.RLock()
    	legacy := s.formatLegacy
    	s.RUnlock()
    
    	// Verify if volume is valid and it exists.
    	volumeDir, err := s.getVolDir(opts.Bucket)
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Mon Apr 15 08:25:46 GMT 2024
    - 12.4K bytes
    - Viewed (0)
  3. cmd/object-api-interface.go

    // tests are adjusted to use GetObjectNInfo this function can be removed.
    func GetObject(ctx context.Context, api ObjectLayer, bucket, object string, startOffset int64, length int64, writer io.Writer, etag string, opts ObjectOptions) (err error) {
    	var header http.Header
    	if etag != "" {
    		header.Set("ETag", etag)
    	}
    	Range := &HTTPRangeSpec{Start: startOffset, End: startOffset + length}
    
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Sat Apr 20 09:05:54 GMT 2024
    - 16.9K bytes
    - Viewed (0)
  4. docs/debugging/inspect/decrypt-v2.go

    package main
    
    import (
    	"errors"
    	"fmt"
    	"io"
    	"os"
    
    	"github.com/minio/madmin-go/v3/estream"
    )
    
    type keepFileErr struct {
    	error
    }
    
    func extractInspectV2(pk []byte, r io.Reader, w io.Writer, okMsg string) error {
    	privKey, err := bytesToPrivateKey(pk)
    	if err != nil {
    		return fmt.Errorf("decoding key returned: %w", err)
    	}
    
    	sr, err := estream.NewReader(r)
    	if err != nil {
    		return err
    	}
    
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Apr 11 21:22:47 GMT 2024
    - 2.2K bytes
    - Viewed (0)
  5. cmd/storage-interface.go

    	DeleteVol(ctx context.Context, volume string, forceDelete bool) (err error)
    
    	// WalkDir will walk a directory on disk and return a metacache stream on wr.
    	WalkDir(ctx context.Context, opts WalkDirOptions, wr io.Writer) error
    
    	// Metadata operations
    	DeleteVersion(ctx context.Context, volume, path string, fi FileInfo, forceDelMarker bool, opts DeleteOptions) error
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Mon Apr 15 08:25:46 GMT 2024
    - 4.9K bytes
    - Viewed (0)
  6. cmd/notification.go

    // DownloadProfilingData - download profiling data from all remote peers.
    func (sys *NotificationSys) DownloadProfilingData(ctx context.Context, writer io.Writer) (profilingDataFound bool) {
    	// Initialize a zip writer which will provide a zipped content
    	// of profiling data of all nodes
    	zipWriter := zip.NewWriter(writer)
    	defer zipWriter.Close()
    
    	for _, client := range sys.peerClients {
    		if client == nil {
    			continue
    		}
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Fri Apr 12 18:13:36 GMT 2024
    - 44.5K bytes
    - Viewed (0)
  7. cmd/metacache-stream.go

    		}
    		return nil
    	}
    	return &w
    }
    
    // write one or more objects to the stream in order.
    // It is favorable to send as many objects as possible in a single write,
    // but no more than math.MaxUint32
    func (w *metacacheWriter) write(objs ...metaCacheEntry) error {
    	if w == nil {
    		return errors.New("metacacheWriter: nil writer")
    	}
    	if len(objs) == 0 {
    		return nil
    	}
    	if w.creator != nil {
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 19.5K bytes
    - Viewed (0)
  8. cmd/erasure-decode.go

    }
    
    // Decode reads from readers, reconstructs data if needed and writes the data to the writer.
    // A set of preferred drives can be supplied. In that case they will be used and the data reconstructed.
    func (e Erasure) Decode(ctx context.Context, writer io.Writer, readers []io.ReaderAt, offset, length, totalLength int64, prefer []bool) (written int64, derr error) {
    	if offset < 0 || length < 0 {
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Fri Apr 19 16:44:59 GMT 2024
    - 9.4K bytes
    - Viewed (0)
  9. internal/grid/grid.go

    	ctx context.Context
    }
    
    func (w *writerWrapper) Write(p []byte) (n int, err error) {
    	buf := GetByteBufferCap(len(p))
    	buf = buf[:len(p)]
    	copy(buf, p)
    	select {
    	case w.ch <- buf:
    		return len(p), nil
    	case <-w.ctx.Done():
    		return 0, context.Cause(w.ctx)
    	}
    }
    
    // WriterToChannel will return an io.Writer that writes to the given channel.
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Tue Apr 02 15:56:18 GMT 2024
    - 4.8K bytes
    - Viewed (0)
  10. cmd/background-newdisks-heal-ops.go

    			h.QueuedBuckets = append(h.QueuedBuckets, b.Name)
    		}
    	}
    }
    
    func (h *healingTracker) printTo(writer io.Writer) {
    	h.mu.RLock()
    	defer h.mu.RUnlock()
    
    	b, err := json.MarshalIndent(h, "", "  ")
    	if err != nil {
    		writer.Write([]byte(err.Error()))
    		return
    	}
    	writer.Write(b)
    }
    
    // toHealingDisk converts the information to madmin.HealingDisk
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 14.7K bytes
    - Viewed (0)
Back to top