وبینار انگولار پلتفرمی برای اپلیکیشن‌هایی با مقیاس بزرگ
301, MovedPermanently
https://www.systemgroup.net/webinars/angular-webinar/ icon

در سال‌های اخیر اپلیکیشن‌های SinglePage جریان اصلی توسعه Front-end هستند که هر روز پیچیده‌تر می‌شوند. این پیچیدگی‌ها  فرصتی را برای پلتفرم‌های مختلف فراهم کرده تا راه‌‌حل‌های متفاوتی را برای مدیریت توسعه Front-end  ارائه کنند. Angular یکی از این پلتفرم‌ها است. در این وبینار به این موضوع می‌پردازیم که Angular چگونه می‌تواند به عنوان پلتفرمی برای توسعه اپلیکیشن‌های با مقیاس بزرگ استفاده شود.

محورهای اصلی این وبینار عبارتند از: 

  • تعریف اپلیکیشن با مقیاس بزرگ
  • مفهوم مقیاس پذیری در Front-end
  • چگونه Angular یک پلتفرم مناسب برای اپلیکیشن‌های با مقیاس بزرگ است؟
    • TypeScript
    • Opinionated Platform
    • Component Based Architecture
    • Modular Design
    • Design Patterns
    • Angular Elements
    • Micro Frontends Readiness 
  • چند راهکار برای اینکه محصولی مقیاس‌پذیر داشته باشیم (مناسب برای اپلیکیشن‌های با مقیاس بزرگ)
    • Separation of Service Abstraction & Implementation
    • Template Inheritance or Containers
    • Routing Strategy
    • Element Strategy
    • Micro Front-ends  

📌 تاریخ برگزاری: شنبه 24 خرداد، ساعت 19 تا 20:30

وبینار انگولار پلتفرمی برای اپلیکیشن‌هایی با مقیاس بزرگ
توسعه پروژه‌های SPA به صورت یکپارچه با ASP.NET Core 3.x
200, OK
https://www.dotnetcurry.com/aspnet-core/1525/angular-react-vuejs-svelte-spa-aspnet-core-3 icon

This tutorial demonstrates how to integrate four different SPA frameworks within ASP.NET Core v3 for Angular, React, Vue and Svelte. This ASP.NET Core tutorial also demontrates how to create your own custom SPA template. 



توسعه پروژه‌های SPA به صورت یکپارچه با ASP.NET Core 3.x
مدیریت مباحث همزمانی مرتبط با یک Rich Domain Model با استفاده از EFCore و الگوی Aggregate
301, MovedPermanently
https://www.kamilgrzybek.com/design/handling-concurrency-aggregate-pattern-and-ef-core/ icon

In summary, the most important issues here are:

  • The Aggregate’s main task is to protect invariants (business rules, the boundary of immediate consistency)
  • In a multi-threaded environment, when multiple threads are running simultaneously on the same Aggregate, a business rule may be broken
  • A way to solve concurrency conflicts is to use Pessimistic or Optimistic concurrency techniques
  • Pessimistic Concurrency involves the use of a database transaction and a locking mechanism. In this way, requests are processed one after the other, so basically concurrency is lost and it can lead to deadlocks.
  • Optimistic Concurrency technique is based on versioning database records and checking whether the previously loaded version has not been changed by another thread.
  • Entity Framework Core supports Optimistic Concurrency. Pessimistic Concurrency is not supported
  • The Aggregate must always be treated and versioned as a single unit
  • Domain events are an indicator, that state was changed so Aggregate version should be changed as well 
public class AggregateRootBase : Entity, IAggregateRoot
{
    private int _versionId;

    public void IncreaseVersion()
    {
        _versionId++;
    }
}
internal sealed class OrderEntityTypeConfiguration : IEntityTypeConfiguration<Order>
{
    public void Configure(EntityTypeBuilder<Order> builder)
    {
        builder.Property("_versionId").HasColumnName("VersionId").IsConcurrencyToken();
 
        //...
    }
}
var order = await _ordersContext.Orders.FindAsync(orderId);
order.AddOrderLine(request.ProductCode); 
var domainEvents = DomainEventsHelper.GetAllDomainEvents(order);
if (domainEvents.Any())
{
    order.IncreaseVersion();
}
await _ordersContext.SaveChangesAsync();


مدیریت مباحث همزمانی مرتبط با یک Rich Domain Model با استفاده از EFCore و الگوی Aggregate
بررسی روش‌های مختلف انجام اعمال غیرهمزمان در جاوااسکریپت
302, Found
https://academind.com/learn/javascript/callbacks-vs-promises-vs-rxjs-vs-async-awaits/ icon

# Which Approach Should You Use?

We had a look at four different approaches:-Callbacks with the danger of entering callback hell -Promises to escape callback hell-Observables to handle streams of data and apply operator magic -async/ await to write “synchronous” code with promises

 

بررسی روش‌های مختلف انجام اعمال غیرهمزمان در جاوااسکریپت
بررسی چالش‌های استفاده از UTC و TimeZones در برنامه‌های تحت وب مبتنی‌بر ‪.NET
200, OK
https://weblog.west-wind.com/posts/2015/feb/10/back-to-basics-utc-and-timezones-in-net-web-apps icon

Using UTC in Applications

Using UTC dates for data is a pretty common and necessary practice but it definitely adds some complexity when managing dates as you always have to remember to properly adjust dates. For display purposes this is pretty straight forward, but for query operations there’s a bit of mental overhead to ensure your date math adds up properly.

No easy solutions, but I hope this post and some of the helpers make life a little easier for you – I know they do for me. 

بررسی چالش‌های استفاده از UTC و TimeZones در برنامه‌های تحت وب مبتنی‌بر ‪.NET
پیاده‌سازی فرآیند Impersonation در ASP.NET Core
200, OK
https://tech.trailmax.info/2017/07/user-impersonation-in-asp-net-core/ icon

Impersonation Process

Impersonation is when an admin user is logged in with the same privileges as a user, but without knowing their password or other credentials. I’ve used this in couple applications and it was invaluable for support cases and debugging user permissions. 

[Authorize(Roles = "Admin")] // <-- Make sure only admins can access this 
public async Task<IActionResult> ImpersonateUser(String userId)
{
    var currentUserId = User.GetUserId();

    var impersonatedUser = await _userManager.FindByIdAsync(userId);

    var userPrincipal = await _signInManager.CreateUserPrincipalAsync(impersonatedUser);

    userPrincipal.Identities.First().AddClaim(new Claim("OriginalUserId", currentUserId));
    userPrincipal.Identities.First().AddClaim(new Claim("IsImpersonating", "true"));

    // sign out the current user
    await _signInManager.SignOutAsync();

    await HttpContext.Authentication.SignInAsync(cookieOptions.ApplicationCookieAuthenticationScheme, userPrincipal);

    return RedirectToAction("Index", "Home");
}


پیاده‌سازی فرآیند Impersonation در ASP.NET Core