Added both log and metrics into index.js