-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(MOS): support OpenMedia's hot standby #1169
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## release52 #1169 +/- ##
=============================================
- Coverage 61.31% 61.29% -0.02%
=============================================
Files 468 468
Lines 82107 82107
Branches 4684 5352 +668
=============================================
- Hits 50340 50327 -13
+ Misses 31674 31636 -38
- Partials 93 144 +51 ☔ View full report in Codecov by Sentry. |
…nnections are offline
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not keen on the name 'hot standby', I find that confusing.
I would expect the 'hot standby' mode to be the one where there is a 'hot spare' connection maintained the whole time, not when the connection is 'cold' except when the primary is down.
I would prefer that the field was renamed to be more descriptive to how the connection will behave, and the description could include something like For OpenMedia Hot Standby
to make it clear it should be used with this
…tStandby to openMediaHotStandby
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would be nice if we grouped these out-of-spec behavior flags into some sort of an options object.
@@ -482,6 +488,11 @@ export class MosHandler { | |||
deviceOptions.primary.heartbeatInterval = | |||
deviceOptions.primary.heartbeatInterval || DEFAULT_MOS_HEARTBEAT_INTERVAL | |||
|
|||
if (deviceOptions.secondary?.id && this._openMediaHotStandby[deviceOptions.secondary.id]) { | |||
//@ts-expect-error this is not yet added to the official mos-connection | |||
deviceOptions.secondary.openMediaHotStandby = true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this mean that this PR is not mergable yet? Because there needs to be an update to mos-connection before?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it appears so.
The PR nrkno/sofie-mos-connection#105 has been merged in that repository, but v4.2.0 has only been half created, so cannot be referenced here yet.
It sounds like there are some more changes waiting in mos-connection
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nrkno/sofie-mos-connection#105 Is this the PR?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That was the PR, but there are some additional fixes without a PR yet
About the Contributor
This PR is made on behalf of BBC
Type of Contribution
This is a Feature
Current Behavior
Currently the Primary and Secondary MOS connection are expected to be online at the same time.
New Behavior
OpenMedia treats the Secondary server as a Hot Standby, so it's not connected while Primary server is connected.
To handle this, a "Hot Spare" option is added in settings to the Secondary server.
When hot spare is activated, status messages are:
Testing Instructions
Connect MOS gateway to a 2 server OpenMedia setup.
Time Frame
We intend to finish the development on this feature in two weeks time.
Other Information
Status