How to Build a Clean Architecture GraphQL App With Kotlin - Android Studio Tutorial

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

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

  • @anb4351
    @anb4351 ปีที่แล้ว +14

    at ~ 9:20 we can never completely see the terminal ./gradlew command you exucuted because of your face blocking the view
    you should paste it in description and also explain better / in more details on how it works

  • @elohimalves
    @elohimalves ปีที่แล้ว +48

    You're not from this world! You're so helpful with your videos! ❤️

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

      Thank you🙌❤️

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

      danke mein mann

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

      @@PhilippLackner
      What is the full command here? 9:40

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

    I await for this. Thank you for all what you do for the Android community.

  • @ryallnovember2664
    @ryallnovember2664 ปีที่แล้ว +34

    At 09:40 his face cam covers the url. here is the full command --> ./gradlew :app:downloadApolloSchema --endpoint='paste-apollo-url-here' --schema=app/src/main/graphql/schema.graphqls

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

    You are amazing man , you have a great effect in my work experience as an Android developer , keep going !

  • @Nick-cx4rs
    @Nick-cx4rs ปีที่แล้ว +1

    Bro since i started android i see you more than my family :)

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

    Going for the 100k! congrats dude you deserve the best :)

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

      🙌🙌❤️

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

      ​@@PhilippLackner btw do you mind to send me the full path that you write on terminal in 9:19? your webcam got in front of it hehe

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

    I like how your t shirt changed magically at 1:33

  • @Abelmengesha-sp6lv
    @Abelmengesha-sp6lv ปีที่แล้ว

    39:50 you clicked my country there! Love and respect from countries[39:50] Philip!

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

    Congratulation 100.000 Follower, cool

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

    I learnt a new trick today: _state.update { it.copy()} is dope. Before I was doing _state.value = _state.value.copy() which is feels repetitive . You are a Legend!

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

    Good explanation of not just GraphQL but on JetPack state and Hilt. I need to tighten up how I use JetPack state based on your video. Extremely good job.

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

    Another MasterClass from Philipp! Many Thanks!!!

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

    I was waiting for this for so long... Finally...

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

    It's a great video. There aren't many videos about this thank you. Why did we create country classes when we already have the opportunity to create custom queries in GraphQL?

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

    Thank you for always showing amazing content 🇧🇷🇧🇷🇧🇷

  • @ИгорьВялков-я1ф
    @ИгорьВялков-я1ф ปีที่แล้ว +11

    Thank you so much for interesting topics. Please don't stop to do some non-standart stuff sometimes

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

    Thanks for putting out content on complex topics

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

    You ve just blown my mind with this.. thanks boss

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

    Always learning from you Philipp.

  • @AmitVerma-iq3oe
    @AmitVerma-iq3oe 10 หลายเดือนก่อน

    Thanks for making such a video, It helps a lot, keep it up 👏

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

    Great video! I can sense that your new premium course might be about creating a ktor backend with grapql then KMM or just android 😁

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

      Actually not, I think GraphQL is a bit too niche for that 😁

  • @RahulKumar-un6ur
    @RahulKumar-un6ur ปีที่แล้ว

    Fantastic and crystal clear explanation. Thank you very much 🙏.

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

    Hi, Great Philipp, but could you please explain how to do it without use cases, can i directly access countryClient in viewModel?

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

    Thanks, Philipp, for amazing content 🇧🇷

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

    Thank you so much Philipp! This helps me a lot! :)

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

    LOL ... just finished my multi-module clean arch Android GraphQL project ... Needed this a week ago 🙂

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

      If you turn on Apollo cache you get a Flow and it looks more like the RoomDB

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

    Amazing tutorial ♥

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

    Nice explanation, tnx!

  • @МаксимСысоев-р5в
    @МаксимСысоев-р5в ปีที่แล้ว +1

    Thank you so much for your work! It's really nice content.
    Few tips if you don't mind:
    - You could provide only ApolloClient in your Dagger Module and use @Binds for map CountryClient to ApolloCountryClient. So you can use just constructor @Inject for UseCases.
    - Why did you create CountryClient in domain package? It seems that it should be in data layer too. At your solution data layer knows about domain layer but is not good and it is break Clean Architecture approach.
    But anyway it was nice video, thanks!

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

      Seems like you misunderstood something about CA then, domain is the innermost layer and is allowed to be accessed by all other layers (which is the reason CountryClient has to be in domain).
      So domain shouldn't know about data, but both presentation and data can access domain

    • @МаксимСысоев-р5в
      @МаксимСысоев-р5в ปีที่แล้ว

      @@PhilippLackner ok, maybe I missed it. Thanks.

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

    Love it ❤️
    From Algeria

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

    Sound great, but does the API or server-side need to handle anything to make this work?

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

    Awesome! I use GraphQl and this tutorial helps with the Apollo client (currently manual creation of DTOs due to lower min SDK).
    Getting closer to touching every aspect of Android development! OpenID/OAuth 2 integration soon?

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

    Thank you Philipp 👏

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

    22:21 this made my day about use cases :V

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

    Thanks Phillip for the great work. Great tutorial with great explanation. Appreciate that you take time explaining things in details. Great job. Thank you.

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

    Thank Philipp, create another one about gRPC, please

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

    Wow amazing 😍❤️

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

    Hello sir
    First, thanks for your great channel
    Secondly, can you make a video on how to build a small application from within which you only download the details of the application or features that you want?
    Thanks again

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

    Amazing bro!

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

    These auto generated model classes aren't parcelable, so how can we transfer data between different screens ?

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

    Is there any way to generate the DTOs automatically without having ro create them manually?

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

    Nice one phillip...

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

    Very interesting topics ❤

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

    What's the difference between a repository and a client?

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

    Many thanks for your work, Philipp! Would be great to have masterclass from you of working with content provider(for both cases of collecting and sharing data by app)

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

    you absolutely rule

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

    Cool! I started from initial project and finish it! All works! Great! 🙂

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

    I wonder how well this scales. I feel like with this approach you need to be at least somewhat familiar with how the data is structured on the backend whereas with a rest api you can view it as a blackbox ("I dont care how or where you get it from, just give me this and that"). You can create rest api calls on a per view/screen basis (organized by sub-urls) which only gives you what you need in one package with one call, thus saving phone resources and bandwidth. I feel like with graphql you either have data related logic on client side which maybe shouldn't be there or you use it exactly like a well implemented rest api. What am I missing here?

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

      There are many systems that have API's that grow over time from the Rest implementation. Most backends are not well designed with the client in mind, not delivering the minimal payload. Its just not been a priority for the BE community. GraphQL is a trade-off solution for these older systems where they can put a layer between the BE and the FE that allows the FE to reduce the payloads on the network, but the tradeoff is that the BE needs to be implemented that can perform those BE calls in a GraphQL way.
      If you are greenfielding a project and you know you will creating it for mobile, GraphQL is likely overload, as you can restrict your API's for mobile, or have separate calls for mobile.

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

    Mapping a list every time you fetch a data is kind of resource intensive specially when you have a large data set

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

      Did you measure it? If yes, does it effect user experience? No? Then it doesn't matter 😄
      There's a common saying that Premature optimization is the root of all evil

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

      @@PhilippLackner hmm yes loading times is much longer. Ill keep that in mind

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

      @@PhilippLackner if you implement paging I think you wont notice the difference

  • @levp1801
    @levp1801 ปีที่แล้ว +3

    What is the full command here? 9:40

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

      Still waiting the full command

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

      @@aldiguizot i actually never seen him fixing his mistakes in comments :(

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

      Kick when they say please

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

    Nice!

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

    Hey Philipp, Please can you tell me how to pdf file upload in graphql?
    mutation UploadUserHandBookFileQuery($productGroupId: String, $filePathKey: String, $file: Upload!, $enrollmentId: String) {
    uploadUserFile(
    productGroupId: $productGroupId
    filePathKey: $filePathKey
    file: $file
    enrollmentId: $enrollmentId
    ) {
    __typename
    url
    fileName
    expiresAt
    }
    }
    I am sharing query, Please help me. Thank you in advance.

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

    I love your videos. Could you dive a bit deeper into the topic and show how to handle error handling, pagination, interceptors?

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

    Wait remind me why do we need to provide usecases through modules? It's our own classes and not like ViewModel or Activities or like third-party classes such as Room DB object. Can't we just @Inject them?

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

      No, how should dagger know how to create our own classes 🤔

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

      @@PhilippLackner eh im pretty sure u can constructor inject them, we do it all the time in our code base. Well we use Dagger2 but im pretty sure Hilt does the same since its basically an extension of it. The only time we cant constructor inject them directly is when we need to inject viewmodel/presenter to activity/fragment, or when we inject stuffs like third party object like Room

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

    how to do Mutation ?

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

    hi philip.. im trying to Buy some of your course but idk how to calculate the fees , because in my visa card i have 250 euros but when i want to buy your 99 course the page tells me that i don't have money enough !! WTF Im from argentina! Can u help me pls? because im trying to buy you course every time but idk why i cant!!

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

    I am not able to download using gradlew command as it is showing me error 'could not resolve classpath' for android gradle plugin and google play services. I tried multipe thing but not working maybe due to version catalogs. I am using gradle version 8.3.1. If anyone got this and solved..please help..thank you

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

      Worked for me after changing JDK version to 11 or jbr 17 in Settings ->Build, Execution, Deployment -> Build Tools -> Gradle

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

    How to get response code?

  • @ibrahimal-zaidi6436
    @ibrahimal-zaidi6436 ปีที่แล้ว

    Cool.
    Anyone here know how to use Android Printing Framework With Jetpack compose?

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

    🇩🇿 thanks Philip

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

    Make api call with retrofit for Soap/xml please in kotlin

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

      Those are dead protocols at this point. I have never seen a tutorial showing how to use retrofit with XML on android!

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

      @philipp lackner?

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

    9:25 I cannot see the entire command :C

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

    Nice content, thanks you very much!
    Can you make video about oauth 2.0, how and where store tokens and how to autologin correctly? :)

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

    - In plugin 'com.apollographql.apollo3' type 'com.apollographql.apollo3.gradle.internal.ApolloDownloadSchemaTask' property 'schema' doesn't have a configured value. i am getting this error could you please help me

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

    Excellent, thank you very much for teaching this