mirror of
https://github.com/coder/code-server.git
synced 2026-05-07 04:51:59 +02:00
Add shared process active message (#16)
* Add shared process active message * Add client function for calling bootstrap fork
This commit is contained in:
@@ -85,7 +85,8 @@ proto.NewSessionMessage.toObject = function(includeInstance, msg) {
|
||||
envMap: (f = msg.getEnvMap(true)) ? f.toArray() : [],
|
||||
cwd: msg.getCwd(),
|
||||
ttyDimensions: (f = msg.getTtyDimensions()) && proto.TTYDimensions.toObject(includeInstance, f),
|
||||
isFork: msg.getIsFork()
|
||||
isFork: msg.getIsFork(),
|
||||
isBootstrapFork: msg.getIsBootstrapFork()
|
||||
};
|
||||
|
||||
if (includeInstance) {
|
||||
@@ -154,6 +155,10 @@ proto.NewSessionMessage.deserializeBinaryFromReader = function(msg, reader) {
|
||||
var value = /** @type {boolean} */ (reader.readBool());
|
||||
msg.setIsFork(value);
|
||||
break;
|
||||
case 8:
|
||||
var value = /** @type {boolean} */ (reader.readBool());
|
||||
msg.setIsBootstrapFork(value);
|
||||
break;
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
@@ -239,6 +244,13 @@ proto.NewSessionMessage.prototype.serializeBinaryToWriter = function (writer) {
|
||||
f
|
||||
);
|
||||
}
|
||||
f = this.getIsBootstrapFork();
|
||||
if (f) {
|
||||
writer.writeBool(
|
||||
8,
|
||||
f
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -378,6 +390,23 @@ proto.NewSessionMessage.prototype.setIsFork = function(value) {
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional bool is_bootstrap_fork = 8;
|
||||
* Note that Boolean fields may be set to 0/1 when serialized from a Java server.
|
||||
* You should avoid comparisons like {@code val === true/false} in those cases.
|
||||
* @return {boolean}
|
||||
*/
|
||||
proto.NewSessionMessage.prototype.getIsBootstrapFork = function() {
|
||||
return /** @type {boolean} */ (jspb.Message.getFieldProto3(this, 8, false));
|
||||
};
|
||||
|
||||
|
||||
/** @param {boolean} value */
|
||||
proto.NewSessionMessage.prototype.setIsBootstrapFork = function(value) {
|
||||
jspb.Message.setField(this, 8, value);
|
||||
};
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Generated by JsPbCodeGenerator.
|
||||
|
||||
Reference in New Issue
Block a user