Multiple Output Paths Gone?

I just took a look at Aurora, which I've been eagerly anticipating, and
everything looks fantastic... except where is the "multiple output path"
feature? Without this feature the product is unusable for debugging code
built by complex ANT scripts: in order to debug one needs to have the
classes compiled (externally) to multiple directories on the class path. In
3.0, multiple output paths mostly solved this, and in 1094 adding these
classes as libraries did the trick; unfortunately, in 1108 adding these
classes as libraries causes a "duplicate class found in the file..." error
in the editor for each class (logical enough: what is a compiled version of
the file I'm working on doing in a library). It seems your intent was to
have the new modules feature provide this kind of multiple output
functionality, but this feature isn't powerfull enough to solve the problem
either (I'm looking at a project with multiple output directories in each
module). So in short is there a way to set the classpath for
running/debugging without causing the editor to highlight every class as a
duplicate? If not I would suggest that this be made a priority. One of
3.0's great strength was that unlike some other IDEs it didn't demand the
user use compilation and module management "features" that merely got in the
way of real compilation and module management systems; I hope this will not
change in the future.
Thanks,
Maciej Szefler


5 comments
Comment actions Permalink

With different modules, you can easily achieve this.

--
Lars Köhler

0
Comment actions Permalink

I admit, when they took out "multiple output paths", I was skeptical at
first.

I really like the module stuff though - it's solved several problems
that we've had (accidentally introducing circular dependancies for one).

You weren't really specific about exactly what "multiple output paths"
could do that you don't think the modules feature can, though.

Donald

0
Comment actions Permalink

You see, I have a module system defined using ANT build scripts, each module
has its own build file. I don't need IDE module features to prevent circular
dependencies: my module system already makes this impossible. Each one of my
module ANT scripts may generate several classes directories, one for the
main classes, one for mock objects, one for internationalization, one for
Junit test cases, one for cactus test cases, etc (i.e. the output
directories within each module are not dependency partitions, but rather
functional partitions). There are multiple output directories in each module
because for various reasons certain classes and resources may need to be
packaged in separate jar files, and the output directories do not have a
one-to-one correspondence with source directories. Now I'm sure IDEA is very
good at building projects, however I'm happy with ANT and have no intention
of letting my IDE compile my code, ever! When I go to run/debug, I need to
have the classpath reflect all those ANT output directories, i.e. the mock
objects, the main classes, the test classes, the internationalization, etc;
I can't do this with Aurora directly (it supports at most two output
directories one for classes, one for test classes), the only thing I can do
is (a) add an ANT script that consolidates the output directories of each
module into one big "module output" directory or (b) create a seperate
Aurora module that specifies as libraries all the relevant ANT outputs. (a)
is not appealing as it requires modification of the build process. (b) is a
bit better, but still inelegant as it requires unnatural use of libraries
and modules to achieve the end of a modified classpath. I understand that if
you are compiling from IDEA the module scheme is clean, it makes sense, and
is an improvement over the previous version, but for those of us with
complex ant-based projects that never use the internal compilation features,
it is a step back. What is needed is an ability to specify on a per-module
basis a set of "external output paths" that could contain compiled code
without triggering a duplicate class definition error; IDEA would never
write to these directories, but would include them on the classpath for
running and debugging (essentially a "Mark as External Output" button in
addition to "Mark as Source" and "Mark as Test" buttons in the "Paths"
dialog.).


-Maciej Szefler

"Donald F. McLean" <dmclean@stsci.edu> wrote in message
news:bujapv$sjo$1@is.intellij.net...

I admit, when they took out "multiple output paths", I was skeptical at
first.

>

I really like the module stuff though - it's solved several problems
that we've had (accidentally introducing circular dependancies for one).

>

You weren't really specific about exactly what "multiple output paths"
could do that you don't think the modules feature can, though.

>

Donald

>


0
Comment actions Permalink

... and the output directories do not have a
one-to-one correspondence with source directories.


Well, in this case I would start to separate them to different source
directories (we did in our project), so there is a one-to-one
correspondence. Otherwise maintaining the build file(s) can easily
become a nightmare.

--
Lars Köhler

0
Comment actions Permalink

"Maciej Szefler" <mbs@fivesight.com> wrote in message
news:bujtpv$c78$1@is.intellij.net...

...Now I'm sure IDEA is very
good at building projects, however I'm happy with ANT and have no

intention

of letting my IDE compile my code, ever! ...

>

IDE == Integrated Development Environment

It sounds like you want IDEA to be a Java Source Code Editor, not an IDE.

Or, you could submit a request to allow you to specify an Ant script as a
replacement for it's internal make/compile mechanism. Not as a separate
option that you invoke yourself or have invoked after a build, but to be
used by IDEA to rebuild/make/compile your code. Although that way, your IDE
would be compiling your code (using your Ant Script ;-).

Tim


0

Please sign in to leave a comment.