Last active
January 12, 2019 00:10
-
-
Save zaccharles/5b3c6933e0b9c5a7878cf4c7eef646d9 to your computer and use it in GitHub Desktop.
blog-warm-lambdas
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 Handler | |
{ | |
private Guid _id; | |
public Handler() | |
{ | |
_id = Guid.NewGuid(); | |
new Thread(Background).Start(); | |
} | |
public void EntryPoint() | |
{ | |
Thread.Sleep(2000); | |
} | |
private void Background() | |
{ | |
var count = 0; | |
while(true) | |
{ | |
Thread.Sleep(1000); | |
Console.WriteLine($"{_id} / {count}"); | |
count++; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment