File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ async fn insert() {
3939
4040 create_table ( & client) . await ;
4141
42- let bytes = Bytes :: copy_from_slice ( TAXI_DATA_TSV ) ;
42+ let bytes = Bytes :: from_static ( TAXI_DATA_TSV ) ;
4343
4444 let mut insert =
4545 client. insert_formatted_with ( "INSERT INTO nyc_taxi_trips_small FORMAT TabSeparated" ) ;
@@ -59,7 +59,7 @@ async fn insert_small_chunks() {
5959
6060 create_table ( & client) . await ;
6161
62- let mut bytes = Bytes :: copy_from_slice ( TAXI_DATA_TSV ) ;
62+ let mut bytes = Bytes :: from_static ( TAXI_DATA_TSV ) ;
6363
6464 let mut insert =
6565 client. insert_formatted_with ( "INSERT INTO nyc_taxi_trips_small FORMAT TabSeparated" ) ;
@@ -106,7 +106,7 @@ async fn insert_send_timeout() {
106106
107107 let client = Client :: default ( ) . with_url ( format ! ( "http://{local_addr}" ) ) ;
108108
109- let bytes = Bytes :: copy_from_slice ( TAXI_DATA_TSV ) ;
109+ let bytes = Bytes :: from_static ( TAXI_DATA_TSV ) ;
110110
111111 let send_timeout = Duration :: from_millis ( 100 ) ;
112112
@@ -148,7 +148,7 @@ async fn insert_end_timeout() {
148148
149149 let client = Client :: default ( ) . with_url ( format ! ( "http://{local_addr}" ) ) ;
150150
151- let bytes = Bytes :: copy_from_slice ( TAXI_DATA_TSV ) ;
151+ let bytes = Bytes :: from_static ( TAXI_DATA_TSV ) ;
152152
153153 let end_timeout = Duration :: from_millis ( 100 ) ;
154154
You can’t perform that action at this time.
0 commit comments