Skip to content

Commit

Permalink
Update changelog. Add entity-change and terminators to stream events.
Browse files Browse the repository at this point in the history
  • Loading branch information
plorenz committed Dec 12, 2023
1 parent 95f650d commit d84f3b4
Show file tree
Hide file tree
Showing 2 changed files with 70 additions and 0 deletions.
53 changes: 53 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,56 @@
# Release 0.31.3

## What's New

* Services Max Idle Time
* Add/Remove Peer and Transfer Leadership via REST

## Service Max Idle Time

A max idle time can now be configured on services. The default value of 0 indicates that no maximum will
be enforced. A circuit is considered idle when no traffic is flowing across through the initiating or
terminating router.

```
ziti edge create service test-service --max-idle-time 5m
```

Note that the idle time calculation is done on the router, so if max idle time on a service is less
than the configured scan interval on the router, it make take longer than expected for idle circuits
to be removed.

## Raft Cluster Management via REST

The controller now allows some Raft cluster management operations to be performed via REST.

NOTE: If your cluster is not bootstrapped yet, the REST API won't be available. These will only work on a bootstrapped cluster!

The following operations are now supported:

* Add member
* Remove member
* Transfer leadership

```
ziti fabric raft add-member tls:localhost:6363
ziti fabric raft add-member tls:localhost:6464
ziti fabric raft transfer-leadership
ziti fabric raft transfer-leadership ctrl3
ziti fabric raft remove-member ctrl2
ziti fabric raft remove-member ctrl3
```

## Component Updates and Bug Fixes

* github.com/openziti/edge-api: [v0.26.1 -> v0.26.5](https://github.com/openziti/edge-api/compare/v0.26.1...v0.26.5)
* github.com/openziti/ziti: [v0.31.2 -> v0.31.3](https://github.com/openziti/ziti/compare/v0.31.2...v0.31.3)
* [Issue #1544](https://github.com/openziti/ziti/issues/1544) - Support transfer raft leadership via REST
* [Issue #1543](https://github.com/openziti/ziti/issues/1543) - Support add/remove raft peer via REST
* [Issue #1496](https://github.com/openziti/ziti/issues/1496) - Configurable Timer needed to close idle circuits
* [Issue #1402](https://github.com/openziti/ziti/issues/1402) - Allow router to decomission itself



# Release 0.31.2

## What's New
Expand Down
17 changes: 17 additions & 0 deletions ziti/cmd/fabric/stream_events.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,14 @@ type streamEventsAction struct {
all bool
apiSessions bool
circuits bool
entityChange bool
entityCounts bool
links bool
metrics bool
routers bool
services bool
sessions bool
terminators bool
usage bool

metricsSourceFilter string
Expand Down Expand Up @@ -68,12 +70,14 @@ func NewStreamEventsCmd(p common.OptionsProvider) *cobra.Command {
streamEventsCmd.Flags().BoolVar(&action.all, "all", false, "Include all events")
streamEventsCmd.Flags().BoolVar(&action.apiSessions, "api-sessions", false, "Include api-session events")
streamEventsCmd.Flags().BoolVar(&action.circuits, "circuits", false, "Include circuit events")
streamEventsCmd.Flags().BoolVar(&action.entityChange, "entity-change", false, "Include entity change events")
streamEventsCmd.Flags().BoolVar(&action.entityCounts, "entity-counts", false, "Include entity count events")
streamEventsCmd.Flags().BoolVar(&action.links, "links", false, "Include link events")
streamEventsCmd.Flags().BoolVar(&action.metrics, "metrics", false, "Include metrics events")
streamEventsCmd.Flags().BoolVar(&action.routers, "routers", false, "Include router events")
streamEventsCmd.Flags().BoolVar(&action.services, "services", false, "Include service events")
streamEventsCmd.Flags().BoolVar(&action.sessions, "sessions", false, "Include session events")
streamEventsCmd.Flags().BoolVar(&action.terminators, "terminators", false, "Include terminators events")
streamEventsCmd.Flags().BoolVar(&action.usage, "usage", false, "Include usage events")
streamEventsCmd.Flags().DurationVar(&action.entityCountsInterval, "entity-counts-interval", 5*time.Minute, "Specify the entity count event interval")
streamEventsCmd.Flags().StringVar(&action.metricsSourceFilter, "metrics-source-filter", "", "Specify which sources to stream metrics from")
Expand All @@ -97,6 +101,13 @@ func (self *streamEventsAction) buildSubscriptions(cmd *cobra.Command) []*event.
})
}

if self.entityChange || (self.all && !cmd.Flags().Changed("entity-change")) {
subscription := &event.Subscription{
Type: "entityChange",
}
subscriptions = append(subscriptions, subscription)
}

if self.entityCounts || (self.all && !cmd.Flags().Changed("entity-counts")) {
subscription := &event.Subscription{
Type: "edge.entityCounts",
Expand Down Expand Up @@ -150,6 +161,12 @@ func (self *streamEventsAction) buildSubscriptions(cmd *cobra.Command) []*event.
})
}

if self.terminators || (self.all && !cmd.Flags().Changed("terminators")) {
subscriptions = append(subscriptions, &event.Subscription{
Type: "fabric.terminators",
})
}

if self.usage || (self.all && !cmd.Flags().Changed("usage")) {
subscription := &event.Subscription{
Type: "fabric.usage",
Expand Down

0 comments on commit d84f3b4

Please sign in to comment.