-
-
Notifications
You must be signed in to change notification settings - Fork 55
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
add region
field to balancer protocol
#1124
Conversation
1 failed test on run #672 ↗︎
Details:
client/tests/e2e/component/RoomSettingsForm.cy.ts • 1 failed test • Component - electron
Review all test suite changes for PR #1124 ↗︎ |
let init = M2BInit { port: http_port }; | ||
let init = M2BInit { | ||
port: http_port, | ||
region: "unknown".into(), |
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.
what does .into() do?
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.
It comes from the Into
trait. https://doc.rust-lang.org/std/convert/trait.Into.html
You can read more in depth about From
/Into
here: https://practice.rs/type-conversions/from-into.html Specifically, this into()
converts a &'static str
into a String
.
@@ -93,6 +93,7 @@ pub enum MsgM2B { | |||
pub struct M2BInit { | |||
/// The port that the monolith is listening for HTTP requests on. | |||
pub port: u16, | |||
pub region: String, | |||
} | |||
|
|||
#[derive(Debug, Clone, Serialize, Deserialize)] |
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.
line 99?
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.
derive
invokes derive macros. They are macros that automatically implement traits for you. For example, #[derive(Clone)]
will automatically implement Clone
, and allow you to call clone()
on the type that it's implemented for.
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.
This file won't let me comment on individual lines so:
wss.on()?
this.emit() - emits to what?
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.
wss is a WebSocket.Server
from the ws
node js package.
on(event, handler)
runs handler
whenever event
is emitted by the object.
this
in that context is BalancerManager
, which has an event bus that emits events from BalancerManagerEvemts
(which ive just realized I've typod)
@@ -513,6 +519,11 @@ function postProcessConfig(): void { | |||
if (conf.get("mail.enabled")) { | |||
validateMail(); |
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.
what does mail mean in this context?
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.
email. used for password recovery emails.
closes #1121