public static void main ( String ... args ) { // Step 1. Enable OpenCensus Metrics. try { setupOpenCensusAndPrometheusExporter ( ) ; } catch ( IOException e ) { System . err . println ( "Failed to create and register OpenCensus Prometheus Stats exporter " + e ) ; return ; } BufferedReader stdin = new BufferedReader ( new InputStreamReader ( System . in ) ) ; while ( true ) { try { readEvaluateProcessLine ( stdin ) ; } catch ( IOException e ) { System . err . println ( "EOF bye " + e ) ; return ; } catch ( Exception e ) { recordTaggedStat ( KEY_METHOD , "repl" , M_ERRORS , new Long ( 1 ) ) ; return ; } } }
Main launcher for the Repl example .