Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 781 for ledger (0.17 sec)

  1. pkg/ledger/ledger.go

    )
    
    // Ledger exposes a modified map with three unique characteristics:
    // 1. every unique state of the map is given a unique hash
    // 2. prior states of the map are retained for a fixed period of time
    // 2. given a previous hash, we can retrieve a previous state from the map, if it is still retained.
    type Ledger interface {
    	// Put adds or overwrites a key in the Ledger
    	Put(key, value string) (string, error)
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue May 23 17:08:31 UTC 2023
    - 3.9K bytes
    - Viewed (0)
  2. pilot/pkg/status/distribution/ledger.go

    	"istio.io/istio/pkg/config"
    	"istio.io/istio/pkg/ledger"
    )
    
    func tryLedgerPut(configLedger ledger.Ledger, obj config.Config) {
    	key := obj.Key()
    	if _, err := configLedger.Put(key, strconv.FormatInt(obj.Generation, 10)); err != nil {
    		scope.Errorf("Failed to update %s in ledger, status will be out of date.", key)
    	}
    }
    
    func tryLedgerDelete(configLedger ledger.Ledger, obj config.Config) {
    	key := obj.Key()
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue May 23 17:08:31 UTC 2023
    - 1.1K bytes
    - Viewed (0)
  3. pilot/pkg/model/disabled_ledger.go

    // limitations under the License.
    
    package model
    
    import (
    	"errors"
    
    	"istio.io/istio/pkg/ledger"
    )
    
    // DisabledLedger is an empty mock of the ledger.Ledger interface
    // which we will substitute when distribution tracking is disabled.
    type DisabledLedger struct {
    	ledger.Ledger
    }
    
    func (d *DisabledLedger) Put(key, value string) (string, error) {
    	return "", nil
    }
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue May 23 17:08:31 UTC 2023
    - 1.3K bytes
    - Viewed (0)
  4. test/typeparam/issue50690a.go

    		sum += args[i]
    	}
    	return sum
    }
    
    // Ledger is an identifiable, financial record.
    type Ledger[T ~string, K Numeric] struct {
    	// ID identifies the ledger.
    	ID_ T
    
    	// Amounts is a list of monies associated with this ledger.
    	Amounts_ []K
    
    	// SumFn is a function that can be used to sum the amounts
    	// in this ledger.
    	SumFn_ func(...K) K
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Mar 09 21:26:42 UTC 2022
    - 1.6K bytes
    - Viewed (0)
  5. pilot/pkg/bootstrap/util.go

    	"istio.io/istio/pkg/ledger"
    )
    
    func hasKubeRegistry(registries []string) bool {
    	for _, r := range registries {
    		if provider.ID(r) == provider.Kubernetes {
    			return true
    		}
    	}
    	return false
    }
    
    func buildLedger(ca RegistryOptions) ledger.Ledger {
    	var result ledger.Ledger
    	if ca.DistributionTrackingEnabled {
    		result = ledger.Make(ca.DistributionCacheRetention)
    	} else {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue May 23 17:08:31 UTC 2023
    - 1.1K bytes
    - Viewed (0)
  6. pilot/pkg/status/distribution/reporter_test.go

    	out.reverseStatus = make(map[string]sets.String)
    	out.status = make(map[string]string)
    	return
    }
    
    func TestBuildReport(t *testing.T) {
    	RegisterTestingT(t)
    	r := initReporterWithoutStarting()
    	r.ledger = ledger.Make(time.Minute)
    	resources := []*config.Config{
    		{
    			Meta: config.Meta{
    				Namespace:       "default",
    				Name:            "foo",
    				ResourceVersion: "1",
    			},
    		},
    		{
    			Meta: config.Meta{
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Jan 30 17:25:17 UTC 2024
    - 4.4K bytes
    - Viewed (0)
  7. pilot/pkg/status/distribution/reporter.go

    	dataField = "distribution-report"
    )
    
    // Init starts all the read only features of the reporter, used for nonce generation
    // and responding to istioctl wait.
    func (r *Reporter) Init(ledger ledger.Ledger, stop <-chan struct{}) {
    	r.ledger = ledger
    	if r.clock == nil {
    		r.clock = clock.RealClock{}
    	}
    	r.distributionEventQueue = make(chan distributionEvent, 100_000)
    	r.status = make(map[string]string)
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Jan 30 17:25:17 UTC 2024
    - 11.5K bytes
    - Viewed (0)
  8. pkg/ledger/ledger_test.go

    		})
    	}
    	if err := eg.Wait(); err != nil {
    		b.Fatalf("An error occurred putting new data on the ledger: %v", err)
    	}
    	b.StopTimer()
    }
    
    // nolint: gosec
    // test only code
    func addConfig(ledger Ledger, b *testing.B) string {
    	objectID := strings.Replace(uuid.New().String(), "-", "", -1)
    	_, err := ledger.Put(objectID, fmt.Sprintf("%d", rand.Int()))
    	assert.NoError(b, err)
    	return objectID
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed Jul 12 16:12:59 UTC 2023
    - 4K bytes
    - Viewed (0)
  9. pilot/pkg/model/context.go

    	return
    }
    
    func (e *Environment) ClusterLocal() ClusterLocalProvider {
    	return e.clusterLocalServices
    }
    
    func (e *Environment) GetLedger() ledger.Ledger {
    	return e.ledger
    }
    
    func (e *Environment) SetLedger(l ledger.Ledger) {
    	e.ledger = l
    }
    
    func (e *Environment) GetProxyConfigOrDefault(ns string, labels, annotations map[string]string, meshConfig *meshconfig.MeshConfig) *meshconfig.ProxyConfig {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Jun 03 08:29:05 UTC 2024
    - 33.6K bytes
    - Viewed (0)
  10. pkg/ledger/smt_tools.go

    // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    // See the License for the specific language governing permissions and
    // limitations under the License.
    
    package ledger
    
    import (
    	"bytes"
    )
    
    // Get fetches the value of a key by going down the current trie root.
    func (s *smt) Get(key []byte) ([]byte, error) {
    	return s.GetPreviousValue(s.Root(), key)
    }
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue May 23 17:08:31 UTC 2023
    - 1.9K bytes
    - Viewed (0)
Back to top