Skip to content

Conversation

Parro
Copy link
Contributor

@Parro Parro commented Jul 20, 2022

Extract Init Duration from Cloudwatch logs for each power values. I pick the first value of the initDurations array because Init Duration is present only in the first invocation.

@alexcasalboni
Copy link
Owner

alexcasalboni commented Jul 20, 2022 via email

@@ -145,6 +145,11 @@ const computeStatistics = (baseCost, results, value, discardTopBottom) => {
const averageDuration = utils.computeAverageDuration(durations, discardTopBottom);
console.log('Average duration: ', averageDuration);

const initDurations = utils.parseLogAndExtractInitDurations(results);

const [initDuration] = initDurations;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The assumption is that there's always only one cold start, right? This will change a bit when #177 is merged.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, we could use the same computeAverageDuration to get the average init duration, passing discardTopBottom as zero.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants