Skip to content

Commit 5754c39

Browse files
committed
set default log mode to 'bus'
1 parent b5a8073 commit 5754c39

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

packages/monitor/lib/monitor-options.js

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -111,14 +111,12 @@ export class WindowOptions {
111111
*/
112112
export const LogModes = {
113113
/**
114-
* Logs by tailing the app's log files. Slight lag, but can result in better formatting than bus.
115-
* @type {string}
114+
* Logs by tailing the app's log files. Slight lag, but can result in better formatting than bus. Not recommended, as logs cannot be rotated by launchpad.
116115
*/
117116
TailLogFile: 'file',
118117

119118
/**
120119
* Logs directly from the app's stdout/stderr bus. Can result in interrupted logs if the buffer isn't consistently flushed by an app.
121-
* @type {string}
122120
*/
123121
LogBusEvents: 'bus',
124122
};
@@ -129,7 +127,7 @@ export const LogModes = {
129127
export class AppLogOptions {
130128
constructor({
131129
logToLaunchpadDir = true,
132-
mode = LogModes.TailLogFile,
130+
mode = LogModes.LogBusEvents,
133131
showStdout = true,
134132
showStderr = true,
135133
} = {}) {
@@ -142,10 +140,10 @@ export class AppLogOptions {
142140

143141
/**
144142
* How to grab the app's logs. Supported values:
145-
* - `'file'`: Logs by tailing the app's log files. Slight lag, but can result in better formatting than bus.
146143
* - `'bus'`: Logs directly from the app's stdout/stderr bus. Can result in interrupted logs if the buffer isn't consistently flushed by an app.
147-
* @type {string}
148-
* @default 'file'
144+
* - `'file'`: Logs by tailing the app's log files. Slight lag, but can result in better formatting than bus. Not recommended, as logs cannot be rotated by launchpad.
145+
* @type {'bus' | 'file'}
146+
* @default 'bus'
149147
*/
150148
this.mode = mode;
151149

@@ -162,6 +160,7 @@ export class AppLogOptions {
162160
* @default true
163161
*/
164162
this.showStderr = showStderr;
163+
165164
}
166165
}
167166

0 commit comments

Comments
 (0)