BenchmarkDotNet=v0.10.11, OS=macOS 10.13.2 (17C88) [Darwin 17.3.0]
Processor=Intel Core i5-7360U CPU 2.30GHz (Kaby Lake), ProcessorCount=4
.NET Core SDK=2.0.3
[Host] : .NET Core 2.0.3 (Framework 4.6.0.0), 64bit RyuJIT
DefaultJob : .NET Core 2.0.3 (Framework 4.6.0.0), 64bit RyuJIT
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
listen 80; | |
location / { | |
proxy_pass http://localhost:5000; | |
proxy_http_version 1.1; | |
proxy_set_header Upgrade $http_upgrade; | |
proxy_set_header Connection keep-alive; | |
proxy_set_header Host $host; | |
proxy_cache_bypass $http_upgrade; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// params call | |
00007fff`0ca4d060 paramsBenchmark.ParameterBenchmark.ParamsWithObject() | |
00007fff`0ca4d076 83fe01 cmp esi,1 | |
00007fff`0ca4d079 751f jne 00007fff`0ca4d09a | |
00007fff`0ca4d07b 48b9a229a168ff7f0000 mov rcx,offset System_Private_CoreLib+0xe29a2 (00007fff`68a129a2) | |
00007fff`0ca4d085 ba02000000 mov edx,2 | |
00007fff`0ca4d08a e8b173ad5f call coreclr!MetaDataGetDispenser+0x72960 (00007fff`6c524440) | |
not managed method | |
00007fff`0ca4d08f ff05ef950400 inc dword ptr [00007fff`0ca96684] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ActionHistory_V1 : IActionHistory | |
{ | |
private Stack<string> _history { get; set; } | |
public ActionHistory_V1() | |
{ | |
if (File.Exists("actions.txt")) | |
{ | |
var lines = File.ReadAllLines("actions.txt"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ActionHistory_V2 : IActionHistory | |
{ | |
private static readonly ActionHistory_V2 instance = new ActionHistory_V2(); | |
public static ActionHistory_V2 Instance { get; } = instance; | |
private ActionHistory_V2() | |
{ | |
.... | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ActionHistory_V3 : IActionHistory | |
{ | |
private static Lazy<ActionHistory_V3> instance = | |
new Lazy<ActionHistory_V3>(() => new ActionHistory_V3()); | |
public static ActionHistory_V3 Instance { get; } = instance.Value; | |
private ActionHistory_V3() | |
{ | |
.... | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ClientPool | |
{ | |
private static Lazy<ClientPool> instance | |
= new Lazy<ClientPool>(() => new ClientPool()); | |
public static ClientPool Instance { get; } = instance.Value; | |
public int Size { get { return _currentSize; } } | |
public int TotalObject { get { return _counter; } } | |
private const int defaultSize = 5; | |
private ConcurrentBag<Client> _bag = new ConcurrentBag<Client>(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public abstract class Client | |
{ | |
public abstract void Connect(); | |
} | |
internal class RequestClient : Client | |
{ | |
public override void Connect() | |
{ | |
Console.WriteLine("Connecting to something with RequestClient..."); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static void BasicExample() | |
{ | |
Console.WriteLine("Havuzun boyutu {0}", ClientPool.Instance.Size); | |
Console.WriteLine("Client sınıfı ediniyoruz."); | |
var client1 = ClientPool.Instance.AcquireObject(); | |
client1.Connect(); | |
Console.WriteLine("Client'ı geri bırakıyoruz"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<div> | |
<blade v-for="(item, index) in items" :items="item" :key="index"></blade> | |
</div> | |
</template> | |
<script> | |
import blade from './blade' | |
export default { |
OlderNewer