Add isHeadless attribute to scribe messages
Summary: So we can distinguish between humans and the machines. We can redirect the traffic to different tables based on this attribute if necessary. Reviewed By: danielbuechele Differential Revision: D14025004 fbshipit-source-id: c3a24b5f8a30f24445eaee67843b78ddabfc9d51
This commit is contained in:
committed by
Facebook Github Bot
parent
029377a849
commit
c912dcaf48
@@ -94,7 +94,7 @@ function startFlipper({
|
|||||||
devToolsEnhancer({realtime: true, hostname: 'localhost', port: 8181}),
|
devToolsEnhancer({realtime: true, hostname: 'localhost', port: 8181}),
|
||||||
)
|
)
|
||||||
: createStore(reducers);
|
: createStore(reducers);
|
||||||
const logger = new Logger(store);
|
const logger = new Logger(store, {isHeadless: true});
|
||||||
init(store);
|
init(store);
|
||||||
dispatcher(store, logger);
|
dispatcher(store, logger);
|
||||||
|
|
||||||
|
|||||||
@@ -12,8 +12,12 @@ import ScribeLogger from './ScribeLogger';
|
|||||||
|
|
||||||
var instance: ?LogManager = null;
|
var instance: ?LogManager = null;
|
||||||
|
|
||||||
|
type Args = {
|
||||||
|
isHeadless?: boolean,
|
||||||
|
};
|
||||||
|
|
||||||
export default class LogManager {
|
export default class LogManager {
|
||||||
constructor(store: Store) {
|
constructor(store: Store, args?: Args) {
|
||||||
this.scribeLogger = new ScribeLogger(this);
|
this.scribeLogger = new ScribeLogger(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -53,7 +53,6 @@ export type State = {|
|
|||||||
plugins: PluginsState,
|
plugins: PluginsState,
|
||||||
|};
|
|};
|
||||||
|
|
||||||
// $FlowFixMe introduced when removing $Subtype/$Supertype
|
|
||||||
export type Store = ReduxStore<State, Actions>;
|
export type Store = ReduxStore<State, Actions>;
|
||||||
|
|
||||||
export default combineReducers<_, Actions>({
|
export default combineReducers<_, Actions>({
|
||||||
|
|||||||
Reference in New Issue
Block a user