Using Maven Efficiently

แชร์
ฝัง
  • เผยแพร่เมื่อ 20 ก.ค. 2024
  • Apache Maven is the most-used build tool in the Java world and omnipresent in the ecosystem. But so are over-usages and not-ideal practices when using Maven. In this video, I want to share my experiences and tips on how to be more pragmatic and efficient when using Maven.
    For more information: blog.sebastian-daschner.com/e...
  • วิทยาศาสตร์และเทคโนโลยี

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

  • @user-xc1rl4nc4q
    @user-xc1rl4nc4q 11 หลายเดือนก่อน +2

    Thank you for this video, you saved me 5 hours of watching the "full course".

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

    Appreciate the tutorial :) Could you maybe do some more advanced stuffs with maven plugins, like the maven shade plugin? Some years ago I remembered seeing a colleague do some magic with it to replace classes in a jar, and his explanation just flew over my head. Some other complex plugins too (where the docs are just ... confusing without an example).

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

    Wow, thank you, Sebastian. Nice looking Linux fonts, do you have fonts.conf in your dot files and maybe you can share what fonts are you using for terminal and jb idea ui/editor ?

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

      See here: blog.sebastian-daschner.com/entries/linux-terminal-font-alacritty-jetbrains-mono-emoji
      I'm using the same font in my IDE (that was the default)

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

    Could you explain more what problem you see with "mvn verify"? Isn't that essentially a shorter version of the rather clunky "mvn test-compile failsafe:integration-test failsafe:verify"?

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

      No, exactly not. That's the issue I see, it's confusing :) `mvn verify` can be thought of as an alias of `mvn package`. The `verify` aspect defines more phases, e.g. one that is called `integration-test`, which (confusingly) is not the same as failsafe:integration-test. To make `verify` actually run our *IT.java classes, you'd need to make extra configuration. Have a look at this list here: maven.apache.org/guides/introduction/introduction-to-the-lifecycle.html#lifecycle-reference (`integration-test` is listed there, however our *ITs won't be run).
      In a nutshell that's why: too confusing, `package` is much clearer from the name :)

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

    Hi Sebastian, how do you choose to use maven instead of gradle for building Quarkus Java project?

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

      Nowadays, all of my enterprise client projects are built with Maven. I like that the projects are very predictable (often the inflexibility of Maven is said to be a feature), people know what to expect, and for at least 99% of projects, the Maven/Java/project structure is sufficient

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

      @@SebastianDaschnerIT Thank you Sebastian, I did think it was interesting Quarkus is also using Maven so i'm not sure what the benefit would be from Gradle usage.

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

    i am getting this error while creating springboot project can someone help me with this ?
    NoSuchMethodError: 'void org.eclipse.m2e.core.project.ResolverConfiguration.setActiveProfiles(java.lang.String)'
    java.lang.reflect.InvocationTargetException