2. Using Phoenix Framework to Create an Elixir REST API Project

แชร์
ฝัง
  • เผยแพร่เมื่อ 16 ม.ค. 2025

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

  • @juanhedderich
    @juanhedderich 5 หลายเดือนก่อน +3

    My brother, you ARE the real deal, thanks for this course, I am very excited to learn this technology!!

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

      Thank you, love to hear it!

  • @jondoe79
    @jondoe79 2 ปีที่แล้ว +5

    Keep'em coming, this channel is a gold mine

  • @CarrotBoy9
    @CarrotBoy9 2 ปีที่แล้ว +8

    cant wait for your phoenix 1.7 liveview CRUD tutorial.

  • @BreakerGandalfStyle
    @BreakerGandalfStyle ปีที่แล้ว +2

    Your videos are amazing and helping me a ton from settling over from Spring/Kotlin to Elixir!

    • @JacobLuetzow
      @JacobLuetzow  ปีที่แล้ว

      Love to hear that! Thank you 🙌🏼

  • @mark_mckellar
    @mark_mckellar ปีที่แล้ว +1

    Best Video on Elixir REST API out there!

  • @andriyabu
    @andriyabu 2 ปีที่แล้ว +2

    cool.. waiting for the next tutorial.

  • @josephwaldner1976
    @josephwaldner1976 ปีที่แล้ว +1

    your play by play as you code really stands out, been doing paid Elixir for about a year working on an existing code base so i don't get a chance to use 'new' unless i hobby code. Thank you

    • @JacobLuetzow
      @JacobLuetzow  ปีที่แล้ว

      I love to hear that! Thank you. That's all too common when you work on existing code. I’d be in the same boat if I wasn't creating TH-cam content.

  • @KhalidKhan-xq5xp
    @KhalidKhan-xq5xp 3 หลายเดือนก่อน +1

    Really helpful video. Thanks.

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

      Love to hear it, thanks!

  • @phanta5m
    @phanta5m 2 ปีที่แล้ว +1

    Cool tuts, easy but deep enough to know phoenix framework

    • @JacobLuetzow
      @JacobLuetzow  2 ปีที่แล้ว

      🥳 awesome, happy you liked it!

  • @AttyTomGrieve
    @AttyTomGrieve ปีที่แล้ว +1

    Noice!

  • @danimusbar
    @danimusbar 2 ปีที่แล้ว +2

    Awesome, I am not regret subscribe this channel tks Bro, keep up 👍👍👍

    • @JacobLuetzow
      @JacobLuetzow  2 ปีที่แล้ว +1

      Thanks, love hearing that!

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

    Thank you so much!

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

      Glad it helped!

  • @gthaka
    @gthaka ปีที่แล้ว +1

    Let's go ☄☄

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

    watching 2nd vid.
    excellent tutorial. thanks for docker too.
    useful for new-bees too.
    can u upload such easy tutorial for chat application similar to whatsapp with plain javascript so that i can implement on native android.
    thanks.
    (commenting after watching other videos and again starting back)

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

      Thank you! Yea docker is great to learn for both development and production.

  • @markhoo
    @markhoo ปีที่แล้ว +2

    Great tutorial! Thank you 👍👍👍

  • @Xrat88
    @Xrat88 2 ปีที่แล้ว +1

    This content is awesome!!

    • @JacobLuetzow
      @JacobLuetzow  2 ปีที่แล้ว

      Thank you, glad you are liking!

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

    What video did you create the psql docker instance? I can't find the first video in this series..

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

      Here is the playlist they are all added to: th-cam.com/play/PL2Rv8vpZJz4zM3Go3X-dda478p-6xrmEl.html

  • @prashlovessamosa
    @prashlovessamosa ปีที่แล้ว +1

    Thank you

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

    Hello I've noticed that there is no View file anymore when running the command. It is not needed anymore or I need to add something to generate it?
    Btw great videos, love this guide!

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

      Thanks for the support. I appreciate it!
      When I started this series, it was Phoenix 1.6, and then the update to 1.7 changed quite a bit. If you check out this forum post on my Discord server, it will explain how to manage the changes. discord.com/channels/1008037778132578334/1131618116305174590

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

      @@JacobLuetzow Thank you for your answer! I did a research yesterday and after couple hours I figured it out. Now I keep going with your videos, they are awesome!

  • @hxdcml83
    @hxdcml83 ปีที่แล้ว +2

    Hi. love the channel and the depth in which you go through elixir and all of the components related to it. Question though, did I miss one of the videos? I couldn't find any previous video where the "real deal api web" was built and configured. 😕

    • @JacobLuetzow
      @JacobLuetzow  ปีที่แล้ว

      Thank you, I love hearing that!
      I'm not sure I follow. We create the whole skeleton project, using phoenix to generate it, starting at about timestamp 3:23 - 7:37.

    • @hxdcml83
      @hxdcml83 ปีที่แล้ว +1

      @@JacobLuetzow I figured out the problem. It was an ID-10-T error. Problem between keyboard and chair. Just getting familiar with the folder structure and realized where everything was. My issue. Was able to make everything run as shown 🙂

    • @JacobLuetzow
      @JacobLuetzow  ปีที่แล้ว

      haha, it happens to the best of us! Glad you got everything sorted though!

  • @Nick__X
    @Nick__X ปีที่แล้ว

    Great video, did you have a list of VS code extensions you'd recommend?

    • @JacobLuetzow
      @JacobLuetzow  ปีที่แล้ว +1

      I do not, but i can put one together.

  • @Redyf
    @Redyf ปีที่แล้ว +1

    What colorscheme is that on vscode? Looks great! Also amazing video man, keep up the good work

    • @JacobLuetzow
      @JacobLuetzow  ปีที่แล้ว +2

      Thank you! The theme is Elixir Theme by Maiqui Tome: marketplace.visualstudio.com/items?itemName=maiquitome.elixir-theme

  • @kvatofermer
    @kvatofermer ปีที่แล้ว

    What's up, Jacob! Thank you for the great video as usual :)
    I run into a little issue already solved, but I want to mention it. I had an error after running "mix ecto.create". It said something like "there is no role 'backend_stuff' in postgres." Thus, you need to create 'backend_stuff' user in psql or use existing user instead of "backend_stuff" one to run "mix ecto.create" successfuly.
    I admit this issue could be an edge-case one. Anyway, my comment could be useful, if someone will be stuck. ;)

    • @JacobLuetzow
      @JacobLuetzow  ปีที่แล้ว +1

      Thanks for sharing! The video before this covers getting Postgres up and running in Docker, so if you follow each video, it’ll work unless you use different credentials.

    • @kvatofermer
      @kvatofermer ปีที่แล้ว +1

      @@JacobLuetzow yep, the issue was on my side. there was already running db on my machine on standard postgres port 5432 my bad

  • @sawood2010
    @sawood2010 ปีที่แล้ว +1

    I'm ignorant when it comes to functional languages... does elxixir have types? How do you know what anything is? I come from dotnet and typescript background. I've dabbled with laravel but php isn't really my thing. I want to make a real-time jobs-posting app, and this framework is looking very intriguing.

    • @JacobLuetzow
      @JacobLuetzow  ปีที่แล้ว +1

      Yes, Elixir has a type system. It is dynamically typed, so type-checking is done at runtime rather than compile-time. Variables can hold any value, and their type can change throughout the program. It also does provide mechanisms for type specification and checking. IE, the @spec module attribute, allows you to specify the expected function arguments and return value types. It also provides the is_integer, is_atom, and other functions to perform type-checking at runtime.
      I think Phoenix would be a great option for a real-time jobs-posting app.
      a nice resource:
      thinkingelixir.com/elixir-in-the-type-system-quadrant/

    • @sawood2010
      @sawood2010 ปีที่แล้ว

      @@JacobLuetzow thx man. So atoms are key/value pairs where the value and key are the same... like ':ok' is the same as json ok: 'ok' or in a dictionary ['ok': 'ok'] ?

    • @JacobLuetzow
      @JacobLuetzow  ปีที่แล้ว

      Atoms are constants whose values are their own name, like symbols in ruby. :ok == "ok"
      hexdocs.pm/elixir/Atom.html

    • @sawood2010
      @sawood2010 ปีที่แล้ว

      @@JacobLuetzow That hurts my brain. I've never used ruby. The company I work for uses dotnet and angular. but it's like the values true and false. that's neat

  • @ruhnet
    @ruhnet 2 ปีที่แล้ว +7

    Great stuff! One thing though: using UUIDs in your DB can massively slow down the DB when there is lots of data, so in general, integers is a better best practice option unless you have a specific reason to use UUIDs. :)

    • @JacobLuetzow
      @JacobLuetzow  2 ปีที่แล้ว +4

      Thank you, I appreciate the kind words! I'll also take a little criticism :). I'll admit, using the words "best practice" probably wasn't the best choice, but saying integers are "best practice" isn't the correct answer either. The debate of UUIDs vs. Integers continues, haha. I like this blog post about it (brandur.org/nanoglyphs/026-ids), and it's always good to research your architecture choices!

    • @ruhnet
      @ruhnet 2 ปีที่แล้ว +4

      @@JacobLuetzow Yes, it underscores the fact that there is no "one-size-fits-all" approach. That's a great article there and breaks down a lot of the pros and cons. There are of course benefits to both ways. In general, my opinion is that integers usually fit a small project better (single node type stuff), because of ease of management with human manual modifications and the like. Larger and more scalable projects it of course depends. An argument for UUIDs is that on a smaller project, it doesn't matter anyway, as performance will still be high, and on a larger project it might or might not, and UUIDs could offer other benefits (like collision avoidance). So yeah, "best practice" is probably the wrong term for either option. 😀 Looking forward to more of your great videos. 👍

    • @JacobLuetzow
      @JacobLuetzow  2 ปีที่แล้ว +2

      🙌🏻thanks, would love to have you in my discord server.

    • @ruhnet
      @ruhnet 2 ปีที่แล้ว

      @@JacobLuetzow Will do!

  • @AndrewBerry-n6e
    @AndrewBerry-n6e 3 หลายเดือนก่อน

    Great content! Havin one issue though, when I run psql -U andy real_deal_api_dev I get the following error ... psql: error: connection to server on socket "/var/run/postgresql/.s.PGSQL.5433" failed: FATAL: role "andy" does not exist.
    I do exist, correctly in the container and in dev.esx. However I notice the error refers to post 5433 for some reason. Again the port in the container is 5432. How do I get the ports set up correctly?

    • @AndrewBerry-n6e
      @AndrewBerry-n6e 3 หลายเดือนก่อน +1

      Oh, I think maybe I should be running psql from within the docker container. I stupidly thought I needed to install postgress on my system. So, If I'm correct I need to figure out how to do that on linux since I don't have a docker desktop.

    • @AndrewBerry-n6e
      @AndrewBerry-n6e 2 หลายเดือนก่อน +1

      Yup, all sorted, had to run the docker shell
      sudo docker exec -it bs_db bash
      then run the psql -U andy real_deal_api_dev command
      all works now
      I'll leave all this here, maybe someone else may fall into the same trap

    • @JacobLuetzow
      @JacobLuetzow  2 หลายเดือนก่อน

      ah great, I'm glad you figured it out. You wouldn't need to run docker. You'd just have to set up postgres on your system instead of docker though. Glad you figured it out!

  • @laszlobalassa8411
    @laszlobalassa8411 2 ปีที่แล้ว +1

    Great video! No offense, but why aren't you using newer version of Elixir?

    • @JacobLuetzow
      @JacobLuetzow  2 ปีที่แล้ว +2

      Thanks, man! Honestly, I had to switch to an older version for an old project and just forgot to change it before my video 😅.

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

    mix phx.gen.json is a good place to start right? for writing an API

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

      If you watch the next video in the playlist you'll learn how to create json resources using `mix phx.gen.json`
      th-cam.com/video/DRsKmU3Sytw/w-d-xo.html