اشتراک‌ها
ویدیوهای NET Conf 2022.
NET Conf is our annual virtual developer event co-organized by the .NET community and Microsoft and sponsored by the .NET Foundation and ecosystem partners. It is a chance to learn and get inspired for your next software project. You will learn to build for web, mobile, cloud, desktop, games, services, libraries and more for a variety of platforms and devices all with .NET. We have sessions for everyone, no matter if you are just beginning or are a seasoned engineer. We’ll have presentations on .NET 7, C# 11, Azure, Visual Studio, and much more. 
ویدیوهای NET Conf 2022.
اشتراک‌ها
استقرار میکروسرویس در Azure Container

Azure Container Instances a simple way to run a container in Azure, without having to manage any virtual machines.

Brady Gaster returns in this follow up to the previous episode on Worker services. This time Brady will show us how to deploy our worker service to Azure Container Instances

  • [00:58] - Creating a new container instance
  • [03:08] - Exploring the Docker tools in Visual Studio Code
  • [04:30] - Reviewing the deployed container instance
  • [05:50] - Exploring the tools for Kubernetes in Visual Studio Code
  • [09:57] - Kubernetes Namespaces and Deployments
  • [12:10] - .NET Architecture Guides 
استقرار میکروسرویس در Azure Container
اشتراک‌ها
Visual Studio 2019 version 16.4.2 منتشر شد
Visual Studio 2019 version 16.4.2 منتشر شد
اشتراک‌ها
ویژگی های SQL Server 2019 را در این ویدئو تماشا کنید!

In this video, you will get to experience bringing SQL and Spark together as a unified data platform running on Kubernetes and learn how:

• Data virtualization integrates data from disparate sources, locations and formats, without replicating or moving the data, to create a single "virtual" data layer

• Data Lake - SQL 2019 provides SQL and Spark query capabilities over a scalable storage, across relational and big data

• Data Mart provides an ability to scale out storage for super-fast performance over big data or data from other external sources 

ویژگی های SQL Server 2019 را در این ویدئو تماشا کنید!
اشتراک‌ها
نگاهی به آینده WebAssembly

The future of WebAssembly - A look at upcoming features and proposals

WebAssembly is a performance optimised virtual machine that was shipped in all four major browsers earlier this year. It is a nascent technology and the current version is very much an MVP (minimum viable product). This blog post takes a look at the WebAssembly roadmap and the features it might be gain in the near future.

I’ll try to keep this blog post relatively high-level, so I’ll skip over some of the more technical proposals, instead focusing on what they might mean for languages that target WebAssembly. 

نگاهی به آینده WebAssembly
نظرات مطالب
پشتیبانی از حذف و به‌روز رسانی دسته‌ای رکوردها در EF 7.0

یک نکته‌ی تکمیلی: روش استفاده از خواص راهبری، در به‌روزسانی‌های دسته‌ای

در همین مثال مطلب جاری، فرض کنید موجودیت کاربر، به همراه خاصیت محاسباتی تعداد کتاب‌ها (NumberOfBooks) هم هست:

public class User
{
    // ...

    public virtual List<Book> Books { get; set; } = new();

    public int NumberOfBooks { get; set; }
}

اگر سعی کنیم این خاصیت را به صورت زیر به‌روز رسانی کنیم که در آن مقدار تعداد کتاب‌ها به کمک خاصیت راهبری Books محاسبه شود:

await context.Users.Where(x=> x.Id == 1).ExecuteUpdateAsync(s => s.SetProperty(user => user.NumberOfBooks,
                user => user.Books.Count()));

به خطای زیر می‌رسیم:

... could not be translated. Additional information: Translation of member 'Books' on entity type 'User' failed. This commonly occurs when the specified member is unmapped.

عنوان می‌کند که این خاصیت راهبری، نگاشت نشده‌است. برای رفع این مشکل باید به صورت زیر عمل کرد:

await context.Users
             .Where(user => user.Id == 1)
             .Select(user => new
             {
                user.NumberOfBooks,
                BooksCount = user.Books.Count()
             })
             .ExecuteUpdateAsync(s => s.SetProperty(arg => arg.NumberOfBooks, arg => arg.BooksCount));

در اینجا تنها کاری که انجام شده، انجام محاسبات و نگاشت‌های لازم، پیش از فراخوانی متد ExecuteUpdateAsync است.

نظرات مطالب
مروری بر Blazor (قسمت اول)
زمانی که از CSharp و به صورت کلی NET. استفاده می‌کنیم تا برای Android-iOS-Windows و جدیدا Web برنامه بنویسیم، این دغدغه ای که گفتید پیش میآد. علاوه بر راه هایی مثل Obfuscation که همیشه امکان استفاده شون هست، شما راه حل بهتری هم دارید و اون تبدیل کدتون به Native machine code هست که عملا مشکلی که گفتید رو نخواهد داشت و Performance خیلی خیلی خیلی بهتری هم می‌ده. توی Android و iOS این قابلیت در Xamarin دیده شده که اول Native Machine Code با قابلیتی به نام AOT یا Ahead of time به دست بیاد و یک دور هم با LLVM یا Low Level Virtual Machine بهینه سازی هم بشه. اون چیزی که شما به مشتری می‌دید دیگه DLL نیست و به هیچ روی چیز قابل فهمی هم داخل اش نیست. در برنامه‌های UWP می‌تونید از Dot Net Native استفاده کنید. در برنامه‌های WPF می‌تونید با پشتیبانی 3 NET Core. از اون، بیایید و خروجی کاملا Windows ای بگیرید که هم احتیاج به نصب بودن Dot Net یا Dot Net Core نداره و هم کدش خوانا نیست. توی Web Assembly هم همین هست، با پشتیبانی Mono از AOT که در مراحل اولیه قرار داره می‌تونید به سمت مرورگر فایل wasm بفرستید، نه dll، هم مشکلی که گفتید رو نداره و هم تا 70 برابر بسته به سناریو سرعت بیشتری داره.
نظرات مطالب
EF Code First #12
در حالت استفاده از الگوی Context Per Request همانطور که عنوان شد هدف به اشتراک گذاری یک Unit Of Work در طی یک درخواست است. 
به عنوان مثال کنترلرهای زیر رو در نظر بگیرید:
public partial class HomeController : Controller
{
        private readonly IUnitOfWork _uow;

        public HomeController(IUnitOfWork uow)
        {
            _uow = uow;
        }
        public virtual ActionResult Index()
        {
            return View();
        }
}
public class TestController : Controller
{
        private readonly IUnitOfWork _uow;

        public TestController(IUnitOfWork uow)
        {
            _uow = uow;
        }

        public ActionResult GetData()
        {
            return Content("Data");
        }
}
در ویوی اکشن متد Index مربوط به کنترلر Home این چنین کدی را جهت رندر کردن اکشن داخل ویو داریم:
@Html.Action("GetData", "Test")
در این حالت باید یک وهله‌ی یکسان از کانتکست در اختیار هر دو کنترلر قرار گیرد، من این مورد رو چک کردم ولی برای حالت فوق به جای یک بار چهار وهله ایجاد و در پایان dispose شدند، این مورد رو برای این مثال تست کردم.
آیا این مورد رو میشه با پیاده‌سازی الگوی Container Per Request و استفاده از Nested Containerها حل کرد؟ یا اینکه من موضوع رو اشتباه متوجه شدم!؟