Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 5 of 5 for inProgressResources (0.22 sec)

  1. pilot/pkg/status/distribution/reporter.go

    			dpVersion, err := r.ledger.GetPreviousValue(nonce, res.ToModelKey())
    			if err == nil && dpVersion == res.Generation {
    				if _, ok := out.InProgressResources[key]; !ok {
    					out.InProgressResources[key] = len(dataplanes)
    				} else {
    					out.InProgressResources[key] += len(dataplanes)
    				}
    			} else if err != nil {
    				scope.Errorf("Encountered error retrieving version %s of key %s from Store: %v", nonce, key, err)
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Jan 30 17:25:17 UTC 2024
    - 11.5K bytes
    - Viewed (0)
  2. pilot/pkg/status/distribution/report.go

    package distribution
    
    import (
    	"gopkg.in/yaml.v2"
    )
    
    type Report struct {
    	Reporter            string         `json:"reporter"`
    	DataPlaneCount      int            `json:"dataPlaneCount"`
    	InProgressResources map[string]int `json:"inProgressResources"`
    }
    
    func ReportFromYaml(content []byte) (Report, error) {
    	out := Report{}
    	err := yaml.Unmarshal(content, &out)
    	return out, err
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed Nov 17 12:28:05 UTC 2021
    - 971 bytes
    - Viewed (0)
  3. pilot/pkg/status/distribution/reporter_test.go

    	rpt, prunes := r.buildReport()
    	r.removeCompletedResource(prunes)
    	Expect(rpt.DataPlaneCount).To(Equal(2))
    	Expect(rpt.InProgressResources).To(Equal(map[string]int{
    		myResources[0].String(): 2,
    		myResources[1].String(): 1,
    		myResources[2].String(): 2,
    	}))
    	Expect(r.inProgressResources).NotTo(ContainElement(resources[0]))
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Jan 30 17:25:17 UTC 2024
    - 4.4K bytes
    - Viewed (0)
  4. pilot/pkg/status/distribution/report_test.go

    	. "github.com/onsi/gomega"
    	"gopkg.in/yaml.v2"
    
    	"istio.io/istio/pilot/pkg/status"
    )
    
    func TestReportSerialization(t *testing.T) {
    	in := Report{
    		Reporter:       "Me",
    		DataPlaneCount: 10,
    		InProgressResources: map[string]int{
    			(&status.Resource{
    				Name:      "water",
    				Namespace: "default",
    			}).String(): 1,
    		},
    	}
    	outbytes, err := yaml.Marshal(in)
    	RegisterTestingT(t)
    	Expect(err).To(BeNil())
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Oct 31 14:48:28 UTC 2023
    - 1.2K bytes
    - Viewed (0)
  5. pilot/pkg/status/distribution/state.go

    func (c *Controller) handleReport(d Report) {
    	defer c.mu.Unlock()
    	c.mu.Lock()
    	for resstr := range d.InProgressResources {
    		res := *status.ResourceFromString(resstr)
    		if _, ok := c.CurrentState[res]; !ok {
    			c.CurrentState[res] = make(map[string]Progress)
    		}
    		c.CurrentState[res][d.Reporter] = Progress{d.InProgressResources[resstr], d.DataPlaneCount}
    	}
    	c.ObservationTime[d.Reporter] = c.clock.Now()
    }
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue May 23 17:08:31 UTC 2023
    - 7.7K bytes
    - Viewed (0)
Back to top