- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 139 for Unmarshal (0.23 sec)
-
cmd/batch-job-common-types.go
type BatchJobSize int64 // UnmarshalYAML to parse humanized byte values func (s *BatchJobSize) UnmarshalYAML(unmarshal func(interface{}) error) error { var batchExpireSz string err := unmarshal(&batchExpireSz) if err != nil { return err } sz, err := humanize.ParseBytes(batchExpireSz) if err != nil { return err } *s = BatchJobSize(sz)
Go - Registered: Sun Apr 28 19:28:10 GMT 2024 - Last Modified: Thu Feb 01 21:53:26 GMT 2024 - 7.9K bytes - Viewed (0) -
internal/event/config_test.go
{[]byte(`<FilterRule><Name>suffix</Name><Value>foo/bar</Value></FilterRule>`), &FilterRule{"suffix", "foo/bar"}, false}, } for i, testCase := range testCases { result := &FilterRule{} err := xml.Unmarshal(testCase.data, result) expectErr := (err != nil) if expectErr != testCase.expectErr { t.Fatalf("test %v: error: expected: %v, got: %v", i+1, testCase.expectErr, expectErr) } if !testCase.expectErr {
Go - Registered: Sun Apr 28 19:28:10 GMT 2024 - Last Modified: Tue Dec 05 10:16:33 GMT 2023 - 29K bytes - Viewed (0) -
internal/bucket/lifecycle/filter_test.go
}, ObjectSizeGreaterThan: 100 * humanize.MiByte, ObjectSizeLessThan: 100 * humanize.GiByte, } b, err := xml.Marshal(f1) if err != nil { t.Fatalf("Failed to marshal %v", f1) } var f2 Filter err = xml.Unmarshal(b, &f2) if err != nil { t.Fatalf("Failed to unmarshal %s", string(b)) } if f1.ObjectSizeLessThan != f2.ObjectSizeLessThan {
Go - Registered: Sun Apr 28 19:28:10 GMT 2024 - Last Modified: Tue Feb 27 00:01:20 GMT 2024 - 7.2K bytes - Viewed (0) -
cni/pkg/log/uds.go
cniLogs := make([]string, 0) err := json.Unmarshal(body, &cniLogs) if err != nil { log.Errorf("Failed to unmarshal CNI plugin logs: %v", err) return } messages := make([]cniLog, 0, len(cniLogs)) for _, l := range cniLogs { var msg cniLog if err := json.Unmarshal([]byte(l), &msg); err != nil { log.Debugf("Failed to unmarshal CNI plugin log entry: %v", err) continue }
Go - Registered: Wed Apr 24 22:53:08 GMT 2024 - Last Modified: Wed Nov 29 01:05:12 GMT 2023 - 3.3K bytes - Viewed (0) -
schema/serializer.go
var bytes []byte switch v := dbValue.(type) { case []byte: bytes = v case string: bytes = []byte(v) default: return fmt.Errorf("failed to unmarshal JSONB value: %#v", dbValue) } if len(bytes) > 0 { err = json.Unmarshal(bytes, fieldValue.Interface()) } } field.ReflectValueOf(ctx, dst).Set(fieldValue.Elem()) return } // Value implements serializer interface
Go - Registered: Sun Apr 28 09:35:09 GMT 2024 - Last Modified: Mon Mar 18 08:28:46 GMT 2024 - 4.6K bytes - Viewed (0) -
istioctl/pkg/writer/compare/comparator.go
for _, resp := range istiodResponses { istiodDump := &configdump.Wrapper{} err := json.Unmarshal(resp, istiodDump) if err != nil { continue } c.istiod = istiodDump break } if c.istiod == nil { return nil, fmt.Errorf("unable to find config dump in Istiod responses") } envoyDump := &configdump.Wrapper{} err := json.Unmarshal(envoyResponse, envoyDump) if err != nil { return nil, err }
Go - Registered: Wed Apr 24 22:53:08 GMT 2024 - Last Modified: Sun Apr 21 17:42:54 GMT 2024 - 3.7K bytes - Viewed (1) -
internal/bucket/lifecycle/expiration_test.go
expectedErr: errLifecycleDateNotMidnight, }, } for i, tc := range testCases { t.Run(fmt.Sprintf("Test %d", i+1), func(t *testing.T) { var expiration Expiration err := xml.Unmarshal([]byte(tc.inputXML), &expiration) if err != tc.expectedErr { t.Fatalf("%d: Expected %v but got %v", i+1, tc.expectedErr, err) } }) } validationTestCases := []struct { inputXML string
Go - Registered: Sun Apr 28 19:28:10 GMT 2024 - Last Modified: Wed Feb 21 20:28:34 GMT 2024 - 4.1K bytes - Viewed (0) -
istioctl/pkg/version/version.go
Info: istioVersion.BuildInfo{ Version: "MISSING CP ID", }, Revision: "MISSING CP ID", }, }, nil } cpID := xds.IstioControlPlaneInstance{} err = json.Unmarshal([]byte(xdsResponse.ControlPlane.Identifier), &cpID) if err != nil { return nil, fmt.Errorf("could not parse CP Identifier: %w", err) } return &istioVersion.MeshInfo{ istioVersion.ServerInfo{
Go - Registered: Wed Apr 24 22:53:08 GMT 2024 - Last Modified: Fri Mar 15 01:18:49 GMT 2024 - 8.3K bytes - Viewed (0) -
cmd/tier-handlers.go
writeErrorResponseJSON(ctx, w, errorCodes.ToAPIErrWithErr(ErrAdminConfigBadJSON, err), r.URL) return } var cfg madmin.TierConfig json := jsoniter.ConfigCompatibleWithStandardLibrary if err := json.Unmarshal(reqBytes, &cfg); err != nil { writeErrorResponseJSON(ctx, w, toAdminAPIErr(ctx, err), r.URL) return } var ignoreInUse bool if forceStr := r.Form.Get("force"); forceStr != "" {
Go - Registered: Sun Apr 28 19:28:10 GMT 2024 - Last Modified: Thu Feb 15 19:52:44 GMT 2024 - 7.5K bytes - Viewed (0) -
cmd/xl-storage-format_test.go
} // Tests the correctness of constructing XLMetaV1 using jsoniter lib. // The result will be compared with the result obtained from json.unMarshal of the byte data. func TestGetXLMetaV1Jsoniter1(t *testing.T) { xlMetaJSON := getXLMetaBytes(1) var unMarshalXLMeta xlMetaV1Object if err := json.Unmarshal(xlMetaJSON, &unMarshalXLMeta); err != nil { t.Errorf("Unmarshalling failed: %v", err) } var jsoniterXLMeta xlMetaV1Object
Go - Registered: Sun Apr 28 19:28:10 GMT 2024 - Last Modified: Thu Feb 22 06:26:06 GMT 2024 - 17.6K bytes - Viewed (0)