- Sort Score
- Result 10 results
- Languages All
Results 521 - 530 of 1,713 for Take (0.05 sec)
-
docs_src/dependencies/tutorial012_an_py39.py
from typing_extensions import Annotated async def verify_token(x_token: Annotated[str, Header()]): if x_token != "fake-super-secret-token": raise HTTPException(status_code=400, detail="X-Token header invalid") async def verify_key(x_key: Annotated[str, Header()]): if x_key != "fake-super-secret-key": raise HTTPException(status_code=400, detail="X-Key header invalid") return x_key
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Mar 18 12:29:59 UTC 2023 - 756 bytes - Viewed (0) -
cmd/erasure.go
} return } func getOnlineOfflineDisksStats(disksInfo []madmin.Disk) (onlineDisks, offlineDisks madmin.BackendDisks) { onlineDisks = make(madmin.BackendDisks) offlineDisks = make(madmin.BackendDisks) for _, disk := range disksInfo { ep := disk.Endpoint if _, ok := offlineDisks[ep]; !ok { offlineDisks[ep] = 0 } if _, ok := onlineDisks[ep]; !ok {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri Oct 04 22:23:33 UTC 2024 - 16.1K bytes - Viewed (0) -
cmd/data-usage.go
dataUsageInfo.BucketsUsage = make(map[string]BucketUsageInfo, len(dataUsageInfo.BucketSizes)) for bucket, size := range dataUsageInfo.BucketSizes { dataUsageInfo.BucketsUsage[bucket] = BucketUsageInfo{Size: size} } } // For backward compatibility reasons, we need to add this code. if len(dataUsageInfo.BucketSizes) == 0 { dataUsageInfo.BucketSizes = make(map[string]uint64, len(dataUsageInfo.BucketsUsage))
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu May 09 00:51:34 UTC 2024 - 5.6K bytes - Viewed (0) -
cmd/erasure_test.go
} func TestErasureEncodeDecode(t *testing.T) { data := make([]byte, 256) if _, err := io.ReadFull(rand.Reader, data); err != nil { t.Fatalf("Failed to read random data: %v", err) } for i, test := range erasureEncodeDecodeTests { buffer := make([]byte, len(data), 2*len(data)) copy(buffer, data)
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Jul 25 19:37:26 UTC 2022 - 4.8K bytes - Viewed (0) -
callbacks/delete.go
return } case schema.Many2Many: var ( queryConds = make([]clause.Expression, 0, len(rel.References)) foreignFields = make([]*schema.Field, 0, len(rel.References)) relForeignKeys = make([]string, 0, len(rel.References)) modelValue = reflect.New(rel.JoinTable.ModelType).Interface() table = rel.JoinTable.Table
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Fri Feb 25 02:48:23 UTC 2022 - 5.6K bytes - Viewed (0) -
istioctl/pkg/writer/envoy/configdump/endpoint.go
addrs := []*core.Address{ep.GetEndpoint().GetAddress()} for _, a := range ep.GetEndpoint().GetAdditionalAddresses() { addrs = append(addrs, a.GetAddress()) } result := make([]string, 0, len(addrs)) for _, addr := range addrs { if addr := addr.GetSocketAddress(); addr != nil { result = append(result, addr.Address+":"+strconv.Itoa(int(addr.GetPortValue()))) continue }
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Mon Jul 22 09:57:29 UTC 2024 - 6.1K bytes - Viewed (0) -
schema/utils.go
queryValues := make([]interface{}, len(foreignValues)) if len(foreignKeys) == 1 { for idx, r := range foreignValues { queryValues[idx] = r[0] } return clause.Column{Table: table, Name: foreignKeys[0]}, queryValues } columns := make([]clause.Column, len(foreignKeys)) for idx, key := range foreignKeys {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Sat Aug 19 13:35:14 UTC 2023 - 5.5K bytes - Viewed (0) -
cmd/peer-rest-client.go
if !globalIsDistErasure { // Only useful in distributed setups return nil, nil } hosts := endpoints.hostsSorted() remote = make([]*peerRESTClient, 0, len(hosts)) all = make([]*peerRESTClient, len(hosts)) for i, host := range hosts { if host == nil { continue } all[i] = newPeerRESTClient(host, endpoints.FindGridHostsFromPeer(host))
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Sep 09 16:58:30 UTC 2024 - 26.1K bytes - Viewed (0) -
internal/store/batch.go
} // NewBatch creates a new batch func NewBatch[I any](config BatchConfig[I]) *Batch[I] { if config.CommitTimeout == 0 { config.CommitTimeout = defaultCommitTimeout } quitCh := make(chan struct{}) batch := &Batch[I]{ items: make([]I, 0, config.Limit), limit: config.Limit, store: config.Store, quitCh: quitCh, } if batch.store != nil { go func() {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri Sep 06 23:06:30 UTC 2024 - 2.9K bytes - Viewed (0) -
cmd/erasure-multipart.go
var buffer []byte switch size := data.Size(); { case size == 0: buffer = make([]byte, 1) // Allocate at least a byte to reach EOF case size == -1: if size := data.ActualSize(); size > 0 && size < fi.Erasure.BlockSize { // Account for padding and forced compression overhead and encryption. buffer = make([]byte, data.ActualSize()+256+32+32, data.ActualSize()*2+512) } else {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Sun Sep 29 22:40:36 UTC 2024 - 44.7K bytes - Viewed (0)