@@ -91,8 +91,8 @@ export default class HazelcastClient {
9191 this . instanceName = 'hz.client_' + this . id ;
9292 }
9393
94- LoggingService . initialize ( this . config . properties [ 'hazelcast.logging' ] as string ) ;
95- this . loggingService = LoggingService . getLoggingService ( ) ;
94+ this . loggingService = new LoggingService ( this . config . properties [ 'hazelcast.logging' ] ,
95+ this . config . properties [ 'hazelcast.logging.level' ] as number ) ;
9696 this . invocationService = new InvocationService ( this ) ;
9797 this . listenerService = new ListenerService ( this ) ;
9898 this . serializationService = new SerializationServiceV1 ( this . config . serializationConfig ) ;
@@ -398,10 +398,10 @@ export default class HazelcastClient {
398398 this . proxyManager . init ( ) ;
399399 this . listenerService . start ( ) ;
400400 this . statistics . start ( ) ;
401- this . loggingService . info ( 'HazelcastClient' , 'Client started' ) ;
401+ this . loggingService . getLogger ( ) . info ( 'HazelcastClient' , 'Client started' ) ;
402402 return this ;
403403 } ) . catch ( ( e ) => {
404- this . loggingService . error ( 'HazelcastClient' , 'Client failed to start' , e ) ;
404+ this . loggingService . getLogger ( ) . error ( 'HazelcastClient' , 'Client failed to start' , e ) ;
405405 throw e ;
406406 } ) ;
407407 }
@@ -412,7 +412,7 @@ export default class HazelcastClient {
412412 const urlEndpoint = HazelcastCloudDiscovery . createUrlEndpoint ( this . getConfig ( ) . properties ,
413413 cloudConfig . discoveryToken ) ;
414414 return new HazelcastCloudAddressTranslator ( urlEndpoint , this . getConnectionTimeoutMillis ( ) ,
415- this . loggingService ) ;
415+ this . loggingService . getLogger ( ) ) ;
416416 }
417417 return new DefaultAddressTranslator ( ) ;
418418
@@ -436,7 +436,8 @@ export default class HazelcastClient {
436436 if ( cloudConfig . enabled ) {
437437 const discoveryToken = cloudConfig . discoveryToken ;
438438 const urlEndpoint = HazelcastCloudDiscovery . createUrlEndpoint ( this . getConfig ( ) . properties , discoveryToken ) ;
439- return new HazelcastCloudAddressProvider ( urlEndpoint , this . getConnectionTimeoutMillis ( ) , this . loggingService ) ;
439+ return new HazelcastCloudAddressProvider ( urlEndpoint , this . getConnectionTimeoutMillis ( ) ,
440+ this . loggingService . getLogger ( ) ) ;
440441 }
441442 return null ;
442443 }
0 commit comments