File tree Expand file tree Collapse file tree 2 files changed +8
-6
lines changed Expand file tree Collapse file tree 2 files changed +8
-6
lines changed Original file line number Diff line number Diff line change 11<Project Sdk =" Microsoft.NET.Sdk" >
22 <PropertyGroup >
33 <OutputType >Exe</OutputType >
4- <TargetFrameworks >net48;netcoreapp3.1 </TargetFrameworks >
5- <LangVersion >8 .0</LangVersion >
4+ <TargetFrameworks >net48;net5.0 </TargetFrameworks >
5+ <LangVersion >9 .0</LangVersion >
66 </PropertyGroup >
77 <ItemGroup >
88 <PackageReference Include =" BenchmarkDotNet" Version =" 0.12.1" />
9- <PackageReference Include =" MySqlConnector" Version =" 1.0 .0-beta.5 " />
10- <PackageReference Include =" MySql.Data" Version =" 8.0.20 " />
9+ <PackageReference Include =" MySqlConnector" Version =" 1.3 .0-beta.4 " />
10+ <PackageReference Include =" MySql.Data" Version =" 8.0.21 " />
1111 </ItemGroup >
1212</Project >
Original file line number Diff line number Diff line change @@ -24,7 +24,7 @@ static void Main()
2424 . AddDiagnoser ( MemoryDiagnoser . Default )
2525 . AddColumn ( StatisticColumn . AllStatistics )
2626 . AddJob ( Job . Default . WithRuntime ( ClrRuntime . Net48 ) )
27- . AddJob ( Job . Default . WithRuntime ( CoreRuntime . Core31 ) )
27+ . AddJob ( Job . Default . WithRuntime ( CoreRuntime . Core50 ) )
2828 . AddExporter ( DefaultExporters . Csv ) ;
2929
3030 var summary = BenchmarkRunner . Run < MySqlClient > ( customConfig ) ;
@@ -76,6 +76,8 @@ create table benchmark.blobs(
7676 var mySqlConnector = new MySqlConnector . MySqlConnection ( s_connectionString ) ;
7777 mySqlConnector . Open ( ) ;
7878 m_connections . Add ( "MySqlConnector" , mySqlConnector ) ;
79+
80+ Connection = m_connections [ Library ] ;
7981 }
8082
8183 [ GlobalCleanup ]
@@ -181,7 +183,7 @@ private int ReadAllRowsSync(string sql)
181183 return total ;
182184 }
183185
184- private DbConnection Connection => m_connections [ Library ] ;
186+ private DbConnection Connection { get ; set ; }
185187
186188 // TODO: move to config file
187189 static string s_connectionString = "server=127.0.0.1;user id=root;password=pass;port=3306;ssl mode=none;Use Affected Rows=true;Connection Reset=false;Default Command Timeout=0;AutoEnlist=false;" ;
You can’t perform that action at this time.
0 commit comments