Skip to content

Commit 0c3e475

Browse files
mniewrzalStorj Robot
authored andcommitted
satellite/orders: remove unused flag
Change-Id: If73905c20142d40542baf6d843c86c920de9a489
1 parent 6810282 commit 0c3e475

File tree

6 files changed

+6
-24
lines changed

6 files changed

+6
-24
lines changed

private/testplanet/satellite.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -445,7 +445,6 @@ func (planet *Planet) newSatellite(ctx context.Context, prefix string, index int
445445
config.Debug.Addr = ""
446446
config.Reputation.AuditHistory.OfflineDQEnabled = false
447447
config.Server.Config.Extensions.Revocation = false
448-
config.Orders.OrdersSemaphoreSize = 0
449448
config.Checker.NodeFailureRate = 0
450449
config.Audit.MaxRetriesStatDB = 0
451450
config.GarbageCollection.RetainSendTimeout = 0

satellite/api.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -406,7 +406,6 @@ func NewAPI(log *zap.Logger, full *identity.FullIdentity, db DB,
406406
satelliteSignee,
407407
peer.Orders.DB,
408408
peer.DB.NodeAPIVersion(),
409-
config.Orders.OrdersSemaphoreSize,
410409
peer.Orders.Service,
411410
)
412411

satellite/console-api.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,6 @@ func NewConsoleAPI(log *zap.Logger, full *identity.FullIdentity, db DB,
313313
satelliteSignee,
314314
peer.Orders.DB,
315315
peer.DB.NodeAPIVersion(),
316-
config.Orders.OrdersSemaphoreSize,
317316
peer.Orders.Service,
318317
)
319318

satellite/orders/endpoint.go

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -177,27 +177,16 @@ type Endpoint struct {
177177
satelliteSignee signing.Signee
178178
DB DB
179179
nodeAPIVersionDB nodeapiversion.DB
180-
ordersSemaphore chan struct{}
181180
ordersService *Service
182181
}
183182

184183
// NewEndpoint new orders receiving endpoint.
185-
//
186-
// ordersSemaphoreSize controls the number of concurrent clients allowed to submit orders at once.
187-
// A value of zero means unlimited.
188-
func NewEndpoint(log *zap.Logger, satelliteSignee signing.Signee, db DB, nodeAPIVersionDB nodeapiversion.DB,
189-
ordersSemaphoreSize int, ordersService *Service) *Endpoint {
190-
var ordersSemaphore chan struct{}
191-
if ordersSemaphoreSize > 0 {
192-
ordersSemaphore = make(chan struct{}, ordersSemaphoreSize)
193-
}
194-
184+
func NewEndpoint(log *zap.Logger, satelliteSignee signing.Signee, db DB, nodeAPIVersionDB nodeapiversion.DB, ordersService *Service) *Endpoint {
195185
return &Endpoint{
196186
log: log,
197187
satelliteSignee: satelliteSignee,
198188
DB: db,
199189
nodeAPIVersionDB: nodeAPIVersionDB,
200-
ordersSemaphore: ordersSemaphore,
201190
ordersService: ordersService,
202191
}
203192
}

satellite/orders/service.go

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,12 +34,11 @@ var (
3434

3535
// Config is a configuration struct for orders Service.
3636
type Config struct {
37-
EncryptionKeys EncryptionKeys `help:"encryption keys to encrypt info in orders" default:""`
38-
Expiration time.Duration `help:"how long until an order expires" default:"24h" testDefault:"168h"` // default is 1 day
39-
FlushBatchSize int `help:"how many items in the rollups write cache before they are flushed to the database" devDefault:"20" releaseDefault:"1000" testDefault:"10"`
40-
FlushInterval time.Duration `help:"how often to flush the rollups write cache to the database" devDefault:"30s" releaseDefault:"1m" testDefault:"$TESTINTERVAL"`
41-
NodeStatusLogging bool `hidden:"true" help:"deprecated, log the offline/disqualification status of nodes" default:"false" testDefault:"true"`
42-
OrdersSemaphoreSize int `help:"how many concurrent orders to process at once. zero is unlimited" default:"2"`
37+
EncryptionKeys EncryptionKeys `help:"encryption keys to encrypt info in orders" default:""`
38+
Expiration time.Duration `help:"how long until an order expires" default:"24h" testDefault:"168h"` // default is 1 day
39+
FlushBatchSize int `help:"how many items in the rollups write cache before they are flushed to the database" devDefault:"20" releaseDefault:"1000" testDefault:"10"`
40+
FlushInterval time.Duration `help:"how often to flush the rollups write cache to the database" devDefault:"30s" releaseDefault:"1m" testDefault:"$TESTINTERVAL"`
41+
NodeStatusLogging bool `hidden:"true" help:"deprecated, log the offline/disqualification status of nodes" default:"false" testDefault:"true"`
4342

4443
DownloadTailToleranceOverrides string `help:"how many nodes should be used for downloads for certain k. must be >= k. if not specified, this is calculated from long tail tolerance. format is comma separated like k-d,k-d,k-d e.g. 29-35,3-5." default:""`
4544
}

satellite/satellite-config.yaml.lock

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1100,9 +1100,6 @@ identity.key-path: /root/.local/share/storj/identity/satellite/identity.key
11001100
# how often to flush the rollups write cache to the database
11011101
# orders.flush-interval: 1m0s
11021102

1103-
# how many concurrent orders to process at once. zero is unlimited
1104-
# orders.orders-semaphore-size: 2
1105-
11061103
# default AS OF SYSTEM TIME for service
11071104
# overlay.as-of-system-time: -10s
11081105

0 commit comments

Comments
 (0)