With these 5 Gradle benefits you'll NEVER use Maven again

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

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

  • @TomGregoryTech
    @TomGregoryTech  2 года назад +5

    Thanks for watching the video. Which Gradle benefit did you find most compelling, and why?

  • @tomekg6629
    @tomekg6629 2 года назад +6

    I always thought maven is a nightmare, but after a few years with gradle, now I enjoy migrating back to maven ;)

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

    Thank you so much!

  • @fuxtnegrx
    @fuxtnegrx Год назад +2

    How (29s + 1s +1 s) / 3 = 1s???
    Maven is lot more wordy? One pom file vs two .gradle files and 2 directories!
    I have to say that maven log is much better. Gradle sometimes crashes, and doesn't tell you why!

  • @AndiRadyKurniawan
    @AndiRadyKurniawan 2 года назад +2

    Custom tasks in gradle makes me move away from gradle. Nowadays, if you want faster maven, you'd use mvnd.

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

    You know it's all bullshit when the FIRST point depends on the gradle daemon being warmed up.

  • @jaymanik
    @jaymanik Год назад +2

    Thank you for this very informative video. It clarified many questions regarding why we were not using maven at work.

  • @vallabbharath
    @vallabbharath 5 месяцев назад +1

    @TomGregoryTech All your videos are very informative. Particularly across all your gradle related videos, the way you broke down gradle to make it easily understandable even for beginners is very good and very helpful.

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

    Gradle have extra benefit: writing script in Kotlin

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

    ive been using "gradle clean build" all along... sort of defeats the purpose of incremental build lol! oops.
    will only use "clean" in future if I actually need it.
    Thanks for the content btw

  • @guai9632
    @guai9632 2 года назад +1

    for some reason there are more good quality gradle plugins, when there are mavens. even widely used maven plugins do crazy stuff if you look closer to them. like overwriting generated source files in the target dir.
    I think the craziness of maven lifecycle creeps into people

  • @kamalhm-dev
    @kamalhm-dev 2 года назад +2

    Hi Tom thanks for keep sharing about Gradle! Would love to see how you start a new project with gradle and setting up the module

    • @TomGregoryTech
      @TomGregoryTech  2 года назад +1

      You're welcome Kamal. This Gradle tutorial is the video for you then :) ruclips.net/video/-dtcEMLNmn0/видео.html

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

    Moved to Gradle last year. I hate maven even more now.

  • @jamesdean4148
    @jamesdean4148 2 года назад +2

    How long have you been using Gradle? Yesterday I spent my whole afternoon and evening to setup a simple Multi-Project build for 2 libraries with Kotlin DSL and Kotlin implementation language.
    It had so many quirks. First, gradle init generated a fairly complex structure. I added publishing just to dig 5 places where project.version is available. Then I find that it published corrupt metadata, which lead to a NPE on the consumer's side. Different Kotlin and Java JVM targets. Old Kotlin version. Setting up integration tests - pain in the ass and a complex mess of source sets and classpath hell of configuration. And many more WTFs.
    I have 10 years of Maven and 2 years of Gradle experience. They both are good and both suck in many ways.

    • @jamesdean4148
      @jamesdean4148 2 года назад +2

      But I really don't know which one sucks more. Imperative Gradle scripts impose a myriad of inconsistent idioms, making them a pain to maintain. Incremental build works until your first test forgets that it was ment to be incremental.. at the end, Gradle is a source of WTFs too, but a faster, more complex WTF machine than Maven.

    • @TomGregoryTech
      @TomGregoryTech  2 года назад +1

      Hi James. Great summary. Thanks for sharing your experience.
      I've been using Gradle for 5 years. You're right, it is complex. It took me a long time to wrap my head around it. I've created many videos here to try to make the tool more approachable.

  • @MrVitalirapalis
    @MrVitalirapalis 2 года назад +1

    Hey Tom, i am freelancer and i completely with you, my current projects have maven as build tool, as i started to work and i saw this my face was like this :( Gradle has a much much much better documentaion

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

    actually yes i do XD

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

    developer experience sucks

  • @kitersrefuge7353
    @kitersrefuge7353 2 года назад +1

    Fantastic!..."hint hint" LOL. so good! thank you I again learned some more! Gradle is becoming demystified incrementally. I can literally work and listen to this video and learn. Byte sized...;=)...to answer your final question in the video...Migrating from Maven to Gradle even for the highly motivated has the following "issues" (not exhaustive, nor applicable everywhere): [Gradle know how], [Risks of migration and therefore management support], ["if it aint broke..."], [Plugin concomitancy from Maven to Gradle], [Some Maven builds files are enormous, or are hierarchical...how would you migrate that?], [Buy-in or the politics of build in the workplace]...the list is long :=) If there was a MavenToGradleCoversion As A service...then maybe. i.e. to be supported during a migration process or even have it done for you while you learn; i can dream right. ;=)

    • @TomGregoryTech
      @TomGregoryTech  2 года назад +1

      "MavenToGradleCoversion As A service" Great idea! I think it could work as a collaboration since there would be a lot of pre-requisite knowledge.

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

    Pretty insightful. Thank you.

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

    concise? no, its obfuscated, full of magic and gotchas

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

      If you don't maintain your build scripts properly, that is.

  • @SB-gc8wf
    @SB-gc8wf 2 года назад +1

    Hi Tom. The most compelling feature for me is the Kotlin DSL because its typesafe. If something is unclear to me I just can directly jump into the sources and see whats going on. I was just wondering why you are not using the Kotlin DSL?

    • @TomGregoryTech
      @TomGregoryTech  2 года назад +1

      Hi S B. Yes Kotlin DSL is good. I'm not using it in some of my videos right now because a) I'm waiting for it to get a bit more momentum and b) I don't have as much experience with it as the Groovy DSL.

  • @henninghoefer
    @henninghoefer 2 года назад +1

    Is Gradle also faster in CI (i.e. without a cache, without a daemon)?

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

      I haven't done this test myself but according to the Gradle article it is still faster. I would want to do an independent test though to make sure.

  • @SirWolf2018
    @SirWolf2018 2 года назад +1

    Thank you so much, you rock, this happens to be exactly what I have been needing these days. :)

    • @TomGregoryTech
      @TomGregoryTech  2 года назад +1

      You're welcome! Thanks for the continued support.

  • @thomasgeorge5261
    @thomasgeorge5261 2 года назад +1

    Really enjoying your content Tom, please keep it up!
    Unrelated question to the video, but do you have any tips for a developers like me working with languages other than Java (Python and TypeScript in my case) to get a role as a Java developer?

    • @TomGregoryTech
      @TomGregoryTech  2 года назад +2

      Hi Thomas. Thanks for your comments. I have worked with a few people who transitioned to Java within a company that was using several languages. One switched Python > Java. If you don't have that luxury, maybe you can get a slightly more junior position than you're used to, then climb back up once you have more Java experience. Just an idea :)

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

      @@TomGregoryTech thanks Tom, that's useful to know!

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

    don't be afraid of XML just avoid it in your life :)

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

    do the incremental builds or daemon matter if it is being spun up through a docker container/image?
    if not, which is faster in this scenario?

    • @TomGregoryTech
      @TomGregoryTech  Год назад +2

      Hi Mike. If you start Gradle within a short-lived Docker container, you won't benefit from an already running daemon. So startup will be slower.
      Similar story with incremental build.
      Consider persisting Gradle's caches for faster builds. I show you how to do this in GItHub in this video ruclips.net/video/a7T2MU2l-es/видео.html

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

    I wish I could use it, did for a while but the JavaFX native plugin simply doesn't work for quite a while now (technically it does, but an important task isn't without manually hacking it in). Maintainers tell me it's because of them being small and Gradle changing too often. :(

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

      Interesting. Yes we do have breaking changes to take care of in major Gradle releases. Guess you're stuck on Maven for now then?

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

      why do one even need a plugin for fx? isn't it just place fxml along with your classes and just run it?

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

    This guy is trying to convince me to never use maven again and replace it with gradle. well I am using ant! :P

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

    Excellent

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

    How about SBT though ? 🤔

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

      Hi Dany. I haven't worked with Scala projects yet.

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

      People use it for java projects too

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

      Hi Dany. I wasn't aware of that so thanks for filling me in. I'm interested to know why you'd choose SBT for a pure Java project.

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

      I dont have an opinion about it, I thought you could clear this up for me 😄
      I guess people like it for simplicity, dont know about it performance though

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

    1 sec or 10 sec or 1 min - it just does not change anything.