oh I was not in the trunk and haven't seen the modules...
The best would certainly be a sub dir + a module "hbase-client".
If that is too much work with moving files around, you could start a
hbase-client module without any files in it, just a dumb pom.xml that
excludes everything not needed (see the attached example; projects that
include that dependency will not go for the org.eclipse.jdt dependency
for instance).
But in any case you'll have to maintain a exclusion list that will be
quite big; and many libs have to be excluded from hbase:core AND from
hadoop:core
One can also argue, why these dependencies got in initially...still I
also think it makes sense (We actually also use a stripped down jar set,
reducing client sizes by 15 Mb)
If you then look further for a one-piece-jar (for the poor without
maven), the shade plugin would do the job.
Regards
Al
Am 14.05.2010 18:59, schrieb Lars Francke:
> Sorry. I accidentally hit "send" too soon. Damn phone keyboards.
>
> HBase already uses sub modules. But to split this up even further we'd have
> to refactor the code which won't be easy.
>
> So what we thought of doing is provide a second .pom for the same
> code/artifact but with a stripped down set of dependencies. There are
> multiple ways of doing this. Do you have any experience with this use-case
> and provide insight into a good solution? That'd be great as I've never done
> _this_ in particular.
>
> Any help is appreciated.
>
> Cheers,
> Lars
>
>
>>
>> On May 14, 2010 6:10 PM, "Al Lias" <[email protected]> wrote:
>>
>> ...Maven can have submodules, ea...
>
>>
>>> I'm sorry I must have missed your answer somehow.
>>>
>>> The problem with using 1 jar "everywhere" ...
>
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>hbase-client</artifactId>
<packaging>jar</packaging>
<name>HBase Client</name>
<parent>
<groupId>org.apache.hbase</groupId>
<artifactId>hbase</artifactId>
<version>0.21.0-SNAPSHOT</version>
</parent>
<!-- I use a separate WAR project to check whats left. Also, my intellj dependency
viewer does a good job on figuring out whats needed. -->
<dependencies>
<dependency>
<groupId>org.apache.hbase</groupId>
<artifactId>hbase-core</artifactId>
<version>0.21.0-SNAPSHOT</version>
<exclusions> <!-- sample, incomplete!-->
<exclusion>
<groupId>org.apache.thrift</groupId>
<artifactId>thrift</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-simple</artifactId>
</exclusion>
<exclusion>
<groupId>org.mortbay.jetty</groupId>
<artifactId>jetty</artifactId>
</exclusion>
<exclusion>
<groupId>org.jruby</groupId>
<artifactId>jruby-complete</artifactId>
</exclusion>
<exclusion>
<groupId>commons-cli</groupId>
<artifactId>commons-cli</artifactId>
</exclusion>
<exclusion>
<groupId>org.eclipse.jdt</groupId>
<artifactId>core</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.apache.hadoop</groupId>
<artifactId>hadoop-core</artifactId>
<exclusions>
<exclusion>
<groupId>org.eclipse.jdt</groupId>
<artifactId>core</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.apache.hadoop</groupId>
<artifactId>zookeeper</artifactId>
</dependency>
</dependencies>
</project>