File tree Expand file tree Collapse file tree 3 files changed +1
-19
lines changed
Expand file tree Collapse file tree 3 files changed +1
-19
lines changed Original file line number Diff line number Diff line change @@ -46,4 +46,3 @@ export declare function readConfigJson(formattedConfig: any): Partial<PinpointCo
4646export declare function readRootConfigFile ( ) : { [ key : string ] : any } ;
4747export declare function getMainModulePath ( requireFunction : NodeRequire ) : string | undefined ;
4848export declare function isContainerEnvironment ( ) : boolean ;
49- export declare function initializeConfig ( initOptions ?: { [ key : string ] : any } ) : void ;
Original file line number Diff line number Diff line change @@ -283,20 +283,6 @@ const getValue = (key, configFile) => {
283283 }
284284}
285285
286- const getConfig = ( initOptions ) => {
287- if ( ! agentConfig ) {
288- init ( initOptions )
289- }
290- return agentConfig
291- }
292-
293- const initializeConfig = ( initOptions ) => {
294- clear ( )
295- init ( initOptions )
296- }
297-
298- const clear = ( ) => agentConfig && ( agentConfig = null )
299-
300286//https://github.com/sindresorhus/is-docker
301287const isContainerEnvironment = ( ) => {
302288 return hasDockerEnv ( ) || hasDockerCGroup ( ) || ( process . env [ 'KUBERNETES_SERVICE_HOST' ] && process . env [ 'KUBERNETES_SERVICE_HOST' ] . length > 0 )
@@ -462,13 +448,10 @@ const setConfig = (config) => {
462448const clear2 = ( ) => configInstance && ( configInstance = null )
463449
464450module . exports = {
465- getConfig,
466- clear,
467451 readConfigJson,
468452 readRootConfigFile,
469453 getMainModulePath,
470454 isContainerEnvironment,
471- initializeConfig,
472455 ConfigBuilder,
473456 getConfig2,
474457 setConfig,
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ const TransactionId = require('../lib/context/transaction-id')
88const TraceId = require ( '../lib/context/trace-id' )
99const SpanId = require ( '../lib/context/span-id' )
1010const testConfig = require ( './pinpoint-config-test' )
11- require ( '../lib/config' ) . clear ( )
11+ require ( '../lib/config' ) . clear2 ( )
1212const config = require ( '../lib/config' ) . getConfig2 ( testConfig )
1313const { namedGroupLocationFileName, namedGroupTypeMethod } = require ( '../lib/instrumentation/call-stack' )
1414
You can’t perform that action at this time.
0 commit comments