This file contains hidden or 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
| using RabbitMQ.Client; | |
| using RabbitMQ.Client.Events; | |
| using System; | |
| using System.Text; | |
| class Receive | |
| { | |
| public static void Main() | |
| { | |
| var factory = new ConnectionFactory() { HostName = "localhost" }; |
This file contains hidden or 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
| using System; | |
| using System.IO; | |
| using System.Net; | |
| using System.Net.Sockets; | |
| namespace EchoServerSocket { | |
| internal class Program { | |
| private static void Main(string[] args) { | |
| while (true) { | |
| var quit = false; |
This file contains hidden or 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
| using System; | |
| using Akka.Actor; | |
| namespace SimpleReceiverAkkaDotNet | |
| { | |
| internal class Program | |
| { | |
| private static void Main() | |
| { | |
| var actorSystem = ActorSystem.Create("MessageSystemActor"); |
This file contains hidden or 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
| using Microsoft.AspNetCore.Builder; | |
| using Microsoft.AspNetCore.Hosting; | |
| using Microsoft.Extensions.Configuration; | |
| using Microsoft.Extensions.DependencyInjection; | |
| namespace CryptoCurrencyInfo { | |
| public sealed class Startup { | |
| public Startup(IConfiguration configuration) { |
This file contains hidden or 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
| using Microsoft.AspNetCore.Builder; | |
| using Microsoft.AspNetCore.Hosting; | |
| using Microsoft.AspNetCore.Http; | |
| using Microsoft.Extensions.DependencyInjection; | |
| namespace CryptoCurrencyInfo { | |
| public sealed class Startup { | |
| public void ConfigureServices(IServiceCollection services) { |
This file contains hidden or 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
| using System; | |
| using System.Collections.Generic; | |
| using System.Collections.ObjectModel; | |
| using System.Net; | |
| using System.Net.Http; | |
| using BinanceCryptoCurrency.Domain; | |
| using BinanceCryptoCurrency.Domain.Entity; | |
| using Newtonsoft.Json; | |
| namespace BinanceCryptoCurrency.Utility { |
This file contains hidden or 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
| docker run --name redis_test -p 6379:6379 -d redis |
This file contains hidden or 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
| IF OBJECT_ID('dbo.Nums') IS NOT NULL | |
| DROP TABLE dbo.Nums; | |
| GO | |
| CREATE TABLE dbo.Nums(n INT NOT NULL PRIMARY KEY); | |
| DECLARE @max AS INT, @rc AS INT; | |
| SET @max = 1000000000; | |
| SET @rc = 1; | |
| INSERT INTO Nums VALUES(1); | |
| WHILE @rc * 2 <= @max |
This file contains hidden or 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
| select | |
| a.FILEID, | |
| [FILE_SIZE_MB] = | |
| convert(decimal(12,2),round(a.size/128.000,2)), | |
| [SPACE_USED_MB] = | |
| convert(decimal(12,2),round(fileproperty(a.name,'SpaceUsed')/128.000,2)), | |
| [FREE_SPACE_MB] = | |
| convert(decimal(12,2),round((a.size-fileproperty(a.name,'SpaceUsed'))/128.000,2)) , | |
| NAME = left(a.NAME,15), | |
| FILENAME = left(a.FILENAME,30) |
This file contains hidden or 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
| IF OBJECT_ID('tempdb.dbo.#space') IS NOT NULL | |
| DROP TABLE #space | |
| CREATE TABLE #space ( | |
| database_id INT PRIMARY KEY | |
| , data_used_size DECIMAL(18,2) | |
| , log_used_size DECIMAL(18,2)) | |
| DECLARE @SQL NVARCHAR(MAX) |