mirror of
https://github.com/compiler-explorer/compiler-explorer.git
synced 2025-12-27 11:44:09 -05:00
Optionally log the compiler cache keys and accesses (#3583)
This commit is contained in:
@@ -20,6 +20,7 @@ pageloadUrl=https://lambda.compiler-explorer.com/pageload
|
||||
storageSolution=s3
|
||||
healthCheckFilePath=/efs/.health
|
||||
showSponsors=true
|
||||
logCompilerCacheAccesses=true
|
||||
|
||||
eventLoopMeasureIntervalMs=50
|
||||
eventLoopLagThresholdWarn=100
|
||||
|
||||
@@ -246,6 +246,9 @@ export class BaseCompiler {
|
||||
|
||||
const key = this.getCompilerCacheKey(compiler, args, options);
|
||||
let result = await this.env.compilerCacheGet(key);
|
||||
if (this.env.ceProps('logCompilerCacheAccesses', false)) {
|
||||
logger.info(`Cache ${JSON.stringify(key)} ${result ? 'hit' : 'miss'}`);
|
||||
}
|
||||
if (!result) {
|
||||
result = await this.env.enqueue(async () => exec.execute(compiler, args, options));
|
||||
if (result.okToCache) {
|
||||
|
||||
Reference in New Issue
Block a user