You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* fixing infinite worker loop
Signed-off-by: Mike Monaghan <mike_monaghan@live.ca>
* Automatically resolve default KinesisEndpoint
This commit fixesvmware-archive#5 by returning `aws.EndpointNotFoundError` from the
endpoint resolver when no `KinesisEndpoint` is defined, which will
resolve the default AWS endpoint. This is the same process used by the
DynamoDB checkpointer to resolve the default endpoint.
Signed-off-by: Caleb Stewart <caleb.stewart94@gmail.com>
* fix: catch DynamoDB Scan error when trying to scan nonexistent table/index in syncLeases()
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* chore: Adding periods to copyright comment to satisfy gofmt
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* feat: Sending renewed lease metric
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* fix: add DeleteMetricMillisBehindLatest for error case
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* Refactor in prep for testing rate limiting improvements
Signed-off-by: John Calixto <jcalixto@vmware.com>
* fix: add getRecords TPS rate limiting
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* fix: add hard cap maxRetries for getRecord errors
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* fix: add maxBytes per second getRecord check
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* chore: log RemoveLeaseOwner errors with debug instead of error
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* fix: add check for GetRecords error within callGetRecordsAPI
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* fix: use nanosecond precision in lease comparisons
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* chore: add info logs in sleep case for kinesis backoff errors
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* fix: Check token bucket corner cases correctly.
Signed-off-by: John Calixto <jcalixto@vmware.com>
* Bump github.com/prometheus/client_golang from 1.11.0 to 1.11.1
Bumps [github.com/prometheus/client_golang](https://github.com/prometheus/client_golang) from 1.11.0 to 1.11.1.
- [Release notes](https://github.com/prometheus/client_golang/releases)
- [Changelog](https://github.com/prometheus/client_golang/blob/main/CHANGELOG.md)
- [Commits](prometheus/client_golang@v1.11.0...v1.11.1)
---
updated-dependencies:
- dependency-name: github.com/prometheus/client_golang
dependency-type: direct:production
...
Signed-off-by: dependabot[bot] <support@github.com>
* Bump golang.org/x/sys from 0.0.0-20211216021012-1d35b9e2eb4e to 0.1.0
Bumps [golang.org/x/sys](https://github.com/golang/sys) from 0.0.0-20211216021012-1d35b9e2eb4e to 0.1.0.
- [Release notes](https://github.com/golang/sys/releases)
- [Commits](https://github.com/golang/sys/commits/v0.1.0)
---
updated-dependencies:
- dependency-name: golang.org/x/sys
dependency-type: indirect
...
Signed-off-by: dependabot[bot] <support@github.com>
* fix: add shutdown and leaseExpired error cases for checkpoint function
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* feat: make lease renewal async
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* fix: return err log in case of ErrLeaseNotAcquired
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* chore: Remove extraneous err check
After checking the scan result above this line, checking err here no
longer has any effect.
Signed-off-by: John Calixto <jcalixto@vmware.com>
* fix: pass in ctx with cancel for renewLease
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
* ran go mod tidy
---------
Signed-off-by: Mike Monaghan <mike_monaghan@live.ca>
Signed-off-by: Caleb Stewart <caleb.stewart94@gmail.com>
Signed-off-by: Shiva Pentakota <spentakota@vmware.com>
Signed-off-by: John Calixto <jcalixto@vmware.com>
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Mike Monaghan <mike_monaghan@live.ca>
Co-authored-by: Caleb Stewart <caleb.stewart94@gmail.com>
Co-authored-by: Shiva Pentakota <spentakota@vmware.com>
Co-authored-by: spentakota <120056013+spentakota@users.noreply.github.com>
Co-authored-by: John Calixto <jcalixto@vmware.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: cmckelvey-vmware <85366153+cmckelvey-vmware@users.noreply.github.com>
Co-authored-by: vmwjc <108959326+vmwjc@users.noreply.github.com>
Copy file name to clipboardExpand all lines: clientlibrary/checkpoint/checkpointer.go
+4-1Lines changed: 4 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,7 @@
20
20
// Package checkpoint
21
21
// The implementation is derived from https://github.com/patrobinson/gokini
22
22
//
23
-
// # Copyright 2018 Patrick robinson
23
+
// Copyright 2018 Patrick robinson.
24
24
//
25
25
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
26
26
//
@@ -79,6 +79,9 @@ type Checkpointer interface {
79
79
// RemoveLeaseOwner to remove lease owner for the shard entry to make the shard available for reassignment
80
80
RemoveLeaseOwner(string) error
81
81
82
+
// GetLeaseOwner to get current owner of lease for shard
83
+
GetLeaseOwner(string) (string, error)
84
+
82
85
// ListActiveWorkers returns active workers and their shards (New Lease Stealing Methods)
Copy file name to clipboardExpand all lines: clientlibrary/checkpoint/dynamodb-checkpointer.go
+33-10Lines changed: 33 additions & 10 deletions
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,7 @@
20
20
// Package checkpoint
21
21
// The implementation is derived from https://github.com/patrobinson/gokini
22
22
//
23
-
// # Copyright 2018 Patrick robinson
23
+
// Copyright 2018 Patrick robinson.
24
24
//
25
25
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
26
26
//
@@ -51,6 +51,10 @@ const (
51
51
NumMaxRetries=10
52
52
)
53
53
54
+
var (
55
+
NoLeaseOwnerErr=errors.New("no LeaseOwner in checkpoints table")
56
+
)
57
+
54
58
// DynamoCheckpoint implements the Checkpoint interface using DynamoDB as a backend
log.Debugf("Lease sync completed. Next lease sync will occur in %s", time.Duration(checkpointer.kclConfig.LeaseSyncingTimeIntervalMillis)*time.Millisecond)
Copy file name to clipboardExpand all lines: clientlibrary/checkpoint/mock-dynamodb_test.go
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -19,7 +19,7 @@
19
19
20
20
// The implementation is derived from https://github.com/patrobinson/gokini
21
21
//
22
-
// Copyright 2018 Patrick robinson
22
+
// Copyright 2018 Patrick robinson.
23
23
//
24
24
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
Copy file name to clipboardExpand all lines: clientlibrary/metrics/cloudwatch/cloudwatch.go
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,7 @@
20
20
// Package cloudwatch
21
21
// The implementation is derived from https://github.com/patrobinson/gokini
22
22
//
23
-
// # Copyright 2018 Patrick robinson
23
+
// Copyright 2018 Patrick robinson.
24
24
//
25
25
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
Copy file name to clipboardExpand all lines: clientlibrary/metrics/interfaces.go
+3-1Lines changed: 3 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,7 @@
20
20
// Package metrics
21
21
// The implementation is derived from https://github.com/patrobinson/gokini
22
22
//
23
-
// Copyright 2018 Patrick robinson
23
+
// Copyright 2018 Patrick robinson.
24
24
//
25
25
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
26
26
//
@@ -35,6 +35,7 @@ type MonitoringService interface {
Copy file name to clipboardExpand all lines: clientlibrary/metrics/prometheus/prometheus.go
+5-1Lines changed: 5 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,7 @@
20
20
// Package prometheus
21
21
// The implementation is derived from https://github.com/patrobinson/gokini
22
22
//
23
-
// # Copyright 2018 Patrick robinson
23
+
// Copyright 2018 Patrick robinson.
24
24
//
25
25
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
Copy file name to clipboardExpand all lines: clientlibrary/partition/partition.go
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,7 @@
20
20
// Package partition
21
21
// The implementation is derived from https://github.com/patrobinson/gokini
22
22
//
23
-
// # Copyright 2018 Patrick robinson
23
+
// Copyright 2018 Patrick robinson.
24
24
//
25
25
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
0 commit comments