Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 40 for decompress (0.07 sec)

  1. docs/en/docs/how-to/custom-request-and-route.md

    ///
    
    First, we create a `GzipRequest` class, which will overwrite the `Request.body()` method to decompress the body in the presence of an appropriate header.
    
    If there's no `gzip` in the header, it will not try to decompress the body.
    
    That way, the same route class can handle gzip compressed or uncompressed requests.
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 27 22:39:38 UTC 2024
    - 4.3K bytes
    - Viewed (0)
  2. .github/workflows/test-redistribute.yml

            run: pip install build
          - name: Build source distribution
            env:
              TIANGOLO_BUILD_PACKAGE: ${{ matrix.package }}
            run: python -m build --sdist
          - name: Decompress source distribution
            run: |
              cd dist
              tar xvf fastapi*.tar.gz
          - name: Install test dependencies
            run: |
              cd dist/fastapi*/
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Thu Aug 08 23:34:25 UTC 2024
    - 1.8K bytes
    - Viewed (0)
  3. cmd/object-api-utils.go

    			logger.Fatal(errSelfTestFailure, "compress: error on self-test: %v", err)
    		}
    	}
    	const skip = 2<<20 + 511
    	r, _ := newS2CompressReader(bytes.NewBuffer(data), int64(len(data)), true)
    	b, err := io.ReadAll(r)
    	failOnErr(err)
    	failOnErr(r.Close())
    	// Decompression reader.
    	s2Reader := s2.NewReader(bytes.NewBuffer(b))
    	// Apply the skipLen on the decompressed stream.
    	failOnErr(s2Reader.Skip(skip))
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Aug 08 15:29:58 UTC 2024
    - 37.1K bytes
    - Viewed (0)
  4. internal/store/store_test.go

    			t.Fatalf("case[%v]: Expected key.Name: %v, got %v", i, testCase.expectedKey.Name, key.Name)
    		}
    		if testCase.expectedKey.Compress != key.Compress {
    			t.Fatalf("case[%v]: Expected key.Compress: %v, got %v", i, testCase.expectedKey.Compress, key.Compress)
    		}
    		if testCase.expectedKey.Extension != key.Extension {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Fri Sep 06 23:06:30 UTC 2024
    - 4K bytes
    - Viewed (0)
  5. internal/store/batch_test.go

    	}
    	keys = store.List()
    	if len(keys) != 1 {
    		t.Fatalf("expected len(store.List())=1; but got %v", len(keys))
    	}
    	key := keys[0]
    	if !key.Compress {
    		t.Fatal("expected key.Compress=true; but got false")
    	}
    	if key.ItemCount != int(limit) {
    		t.Fatalf("expected key.ItemCount=%d; but got %v", limit, key.ItemCount)
    	}
    	items, err := store.GetMultiple(key)
    	if err != nil {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Fri Sep 06 23:06:30 UTC 2024
    - 5.6K bytes
    - Viewed (0)
  6. internal/s3select/progress.go

    package s3select
    
    import (
    	"context"
    	"errors"
    	"fmt"
    	"io"
    	"runtime"
    	"sync"
    	"sync/atomic"
    
    	"github.com/cosnicolaou/pbzip2"
    	"github.com/klauspost/compress/s2"
    	"github.com/klauspost/compress/zstd"
    	gzip "github.com/klauspost/pgzip"
    	"github.com/pierrec/lz4/v4"
    )
    
    type countUpReader struct {
    	reader    io.Reader
    	bytesRead int64
    }
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sun Sep 22 00:33:43 UTC 2024
    - 4.3K bytes
    - Viewed (0)
  7. cmd/object-api-utils_test.go

    	"fmt"
    	"io"
    	"math/rand"
    	"net/http"
    	"net/http/httptest"
    	"path"
    	"reflect"
    	"runtime"
    	"strconv"
    	"testing"
    
    	"github.com/klauspost/compress/s2"
    	"github.com/minio/minio/internal/auth"
    	"github.com/minio/minio/internal/config/compress"
    	"github.com/minio/minio/internal/crypto"
    	"github.com/minio/pkg/v3/trie"
    )
    
    func pathJoinOld(elem ...string) string {
    	trailingSlash := ""
    	if len(elem) > 0 {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Aug 08 15:29:58 UTC 2024
    - 24.1K bytes
    - Viewed (0)
  8. internal/store/queuestore.go

    package store
    
    import (
    	"bytes"
    	"encoding/json"
    	"errors"
    	"os"
    	"path/filepath"
    	"sort"
    	"sync"
    	"time"
    
    	"github.com/google/uuid"
    	jsoniter "github.com/json-iterator/go"
    	"github.com/klauspost/compress/s2"
    	"github.com/valyala/bytebufferpool"
    )
    
    const (
    	defaultLimit = 100000 // Default store limit.
    	defaultExt   = ".unknown"
    	compressExt  = ".snappy"
    )
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Fri Sep 06 23:06:30 UTC 2024
    - 8.6K bytes
    - Viewed (0)
  9. internal/store/store.go

    type Key struct {
    	Name      string
    	Compress  bool
    	Extension string
    	ItemCount int
    }
    
    // String returns the filepath name
    func (k Key) String() string {
    	keyStr := k.Name
    	if k.ItemCount > 1 {
    		keyStr = fmt.Sprintf("%d:%s", k.ItemCount, k.Name)
    	}
    	return keyStr + k.Extension + func() string {
    		if k.Compress {
    			return compressExt
    		}
    		return ""
    	}()
    }
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Fri Sep 06 23:06:30 UTC 2024
    - 4.2K bytes
    - Viewed (0)
  10. cmd/untar.go

    	"bufio"
    	"bytes"
    	"context"
    	"errors"
    	"fmt"
    	"io"
    	"io/fs"
    	"os"
    	"path"
    	"runtime"
    	"sync"
    	"time"
    
    	"github.com/cosnicolaou/pbzip2"
    	"github.com/klauspost/compress/s2"
    	"github.com/klauspost/compress/zstd"
    	gzip "github.com/klauspost/pgzip"
    	"github.com/pierrec/lz4/v4"
    )
    
    // Max bzip2 concurrency across calls. 50% of GOMAXPROCS.
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sun Sep 22 00:33:43 UTC 2024
    - 6K bytes
    - Viewed (0)
Back to top