ASP.NET Multi-Tenant SaaS App in 20 Minutes (EF Core) - Free Tutorial + GitHub Code Project

แชร์
ฝัง
  • เผยแพร่เมื่อ 15 ก.ย. 2024

ความคิดเห็น • 35

  • @PreethamM-di9qk
    @PreethamM-di9qk 5 หลายเดือนก่อน +1

    Thank you soo much for the awesome video about Multi-Tenant.
    Clear and crisp explanation.
    Loved it!

    • @aspnano
      @aspnano  4 หลายเดือนก่อน

      Thanks everyone for learning from these videos! Your comments and feedback are very appreciated

  • @Tamer_Ali
    @Tamer_Ali 11 หลายเดือนก่อน +2

    Thanks a lot for the awesome video 👍
    waiting to learn more about SaaS and Multi-Tenant.

  • @nsa-iwillneverhityou
    @nsa-iwillneverhityou 9 หลายเดือนก่อน

    멀티 테넌트에 대한 좋은 접근 방식에 대한 강좌. 좋은 설명입니다.

  • @TheMezanine
    @TheMezanine 4 วันที่ผ่านมา

    Thank you so much!!!

  • @learndotnetcore
    @learndotnetcore 6 หลายเดือนก่อน

    Deep dive tutorial 🎉 thanks efforts dude

  • @muhammadfaryadazim6110
    @muhammadfaryadazim6110 4 หลายเดือนก่อน +1

    I will just say .... wow 🤟🤟

  • @kumaravelg2348
    @kumaravelg2348 5 หลายเดือนก่อน

    Excellent Tutorial😊

  • @bolajibello8917
    @bolajibello8917 8 หลายเดือนก่อน

    Awesome content.. Thanks man!💯

  • @brankogojkovic8600
    @brankogojkovic8600 9 หลายเดือนก่อน

    Awesome, thanks a lot. It would be nice if there was a video for another example as well (Build a Multi-Tenant App With Multiple Databases)

    • @aspnano
      @aspnano  9 หลายเดือนก่อน +1

      There is a part 2 where multiple databases are covered, I just added the link in the description.

    • @brankogojkovic8600
      @brankogojkovic8600 9 หลายเดือนก่อน

      Thanks a lot. Best regards@@aspnano

  • @AhmedGamal-it8ru
    @AhmedGamal-it8ru หลายเดือนก่อน

    Thanks very much

  • @jamyrcarrasco8043
    @jamyrcarrasco8043 10 หลายเดือนก่อน

    NIcee!!! Thanks for the video.

  • @jheyssonapazamonasterio2110
    @jheyssonapazamonasterio2110 หลายเดือนก่อน +1

    8:24 dotnet ef migrations add Initial

  • @CarCan316
    @CarCan316 3 หลายเดือนก่อน

    Great stuff - if we can see how to do this using Identity for the authentication, sign up, etc., if would make this thing AWSOME!

    • @aspnano
      @aspnano  3 หลายเดือนก่อน

      Thats done in the Nano boilerplate, check it out!

  • @gga-wh5du
    @gga-wh5du 10 หลายเดือนก่อน

    Thanks for the video 😊

  • @billias28
    @billias28 11 หลายเดือนก่อน

    Very nice video !

  • @larsp5109
    @larsp5109 7 หลายเดือนก่อน

    6:21 SQLServer is way slower working with a string as a primary key instead of an int.

  • @user-nw8oi9vn9y
    @user-nw8oi9vn9y 5 หลายเดือนก่อน

    Does this integrate with Azure AD (Entra ID) tenants?

  • @umairmalpara9208
    @umairmalpara9208 8 หลายเดือนก่อน

    This is good. But it can be hectic if we have lots of tenants. Can we extend this example to store tenant data in different schemas of the same database? And How?

    • @logantcooper6
      @logantcooper6 7 หลายเดือนก่อน

      You would have to create a copy of every table required for your application for every new schema and be able to generate the schema/tables dynamically. That would be even more hectic.

  • @caseyspaulding
    @caseyspaulding 3 หลายเดือนก่อน

    💯Thank you

  • @FelipeAlmeida-bc9kf
    @FelipeAlmeida-bc9kf 10 หลายเดือนก่อน

    first off all thks a lot for these tutorial...
    i have just one question:
    when i tried to POST a new product, an Microsoft.Data.SqlClient.SqlException was thrown saying that it can't insert a NULL value to TenantId Column, on Product table....
    Should we add this information ( by claims for example) on Create endpoint/service?
    i watched your tutorial twice and could not find any diferences on our code...
    thanks alot!!!!

    • @aspnano
      @aspnano  10 หลายเดือนก่อน +1

      Hi, hopefully this helps... you need to have a header called tenant and provide a value, otherwise you should get an Invalid Tenant error. Set a breakpoint in the constructor of your applicationdbcontext and see if a TenantId id being set in the currentTenantService - if not your problem is in the middleware or that service. Last place the issue could be is in your SaveChanges override in dbcontext. In the video (I didnt explain this detail) save changes loops over any entity that implements IMustHaveTenant interface. Make sure your product entity is implementing that interface otherwise it wont get included in the save changes process.

    • @FelipeAlmeida-bc9kf
      @FelipeAlmeida-bc9kf 10 หลายเดือนก่อน

      @@aspnano i found where i made a mistake hehehehe... i left a little "break" at saveChanges switch...
      tks again and waiting for more 😃

    • @johnbhatt
      @johnbhatt หลายเดือนก่อน +1

      If anyone still getting this error on .NET Core 8, I found the solution. When we implemented interface IMustHaveTenant on Entity, it automatically added Column in database. When we added TenantId separately, it was confused because it found two column named TenantId.
      I simply removed TenantId property from entity class and it saved as expected.

  • @SOYLUISO
    @SOYLUISO 10 หลายเดือนก่อน

    good video, but that part of creating a second db context only for resolving the tenant of the request is pretty ugly to be honest.

  • @joga_bonito_aro
    @joga_bonito_aro 9 หลายเดือนก่อน +1

    ngl... that second DBContext feels like a hack.

  • @ghevisartor6005
    @ghevisartor6005 9 หลายเดือนก่อน

    nice video! how do you prevent another tenant to use the key of someone else? are they supposed to be very difficult to find or is this a non issue?

    • @aspnano
      @aspnano  9 หลายเดือนก่อน +2

      The only time you would resolve the tenant from a header or subdomain, is in an unauthenticated request like login. Once the user is authenticated and issued a token, the tenant key would always be read from that token (or cookie) which are imposible to modify. So in the tenant resolver middleware, you would first check to see if there is a token present and if so, obtain the tenant value from a claim in that token.

    • @ghevisartor6005
      @ghevisartor6005 9 หลายเดือนก่อน

      @@aspnano you are right, i'm so dumb

  • @LordErnie
    @LordErnie 11 หลายเดือนก่อน +2

    Here is me, asking myself what the fk is a Tenant. Good vid non the less tho.