@@ -56,9 +56,14 @@ public class ConnImplBenchmark {
5656 public void setUp () throws IOException {
5757 java .util .logging .Logger .getGlobal ().setLevel (Level .ALL );
5858
59- connectionSettingsReadAPIEnabled = ConnectionSettings .newBuilder ().setUseReadAPI (true ).build ();
60- connectionSettingsReadAPIDisabled =
61- ConnectionSettings .newBuilder ().setUseReadAPI (false ).build ();
59+ connectionSettingsReadAPIEnabled = ConnectionSettings .newBuilder ()
60+ .setUseReadAPI (true )
61+ .setMaxResults (500L )
62+ .setJobTimeoutMs (Long .MAX_VALUE )
63+ .build ();
64+ connectionSettingsReadAPIDisabled = ConnectionSettings .newBuilder ()
65+ .setUseReadAPI (false )
66+ .build ();
6267 }
6368
6469 @ Benchmark
@@ -153,8 +158,8 @@ private long getResultHash(BigQueryResult bigQueryResultSet) throws SQLException
153158 System .out .println ("\n Running" );
154159 while (rs .next ()) {
155160 hash += computeHash (rs , "vendor_id" , ResultSet ::getString );
156- hash += computeHash (rs , "pickup_datetime" , ResultSet ::getString );
157- hash += computeHash (rs , "dropoff_datetime" , ResultSet ::getString );
161+ hash += computeHash (rs , "pickup_datetime" , ResultSet ::getLong );
162+ hash += computeHash (rs , "dropoff_datetime" , ResultSet ::getLong );
158163 hash += computeHash (rs , "passenger_count" , ResultSet ::getLong );
159164 hash += computeHash (rs , "trip_distance" , ResultSet ::getDouble );
160165 hash += computeHash (rs , "rate_code" , ResultSet ::getString );
0 commit comments