Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 80 for item (0.22 sec)

  1. internal/store/queuestore.go

    	buf.Reset()
    	if err != nil {
    		return err
    	}
    
    	// Increment the item count.
    	store.entries[key] = time.Now().UnixNano()
    
    	return nil
    }
    
    // write - writes an item to the directory.
    func (store *QueueStore[I]) write(key string, item I) error {
    	// Marshalls the item.
    	eventData, err := json.Marshal(item)
    	if err != nil {
    		return err
    	}
    
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Mon Mar 25 16:44:20 GMT 2024
    - 7.1K bytes
    - Viewed (0)
  2. internal/store/batch_test.go

    				t.Errorf("failed to get the item by key %v after adding", item)
    			}
    		}(i)
    	}
    	wg.Wait()
    
    	keys, items, err := batch.GetAll()
    	if err != nil {
    		t.Fatalf("unable to get the items from the batch; %v", err)
    	}
    	if len(items) != int(limit) {
    		t.Fatalf("expected batch length %v but got %v", limit, len(items))
    	}
    	if len(keys) != int(limit) {
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Sat Oct 07 15:07:38 GMT 2023
    - 3.8K bytes
    - Viewed (0)
  3. cmd/admin-handlers-site-replication.go

    	case madmin.SRBucketMetaTypeObjectLockConfig:
    		err = globalSiteReplicationSys.PeerBucketObjectLockConfigHandler(ctx, item.Bucket, item.ObjectLockConfig, item.UpdatedAt)
    	case madmin.SRBucketMetaTypeSSEConfig:
    		err = globalSiteReplicationSys.PeerBucketSSEConfigHandler(ctx, item.Bucket, item.SSEConfig, item.UpdatedAt)
    	case madmin.SRBucketMetaLCConfig:
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Apr 15 09:40:39 GMT 2024
    - 19.4K bytes
    - Viewed (0)
  4. internal/store/queuestore_test.go

    				t.Fatal("Failed to Get the item from the queue store ", eErr)
    			}
    			if !reflect.DeepEqual(testItem, item) {
    				t.Fatalf("Failed to read the item: error: expected = %v, got = %v", testItem, item)
    			}
    		}
    	} else {
    		t.Fatalf("List() Expected: 10, got %d", len(itemKeys))
    	}
    }
    
    // TestQueueStoreDel - tests for store.Del
    func TestQueueStoreDel(t *testing.T) {
    	defer func() {
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Tue Apr 04 17:52:24 GMT 2023
    - 5.9K bytes
    - Viewed (0)
  5. internal/store/store.go

    // Target - store target interface
    type Target interface {
    	Name() string
    	SendFromStore(key Key) error
    }
    
    // Store - Used to persist items.
    type Store[I any] interface {
    	Put(item I) error
    	PutMultiple(item []I) error
    	Get(key string) (I, error)
    	GetRaw(key string) ([]byte, error)
    	Len() int
    	List() ([]string, error)
    	Del(key string) error
    	DelList(key []string) error
    	Open() error
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Mon Mar 25 16:44:20 GMT 2024
    - 3.5K bytes
    - Viewed (0)
  6. operator/cmd/mesh/manifest-diff.go

    	// The format of each list item is :: and the items are comma separated. The * character represents wildcard selection.
    	// e.g.
    	// Deployment:istio-system:* - compare all deployments in istio-system namespace
    	// Service:*:istio-pilot - compare Services called "istio-pilot" in all namespaces.
    	selectResources string
    	// ignoreResources ignores all listed items during comparison. It uses the same list format as selectResources.
    Go
    - Registered: Wed Mar 20 22:53:08 GMT 2024
    - Last Modified: Fri Mar 15 01:18:49 GMT 2024
    - 5.8K bytes
    - Viewed (0)
  7. cmd/iam-etcd-store.go

    }
    
    func getIAMConfig(item interface{}, data []byte, itemPath string) error {
    	data, err := decryptData(data, itemPath)
    	if err != nil {
    		return err
    	}
    	json := jsoniter.ConfigCompatibleWithStandardLibrary
    	return json.Unmarshal(data, item)
    }
    
    func (ies *IAMEtcdStore) loadIAMConfig(ctx context.Context, item interface{}, path string) error {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 13.6K bytes
    - Viewed (0)
  8. internal/pubsub/pubsub.go

    // Hence receivers should use buffered channel so as not to miss the published events.
    func (ps *PubSub[T, M]) Publish(item T) {
    	ps.RLock()
    	defer ps.RUnlock()
    	for _, sub := range ps.subs {
    		if sub.types.Contains(Mask(item.Mask())) && (sub.filter == nil || sub.filter(item)) {
    			select {
    			case sub.ch <- item:
    			default:
    			}
    		}
    	}
    }
    
    // Subscribe - Adds a subscriber to pubsub system
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Tue Feb 06 16:57:30 GMT 2024
    - 5.2K bytes
    - Viewed (0)
  9. cmd/iam-object-store.go

    	res := make(map[string][]string)
    	ctx, cancel := context.WithCancel(ctx)
    	defer cancel()
    	for item := range listIAMConfigItems(ctx, iamOS.objAPI, iamConfigPrefix+SlashSeparator) {
    		if item.Err != nil {
    			return nil, item.Err
    		}
    
    		lastIndex := strings.HasPrefix(item.Item, policyDBPrefix)
    		listKey, trimmedItem := splitPath(item.Item, lastIndex)
    		if listKey == iamFormatFile {
    			continue
    		}
    
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Apr 05 21:26:41 GMT 2024
    - 19.9K bytes
    - Viewed (0)
  10. tests/hooks_test.go

    	var productWithItem Product4
    	if err := DB.Session(&gorm.Session{SkipHooks: true}).Preload("Item").First(&productWithItem, "name = ?", product.Name).Error; err != nil {
    		t.Errorf("should find product, but got error %v", err)
    	}
    
    	if productWithItem.Item.AfterFindCallTimes != 0 {
    		t.Fatalf("AfterFind should not be called times:%d", productWithItem.Item.AfterFindCallTimes)
    	}
    }
    
    type Product5 struct {
    	gorm.Model
    	Name string
    Go
    - Registered: Sun Apr 28 09:35:09 GMT 2024
    - Last Modified: Sat Feb 18 01:20:29 GMT 2023
    - 15.9K bytes
    - Viewed (0)
Back to top