MNG-3339, Maven against the IDE

Well, not exactly. But now that you’re reading…

Issue MNG-3339 highlights one interesting maven feature: everything comes from the repository. This is usually fine, since you would like to depend on stable versions for your business, but it is not so useful when you’re developing a multi module project.

Say you have your typical webapp in maven. You might have a module for the model (myapp-model) another for the view (myapp-view) and so on. Obviously, myapp-view dependes on myapp-model. Every time you make a change to the model, you need to install it to your repository for maven to build myapp-view correctly.

maven-dependency-install-to-repo

Having the source code (and even compiled classes) in the same project is not (yet) used by maven to avoid that extra step of installing to the local repository.

Now, if you’re using an IDE, it doesn’t seem convenient to install the artifact after every change, since installing means running all the test cases, which can be lengthy.

Some workarounds exist on the IDE space, like using the IDE compiler instead of maven’s mojo. But this does not work on every case and, what’s worse, leads to different results when building from the IDE and from the command line. If you don’t install myapp-model, maven will fail to build myapp-view… but your IDE might succeed!

Because this is open source… why don’t you help in raising awareness of MNG-3339. Vote for it, comment on the issue if you have an opinion, watch it or do what would be the best of all options: attach a patch!


  • My profile

    View Abel Muño's profile on LinkedIn

    amuino on Twitter

  • My projects

    The cloud market:
    Find the virtual image you need on the cloud.
  • Top Posts

  • Archives

  • Categories