Search Options

Results per page
Sort
Preferred Languages
Advance

Results 51 - 60 of 83 for Marshal (0.16 sec)

  1. internal/grid/handlers.go

    		},
    	}
    	return func() RT { return pool.Get().(RT) },
    		func(r RT) {
    			if r != rZero {
    				pool.Put(r)
    			}
    		}
    }
    
    // NewSingleHandler creates a typed handler that can provide Marshal/Unmarshal.
    // Use Register to register a server handler.
    // Use Call to initiate a clientside call.
    func NewSingleHandler[Req, Resp RoundTripper](h HandlerID, newReq func() Req, newResp func() Resp) *SingleHandler[Req, Resp] {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Apr 23 17:15:52 GMT 2024
    - 27.1K bytes
    - Viewed (0)
  2. cmd/admin-handlers-pools.go

    		writeErrorResponseJSON(ctx, w, toAPIError(ctx, err), r.URL)
    		return
    	}
    
    	// Rebalance routine is run on the first node of any pool participating in rebalance.
    	pools.StartRebalance()
    
    	b, err := json.Marshal(struct {
    		ID string `json:"id"`
    	}{ID: id})
    	if err != nil {
    		writeErrorResponseJSON(ctx, w, toAPIError(ctx, err), r.URL)
    		return
    	}
    
    	writeSuccessResponseJSON(w, b)
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 10.9K bytes
    - Viewed (0)
  3. cmd/bucket-handlers.go

    	if err != nil {
    		apiErr := errorCodes.ToAPIErr(ErrInvalidArgument)
    		apiErr.Description = err.Error()
    		writeErrorResponse(ctx, w, apiErr, r.URL)
    		return
    	}
    
    	configData, err := xml.Marshal(config)
    	if err != nil {
    		writeErrorResponse(ctx, w, toAPIError(ctx, err), r.URL)
    		return
    	}
    
    	// Deny object locking configuration settings on existing buckets without object lock enabled.
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 25 16:27:27 GMT 2024
    - 61.6K bytes
    - Viewed (0)
  4. cmd/iam-etcd-store.go

    func (ies *IAMEtcdStore) getUsersSysType() UsersSysType {
    	return ies.usersSysType
    }
    
    func (ies *IAMEtcdStore) saveIAMConfig(ctx context.Context, item interface{}, itemPath string, opts ...options) error {
    	data, err := json.Marshal(item)
    	if err != nil {
    		return err
    	}
    	if GlobalKMS != nil {
    		data, err = config.EncryptBytes(GlobalKMS, data, kms.Context{
    			minioMetaBucket: path.Join(minioMetaBucket, itemPath),
    		})
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 13.6K bytes
    - Viewed (0)
  5. logger/sql_test.go

    		return nil, nil
    	}
    	return json.RawMessage(j).MarshalJSON()
    }
    
    type ExampleStruct struct {
    	Name string
    	Val  string
    }
    
    func (s ExampleStruct) Value() (driver.Value, error) {
    	return json.Marshal(s)
    }
    
    func format(v []byte, escaper string) string {
    	return escaper + strings.ReplaceAll(string(v), escaper, escaper+escaper) + escaper
    }
    
    func TestExplainSQL(t *testing.T) {
    	type role string
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Thu Mar 21 08:00:02 GMT 2024
    - 8.4K bytes
    - Viewed (0)
  6. cmd/batch-handlers.go

    	ctx       context.Context      `msg:"-"`
    }
    
    func notifyEndpoint(ctx context.Context, ri *batchJobInfo, endpoint, token string) error {
    	if endpoint == "" {
    		return nil
    	}
    
    	buf, err := json.Marshal(ri)
    	if err != nil {
    		return err
    	}
    
    	ctx, cancel := context.WithTimeout(ctx, 10*time.Second)
    	defer cancel()
    
    	req, err := http.NewRequestWithContext(ctx, http.MethodPost, endpoint, bytes.NewReader(buf))
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sun May 05 16:56:21 GMT 2024
    - 55.2K bytes
    - Viewed (0)
  7. cni/pkg/plugin/plugin.go

    	}
    
    	log.Debugf("istio-cni: Config is: %+v", conf)
    	// Parse previous result. Remove this if your plugin is not chained.
    	if conf.RawPrevResult != nil {
    		resultBytes, err := json.Marshal(conf.RawPrevResult)
    		if err != nil {
    			return nil, fmt.Errorf("could not serialize prevResult: %v", err)
    		}
    		res, err := version.NewResult(conf.CNIVersion, resultBytes)
    		if err != nil {
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Wed May 08 15:58:51 GMT 2024
    - 10.5K bytes
    - Viewed (0)
  8. istioctl/pkg/workload/workload_test.go

    	}
    }
    
    func TestWorkloadEntryToPodPortsMeta(t *testing.T) {
    	cases := []struct {
    		description string
    		ports       map[string]uint32
    		want        string
    	}{
    		{
    			description: "test json marshal",
    			ports: map[string]uint32{
    				"HTTP":  80,
    				"HTTPS": 443,
    			},
    			want: `[{"name":"HTTP","containerPort":80,"protocol":""},{"name":"HTTPS","containerPort":443,"protocol":""}]`,
    		},
    	}
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Wed Mar 27 16:59:05 GMT 2024
    - 14.6K bytes
    - Viewed (0)
  9. cmd/xl-storage-format-v2_test.go

    			t.Fatal(err)
    		}
    		vers = append(vers, xl.versions)
    	}
    	for _, v2 := range vers {
    		for _, ver := range v2 {
    			b, _ := json.Marshal(ver.header)
    			t.Log(string(b))
    			var x xlMetaV2Version
    			_, _ = x.unmarshalV(0, ver.meta)
    			b, _ = json.Marshal(x)
    			t.Log(string(b), x.getSignature())
    		}
    	}
    
    	for i := range vers {
    		t.Run(fmt.Sprintf("non-strict-q%d", i), func(t *testing.T) {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri Mar 08 17:50:48 GMT 2024
    - 36.4K bytes
    - Viewed (0)
  10. internal/event/target/nats.go

    	objectName, err := url.QueryUnescape(eventData.S3.Object.Key)
    	if err != nil {
    		return err
    	}
    	key := eventData.S3.Bucket.Name + "/" + objectName
    
    	data, err := json.Marshal(event.Log{EventName: eventData.EventName, Key: key, Records: []event.Event{eventData}})
    	if err != nil {
    		return err
    	}
    
    	if target.stanConn != nil {
    		if target.args.Streaming.Async {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Feb 27 18:11:55 GMT 2024
    - 12.8K bytes
    - Viewed (0)
Back to top