@@ -39,12 +39,12 @@ func init() { //nolint:gochecknoinits
39
39
httpcaddyfile .RegisterDirectiveOrder ("mercure" , "after" , "encode" )
40
40
}
41
41
42
- type JWTConfig struct {
42
+ type jwtConfig struct {
43
43
Key string `json:"key,omitempty"`
44
44
Alg string `json:"alg,omitempty"`
45
45
}
46
46
47
- type TopicSelectorCacheConfig struct {
47
+ type topicSelectorCacheConfig struct {
48
48
MaxEntriesPerShard uint `json:"max_entries_per_shard,omitempty"`
49
49
ShardCount uint `json:"shard_count,omitempty"`
50
50
}
@@ -73,13 +73,13 @@ type Mercure struct {
73
73
Heartbeat * caddy.Duration `json:"heartbeat,omitempty"`
74
74
75
75
// JWT key and signing algorithm to use for publishers.
76
- PublisherJWT JWTConfig `json:"publisher_jwt,omitempty"`
76
+ PublisherJWT jwtConfig `json:"publisher_jwt,omitempty"`
77
77
78
78
// JWK Set URL to use for publishers.
79
79
PublisherJWKSURL string `json:"publisher_jwks_url,omitempty"`
80
80
81
81
// JWT key and signing algorithm to use for subscribers.
82
- SubscriberJWT JWTConfig `json:"subscriber_jwt,omitempty"`
82
+ SubscriberJWT jwtConfig `json:"subscriber_jwt,omitempty"`
83
83
84
84
// JWK Set URL to use for subscribers.
85
85
SubscriberJWKSURL string `json:"subscriber_jwks_url,omitempty"`
@@ -99,7 +99,7 @@ type Mercure struct {
99
99
LRUShardSize * int64 `json:"lru_shard_size,omitempty"`
100
100
101
101
// Triggers use of LRU topic selector cache and avoidance of select priority queue.
102
- TopicSelectorCache * TopicSelectorCacheConfig `json:"cache,omitempty"`
102
+ TopicSelectorCache * topicSelectorCacheConfig `json:"cache,omitempty"`
103
103
104
104
// The name of the authorization cookie. Defaults to "mercureAuthorization".
105
105
CookieName string `json:"cookie_name,omitempty"`
@@ -482,7 +482,7 @@ func (m *Mercure) UnmarshalCaddyfile(d *caddyfile.Dispenser) error { //nolint:fu
482
482
return err
483
483
}
484
484
485
- m .TopicSelectorCache = & TopicSelectorCacheConfig {uint (maxEntriesPerShard ), uint (shardCount )}
485
+ m .TopicSelectorCache = & topicSelectorCacheConfig {uint (maxEntriesPerShard ), uint (shardCount )}
486
486
case "cookie_name" :
487
487
if ! d .NextArg () {
488
488
return d .ArgErr ()
0 commit comments