Create a RESTful API with .NET Core and MongoDB

Поділитися
Вставка
  • Опубліковано 16 гру 2024

КОМЕНТАРІ • 29

  • @MongoDB
    @MongoDB  Рік тому +1

    ✅ Sign-up for a free cluster at: mdb.link/free-jJK9alBkzU0
    ✅ Get help on our Community Forums: mdb.link/community-jJK9alBkzU0

  • @narutodihargo
    @narutodihargo Рік тому +2

    00:35= Prequisite Softwares, 01:17= Command to create new Web Api, 02:55= Create Module, Model-> MongoDBSettings.cs file, 04:30= appsettings.json , 06:25=ConnectionURL , 07:13= Services Module, 08:15= Read Only, 09:14= PlayList.cs , 17:20= Controller Module, 23:30= MongoDb Service, 24:46=Start From Here ,

  • @danielsosinskiy5758
    @danielsosinskiy5758 8 місяців тому +2

    I've been following the entire guide and was stuck with a problem of Swagger not recognizing my endpoints ("No operations defined in spec!"). Eventually, I figured it out. In case anyone else has the same problem, I've changed "[Controller]" to "[ApiController]" in PlaylistController.cs file. Other than that, thank you for your video!

    • @mongodb_nraboy
      @mongodb_nraboy 5 місяців тому +1

      Thanks for sharing your solution! I'm sorry I left in some confusion.

  • @pilgrimk
    @pilgrimk 6 місяців тому +1

    Incredibly helpful video! great job and thank you!
    one question though, what's the mechanism in this approach for accessing another collection within the database? in this example you've hard coded the CollectionName to be "playlist" in the appsettings.json file. what do you do to access the "movies" and "theaters" collection from your sample_mflix database?

    • @Columbiform79
      @Columbiform79 4 місяці тому

      If you search/google for 'MongoDB Provider for EF Core Tutorial' there is an official mongodb article that shows how this can be done using the mongodb entity framework and using the [Collection("collectionName")] annotation when creating the collection model class.

  • @charlesm.1638
    @charlesm.1638 Рік тому +1

    Great video, made changes to meet my own local MongoDB server.

  • @zutafe
    @zutafe 2 роки тому +4

    There's one problem at PUT method. When you try to update a document, it add a new item instead of updating the value of the current item.

    • @quizzerrr
      @quizzerrr 2 роки тому +2

      21:45 He mentions that he is deliberately doing it.

  • @sniperharshgaming3047
    @sniperharshgaming3047 9 місяців тому

    So MongoDB service is basically like a repository if we use a repository pattern as you are in contact with database when you are in MongoDbService.

  • @xnag78
    @xnag78 2 роки тому +2

    Is there any github for the tutorial?

  • @leighton_lam
    @leighton_lam 5 місяців тому

    Hey thank you for the video! I'm running into a CORS problem when trying to execute the GET request. What could I be doing wrong? (can't seem to find any answers on google)
    Edit: nevermind, it seemed to resolve itself, i think i cant make too many calls/requests to MongoDB in a short time maybe?

  • @yvanbrunel9734
    @yvanbrunel9734 2 роки тому +2

    This is, amazing ❤️

  • @kurtaaroncabrera3261
    @kurtaaroncabrera3261 Рік тому

    Hello I have this error Internal server error: Unable to authenticate using sasl protocol mechanism SCRAM-SHA-1. can you help me?

    • @mongodb_nraboy
      @mongodb_nraboy 5 місяців тому

      Have you validated that you are using the correct connection string, correct username and password, and have the proper user and network rules created within Atlas?

  • @gunuluutku583
    @gunuluutku583 4 місяці тому

    I have followed every step but every action gives me "404: Not Found" error. How can I fix it?

    • @MongoDB
      @MongoDB  4 місяці тому

      By every action do you mean every time you try to make a request against the API? Any server logs rather than just client facing?

  • @GamaSharmaShamulailatpam
    @GamaSharmaShamulailatpam 5 місяців тому +1

    Thank you .

  • @wilsonnarea5378
    @wilsonnarea5378 2 роки тому +1

    great video!

  • @satidseenun1724
    @satidseenun1724 Рік тому +1

    Thank you very much

  • @mauroinde
    @mauroinde Рік тому

    Usted es la verga mi llave, gracias. Encima como me gusta con vs code y con cmd.

  • @hackerbryan
    @hackerbryan Рік тому

    I Love you rsrsrsr

  • @botyironcastle
    @botyironcastle Рік тому

    cant even create a simple upsert , swagger always shits out: Unable to cast object of type 'MongoDB.Bson.BsonObjectId' to type 'MongoDB.Bson.BsonBoolean'.
    at AsBooleanGetter(Object)

    • @mongodb_nraboy
      @mongodb_nraboy 5 місяців тому

      Is there any particular line number involved in this? You might want to take this to the MongoDB forums and we can properly troubleshoot it 🙂