let today = new Beginning();

All Posts in 2021.5


在过去的二十年间,我们目睹了中美关系的长足发展带来了在技术领域非常多元的交流。其中典型的代表,就是微软和苹果在中国的市场发展。李永乐老师的视频中曾经指出:两个国家在贸易的过程中,一定是对国家双方都有利益的。 在这样的思想的指导下,我们始终认为构建的应用,也应该是越来越“全球化”的。所谓全球化,指的也正是在应用能够全球布局,全球服务。而面向这种全球布局的应用,我们完全可以在已有的基础设施、服务和运维经验的基础上,来大幅度的降低我们的维护成本。因为我们始终只需要一份专业的运维团队来维持全球的数据和服务。 我们曾经在思考一个问题的时候,也随着技术的背景发展,我们思考“分布式”的方式也逐渐改变。其中,最典型的代表就是在思考CAP定理时,我们更多的考虑的是实现分区容忍性和可用性,而弱化最终一致性。这类使用场景,在例如Email、微信等通信App的构建上时非常典型。也就是说,我们可以考虑中美两个大型数 …

Multi-tenant China Software Development AirGap

Build a package that can be used in browser and node with TypeScript

Sometimes I may need to share some of my logic\algorithm with other developers. In this case I might need to build a library. That library might be used in the customer's browser, or might be referenced by other front-end projects, may be based on Angular or React. So how can we build a package with TypeScript that benefits from strong type while can be installed\reference\used by others? After  …

Web npm TypeScript node webpack JavaScript Front-end

Use Azure Key Vault to store connection strings for App Service.

Sometimes, we need to provide key-values as environment variables for Azure app service, like database connection strings. In some cases, we might need someone to collaborate managing the app service. However, with app service environment variables access, he will also be able to connect to the database manually and do custom database operations, like drop database. That is not what we expected.  …

Azure App Service Azure Security Key vault

Programmatically connect to the remote server via SSH and execute remote command.

Recently I was trying to build a server management tool. That I need to connect to my server (Ubuntu) programmatically. I usually access my server via SSH, as a normal human. So I wanna do it with the same approach. First, create a new .NET Core project with: dotnet new console After creating the new project, install the latest SSH.NET library. Reference: NuGet Gallery | SSH.NET 2020.0.1 And  …

C# .NET Core bash Linux SSH