lock(this) is actually a pit

In this case, only one machine is considered, and multiple servers can use distributed locks. For thread safety reasons, you may see the emergence of lock in many scenarios, especially in the processing of fund class. But does lock(this) really meet your needs? Here is an example We don't have much theoretical knowledge. Back to the business s ...

Posted on Fri, 07 Feb 2020 07:59:30 -0800 by jchemie

The way of Asp.Net Mvc to upload files asynchronously

Today, I tried the Ajax provided by mvc, and found that the backend action could not receive the file when uploading the file, neither Request.Files nor HttpPostedFileBase could receive the file..... Later, I found that the Ajax provided by mvc does not support file upload, but I can only use other methods The first way: through jQuery's ajaxSu ...

Posted on Wed, 08 Jan 2020 09:23:32 -0800 by loftystew

ASP.NET MVC controller

We said in the first part. There are two steps to write a controller class: implement a class, and then add some public methods to the class, which can be found as a controller when the class is running, and these methods are found as operations. Here we have two details: 1: How does the system know to instantiate that controller 2: How to d ...

Posted on Wed, 08 Jan 2020 05:43:07 -0800 by tkmk

Web service development and reference

1, Web service development 1. Right click the solution to add a new project and create a new empty web application 2. Right click new item to add new item to select web service 3. This is the method in webservice. You can add the method you need (you need to add the feature of [WebMethod] before the method can be called) 4. Publish iis to ac ...

Posted on Tue, 07 Jan 2020 02:52:14 -0800 by fredyap1234

[UWP] Use BorderEffect of Win2D to tile pictures

1. WPF has but UWP does not have picture tiling In WPF, images can be tiled simply by setting the TileMode property of ImageSource to Tile. These documents in WPF can be seen in detail: ImageBrush class (System.Windows.Media) Microsoft Docs TileBrush class (System.Windows.Media) Microsoft Docs TileBrush.TileMode l Properties (System.Windows.Me ...

Posted on Mon, 06 Jan 2020 03:53:56 -0800 by shadypalm88

[UWP] realization of openwork text with Win2D

1. Preface Before I made a tomato clock with PointLight, the effect was pretty good. See this article for details: [UWP] use PointLight and animate Later, I tried Win2D. This time, I used Win2D to achieve the hollowing effect of the text, and made an introverted and unobtrusive tomato clock with PointLight. The core idea of realizing hollow t ...

Posted on Fri, 03 Jan 2020 21:43:26 -0800 by xdentan

asp.net website monitoring scheme

There are many ways to monitor the web site. This paper discusses how to monitor the asp.net web site of windows Server Scheme adopted, Powershell + Influxdb + Grafana 1,PowerShell + Influxdb PowerShell is used to collect IIS indicators, once every 10 seconds, and then write to influxdb. The main code is as follows: note that PowerShell need ...

Posted on Sun, 29 Dec 2019 11:59:44 -0800 by jnmunsey

[UWP] Make long shadows using GetAlphaMask and ContainerVisual

1. What is Long Shadow Flat Design was popular a few years ago, and then Long Shadow became popular on the basis of it.A long shadow actually expands the projection of an object. It feels like a shadow illuminated by light. Usually, a projection with an angle of 45 degrees adds a sense of stereology to the object.Long shadows are rapidly becom ...

Posted on Sat, 28 Dec 2019 15:24:52 -0800 by JimStrosky

[UWP] Use GetAlphaMask to make shadows

1. Preface GetAlphaMask has been around a lot lately, so I want to write this article to show you how GetAlphaMask works.In fact, the use of GetAlphaMask is very limited, and what you can find on Github is designed to work with DropShadow, so this article also focuses on introducing DropShadow. 2. Composite Shadow Let's start with Composite Sh ...

Posted on Thu, 26 Dec 2019 16:12:54 -0800 by jerbecca

Modification method of missing files in Ueditor1.4.3.3 asp UTF-8

A few days ago, we need to use rich text editor in a project. Finally, we choose to use Ueditor editor to download the source code from the official website (http://ueditor.baidu.com/website/download.html). Create a demo according to the document, as follows: 1 <!DOCTYPE HTML> 2 <html lang="en-US"> 3 4 <head> 5 ...

Posted on Tue, 24 Dec 2019 06:47:15 -0800 by ckjian