@@ -61,8 +61,8 @@ func WithPreAllocCacheNumNodes(n int) ChanGraphOption {
61
61
}
62
62
}
63
63
64
- // KVStoreOptions holds parameters for tuning and customizing a graph. DB.
65
- type KVStoreOptions struct {
64
+ // StoreOptions holds parameters for tuning and customizing a graph DB.
65
+ type StoreOptions struct {
66
66
// RejectCacheSize is the maximum number of rejectCacheEntries to hold
67
67
// in the rejection cache.
68
68
RejectCacheSize int
@@ -81,37 +81,37 @@ type KVStoreOptions struct {
81
81
NoMigration bool
82
82
}
83
83
84
- // DefaultOptions returns a KVStoreOptions populated with default values.
85
- func DefaultOptions () * KVStoreOptions {
86
- return & KVStoreOptions {
84
+ // DefaultOptions returns a StoreOptions populated with default values.
85
+ func DefaultOptions () * StoreOptions {
86
+ return & StoreOptions {
87
87
RejectCacheSize : DefaultRejectCacheSize ,
88
88
ChannelCacheSize : DefaultChannelCacheSize ,
89
89
NoMigration : false ,
90
90
}
91
91
}
92
92
93
- // KVStoreOptionModifier is a function signature for modifying the default
94
- // KVStoreOptions .
95
- type KVStoreOptionModifier func (* KVStoreOptions )
93
+ // StoreOptionModifier is a function signature for modifying the default
94
+ // StoreOptions .
95
+ type StoreOptionModifier func (* StoreOptions )
96
96
97
97
// WithRejectCacheSize sets the RejectCacheSize to n.
98
- func WithRejectCacheSize (n int ) KVStoreOptionModifier {
99
- return func (o * KVStoreOptions ) {
98
+ func WithRejectCacheSize (n int ) StoreOptionModifier {
99
+ return func (o * StoreOptions ) {
100
100
o .RejectCacheSize = n
101
101
}
102
102
}
103
103
104
104
// WithChannelCacheSize sets the ChannelCacheSize to n.
105
- func WithChannelCacheSize (n int ) KVStoreOptionModifier {
106
- return func (o * KVStoreOptions ) {
105
+ func WithChannelCacheSize (n int ) StoreOptionModifier {
106
+ return func (o * StoreOptions ) {
107
107
o .ChannelCacheSize = n
108
108
}
109
109
}
110
110
111
111
// WithBatchCommitInterval sets the batch commit interval for the interval batch
112
112
// schedulers.
113
- func WithBatchCommitInterval (interval time.Duration ) KVStoreOptionModifier {
114
- return func (o * KVStoreOptions ) {
113
+ func WithBatchCommitInterval (interval time.Duration ) StoreOptionModifier {
114
+ return func (o * StoreOptions ) {
115
115
o .BatchCommitInterval = interval
116
116
}
117
117
}
0 commit comments