How to Make a Chat App With Ktor - Building the Android App - Part 2

Поделиться
HTML-код
  • Опубликовано: 22 янв 2025

Комментарии • 38

  • @tiamabderezai5374
    @tiamabderezai5374 3 года назад +2

    Alter, nur durch deine Videos kann ich in der Tat pragmatische und nutzbare Apps herstellen. Du und Florian seid einfach die Besten in diesem Raum. Ihr seid nicht nur hervorragende Android-Entwickler, sondern auch tolle Lehrer. Ich schätze all deine Unterrichten, die Du uns beibringst. Ich wünsche Dir ein treffliches neues Jahr.

  • @chimaobicharles2032
    @chimaobicharles2032 3 года назад +6

    I am just downloading and saving them, still working on the community social media app on twitch. Honestly I fell in love with coding ever since I joined this channel all the way from Nigeria.. I Respect you Man Philip. My Mr Innovator... 💪💯🔥

    • @PhilippLackner
      @PhilippLackner  3 года назад +4

      Awesome man, thanks so much for the support!

    • @osisuper98
      @osisuper98 3 года назад

      My bro, no be only you oo. We move together by God's grace!

  • @tanjimahmed213
    @tanjimahmed213 3 года назад +1

    1st one to watch. Thanks for uploading second part. 1st part was awesome

  • @kafka5973
    @kafka5973 4 месяца назад

    Thanx philip I finished this part1 today and going to continue with part2. Your contents are always helpful for android developer like me. Keep posting.🚀🚀🚀🚀

  • @andrefilgueiras
    @andrefilgueiras 3 года назад +1

    Hi Philipp, nice video as always
    At 26:30 "Is that easy" lol
    We hope some day Android development could be that easy =]

  • @dendroid4389
    @dendroid4389 2 года назад

    this is a great playlist, I've learned a lot

  • @themindsetgarage
    @themindsetgarage 3 года назад +1

    Great tutorial. The android part got my head spinning. especially for someone who is new to compose, sounded like Greek. I guess is time to learn android Compose

    • @PhilippLackner
      @PhilippLackner  3 года назад +1

      Yea without learning compose first, this is not easy haha

    • @themindsetgarage
      @themindsetgarage 2 года назад

      @@PhilippLackner learnt compose and am back.haha . I really missed out a lot in jetpack compose.Thanks for this. keep doing more content on ktor for android devs

  • @santri.awon1
    @santri.awon1 3 года назад

    always waiting for your videos,,,, mr philipp

  • @RealformStudioXR
    @RealformStudioXR Год назад +1

    Hello Phillip, I have an issue with the mapper part, it simple does not work with client.get defining the type is not working

    • @RealformStudioXR
      @RealformStudioXR Год назад

      When I write the client.get(etc) it says there is no suitable method for that, any chance to help

    • @tonykozarev
      @tonykozarev Год назад

      @@RealformStudioXR you are using Ktor version 2.* and he is using Ktor version 1.*. This is why you are getting this error.

  • @kasemsm8092
    @kasemsm8092 3 года назад +2

    well scarlet was easy but Ktor’s web socket client is more + multiplatform benefits!

  • @duaakhaled6531
    @duaakhaled6531 2 года назад

    Thank you for the tutorials. I have a question, do you know if this kotlin code would work when i need a connection between the mobile app but with the jetson nano. and a glimpse of how to do it. Thank you

  • @coreyorndoff9417
    @coreyorndoff9417 2 года назад

    Love all the informative videos. It's a long shot but does anyone know if Philipp has done a video about sending images or files to the server?

  • @harshal_p24
    @harshal_p24 3 года назад

    I am following up this tutorial using xml rather than compose. The State in viewmodel is equivalent to StateFlow, isn't it?

  • @nipunkumarit2168
    @nipunkumarit2168 3 года назад

    Hello sir it's pleasure to see your videos, but i have facing some issues like in Android 11 i cant access android folder whether i have manage all file permission.. i also put request for saf file it will very helpful for us if you make a video how we can access android folder... And also we need more video on jetpack design like how we can setup typography and themes for both day and night mode....... At last thank you sir you are great , hope in future i can do work with you in android... HOPE YOU REPLY SIR

  • @tafelsalz1
    @tafelsalz1 2 года назад

    Hey, just a question. I implemented the websocket exactly like in this video, but i cannot receive any messages. I call onEach inside my viewmodel and print the output to console, but the output never comes. No exceptions, no nothing. I also tried the while(true) approach as stated in the official documentation and it works, but i don't like this approach. Any ideas?

  • @rezafaraji1417
    @rezafaraji1417 3 года назад

    Thank you Philipp these series was really life saving for me! I just couldn't understand why we need Message service here. could you please explain?

    • @PhilippLackner
      @PhilippLackner  3 года назад +1

      The MessageService defines how we're going to access our API. You shouldn't only create a concrete implementation of something because that will make your whole code depend on that specific implementation (like in this case you would force it to use Ktor). If you create an abstraction using an interface and pass that in your code, you can always easily change the networking library and you only need to adjust the implementation of that MessageService interface, but you don't need to change all occurences in your code

  • @fensom80
    @fensom80 2 года назад

    I want to use Nodejs as the backend. Hopefully the compose code shouldn't need much changes

  • @stzaske
    @stzaske 2 года назад

    I noticed one problem with the messageService...the database is capturing both sides of each message. If you watch at the end of the video you'll see that each chat bubble is duplicated (shown twice). Can you explain where in the code the messages are getting saved to the database? I cannot seem to find it.

    • @romanhruska7402
      @romanhruska7402 Год назад

      That is indeed happening, in Part 1 when writing code for RoomController.kt watch out for members.values.forEach { }
      inside this lambda we call messageDataSource.insertMessage(messageEntity)
      I believe it should be OUTside the lambda. So from what I see now the function should probably be more like
      suspend fun sendMessage(senderUsername: String, message: String) {
      val messageEntity = Message( // moved out of the foreach lambda
      text = message,
      username = senderUsername,
      timestamp = System.currentTimeMillis()
      )
      messageDataSource.insertMessage(messageEntity)
      members.values.forEach { member ->
      // now we want to send the message to all members in the room...
      val parsedMessage = Json.encodeToString(messageEntity) // import kotlinx.serialization.encodeToString
      member.socket.send(Frame.Text(parsedMessage))
      }
      }

  • @immanueldiaz5710
    @immanueldiaz5710 3 года назад

    Amazing video bro!! maybe we can create a ticktock clone or uber clone or any complex ui with jetpack compose it would be great!

  • @porasraval6808
    @porasraval6808 3 года назад

    Hello sir can you make a video for us and the topic is how can we send a text message in selected multiple phone numbers. (Using sqlite).need help sir💐

  • @CyberSoftSolution
    @CyberSoftSolution 3 года назад

    Android Studio said that Ktor is Depricated :( ?????

  • @tafelsalz1
    @tafelsalz1 3 года назад

    I wish i could give this video more upvotes!

  • @kazimd.saidul4212
    @kazimd.saidul4212 2 года назад

    Why not use usecase?

  • @jingxuanwang1690
    @jingxuanwang1690 2 года назад

    hi, I got some 2022-11-07 09:56:01.179 13865-13865 System.err W java.util.concurrent.CancellationException: ArrayChannel was cancelled problem why it happens

  • @anudeepananth
    @anudeepananth 3 года назад

    Could you do a tutorial on navigating from a regular composable(like a twitter post post composable) to a photo composable ( the photo view of that post ). The transition of between these 2 composables in apps like twitter and linkedIn is that the photo turns into a full screen while the background just fades to black which looks great. This isnt a regular fragmane to fragment or a composable to composable transition... #jetpackcompose

  • @علیرضانیکفال-ظ4ل
    @علیرضانیکفال-ظ4ل 3 года назад

    thank you for this

  • @mracipayam
    @mracipayam Год назад

    it does not work because of hilt updates :(