build/utils/gcp-logging.js
// increase the log severity for alerting purposes
increase the log severity for alerting purposes
increase the log severity for alerting purposes
async endTimeAndLog(requestId) {
        this.endTime();
        this.requestId = requestId;
        const entry = gcpLogging.entry({
            resource: { type: 'global' },
            severity: 'INFO',
            labels: {
                latency: this.elapsedTimeInMs?.toString(),
            },
        }, {
            requestId: this.requestId,
            elapsedTimeInMs: this.elapsedTimeInMs,
            containerName: this.containerName,
        });
        gcpLogging.write(entry);
        console.log('Process Time', this.elapsedTimeInMs, 'ms Job', this.jobId);
        return;
    }
async endTimeAndLog ( requestId ) { this . endTime ( ) ; this . requestId = requestId ; const entry = gcpLogging . entry ( { resource : { type : 'global' } , severity : 'INFO' , labels : { latency : this . elapsedTimeInMs ?. toString ( ) , } , } , { requestId : this . requestId , elapsedTimeInMs : this . elapsedTimeInMs , containerName : this . containerName , } ) ; gcpLogging . write ( entry ) ; console . log ( 'Process Time' , this . elapsedTimeInMs , 'ms Job' , this . jobId ) ; return ; }
increase the log severity for alerting purposes
increase the log severity for alerting purposes