You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by HUGOT Franck <fh...@sofinco.fr> on 2006/08/30 18:09:56 UTC

Problem with internal repository (checksum?)

I have trouble with my organization repository (for maven2).

 

Here is my configuration :

 

 

I have an organisation repository on a tomcat server. This repository
has been populated by all the maven plugins and my projects (this
repository is the local repository of the maven tool installed on this
machine so it has been automatically populated because this machine has
internet access).

 

I want that all developers use this repository because they don't have
access to internet.

Developers use Eclipse on Windows XP and run maven 2 with external tools
shortcuts.

 

I try 3 scenarios :

 

-          In my settings.xml I declare my new repository (abc) and run
maven :

 

Settings.xml

 

<settings>

 

<proxies>

   <proxy>

      <id>optional</id>

      <active>true</active>

      <protocol>http</protocol>

      <host>10.133.2.84</host>

      <port>8080</port>

      <nonProxyHosts>10.133.125.36</nonProxyHosts>

    </proxy>

  </proxies>

 

 <profiles>

   <profile>

     <id>developpement</id>

     <activation>

        <property>

                <name>env</name>

                <value>dev</value>

        </property>

     </activation>

     <repositories>

            <repository>

                        <id>abc</id>

                        <name>Repository interne</name>

 
<url>http://10.233.125.36:8080/m2repository</url>

            </repository>

     </repositories>

     <pluginRepositories>

            <pluginRepository>

                        <id>abc</id>

                        <name>Repository interne pour plugins</name>

 
<url>http://10.233.125.36:8080/m2repository</url>

            </pluginRepository>

     </pluginRepositories>

     </profile>

 </profiles>

 

 <activeProfiles>

   <activeProfile>developpement</activeProfile>

 </activeProfiles>

 

 

</settings>

 

The result is :

INFO] Scanning for projects...

[INFO]
------------------------------------------------------------------------
----

[INFO] Building FWK_PRM

[INFO]    task-segment: [process-resources]

[INFO]
------------------------------------------------------------------------
----

[INFO] artifact org.apache.maven.plugins:maven-resources-plugin:
checking for updates from abc

[INFO] artifact org.apache.maven.plugins:maven-resources-plugin:
checking for updates from central

Downloading:
http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-resources-p
lugin/2.2/maven-resources-plugin-2.2.pom

1/1K

1K downloaded

Downloading:
http://10.233.125.36:8080/m2repository/org/apache/maven/plugins/maven-re
sources-plugin/2.2/maven-resources-plugin-2.2.jar

4/13K

8/13K

9/13K

13/13K

13K downloaded

 

 

Why maven download the pom from repo1 and the jar from my repository? If
I look at my repository the pom is present.

 

If I replace in my settings.xml my repository id by "central" to
override maven central repository then I get the error :

 

[INFO] Scanning for projects...

[INFO]
------------------------------------------------------------------------
----

[INFO] Building FWK_PRM

[INFO]    task-segment: [process-resources]

[INFO]
------------------------------------------------------------------------
----

[INFO] artifact org.apache.maven.plugins:maven-resources-plugin:
checking for updates from central

[INFO]
------------------------------------------------------------------------

[ERROR] BUILD ERROR

[INFO]
------------------------------------------------------------------------

[INFO] The plugin 'org.apache.maven.plugins:maven-resources-plugin' does
not exist or no valid version could be found

[INFO]
------------------------------------------------------------------------

[INFO] For more information, run Maven with the -e switch

[INFO]
------------------------------------------------------------------------

[INFO] Total time: < 1 second

[INFO] Finished at: Wed Aug 30 17:55:58 CEST 2006

[INFO] Final Memory: 1M/2M

[INFO]
------------------------------------------------------------------------

 

 

 

So, I try another test. I specify a proxy setting to download the
resources plugin from internet and restart the command and get this
error :

 

[INFO] Scanning for projects...

Downloading:
http://10.233.125.36:8080/m2repository/sft/framework/tru/FWK/2005.3/FWK-
2005.3.pom

1/1K

1K downloaded

[WARNING] *** CHECKSUM FAILED - Error retrieving checksum file for
sft/framework/tru/FWK/2005.3/FWK-2005.3.pom - IGNORING

 

 

 

Because my project pom refer to this dependency maven try to download it
from my organization repository, this works but I get this warning.

Indeed, there is no checksum file for my projects installed on my
organization repository, why? Does maven don't create this file
automatically?

Is it because I use install-file goal? 

 

Thanks in advance.

 

Franck HUGOT

 

 

 

 

 

 

 

 

 

 


Re: Problem with internal repository (checksum?)

Posted by Arnaud Bailly <ab...@oqube.com>.
"HUGOT Franck" <fh...@sofinco.fr> writes:

> I have an organisation repository on a tomcat server. This repository
> has been populated by all the maven plugins and my projects (this
> repository is the local repository of the maven tool installed on this
> machine so it has been automatically populated because this machine has
> internet access).

In general, using a local repository (one populated with mvn install)
a remote one is not a good idea, as the repository will lack some
important pieces of information generated at deploy time (eg. cheksum
and snapshot versions at least).

You would be better off using a mirror  such as proximity or
maven-proxy if you want/need to insulate/control what is downloaded in
dev. You should not confound proxy and mirrors: The former are just
network handlers for accessing another repo, while the latter are ful
blown replicas of another repo (eg. central).

>  
>
> Why maven download the pom from repo1 and the jar from my repository? If
> I look at my repository the pom is present.
>
>  
>
> If I replace in my settings.xml my repository id by "central" to
> override maven central repository then I get the error :
>
>
> [INFO] The plugin 'org.apache.maven.plugins:maven-resources-plugin' does
> not exist or no valid version could be found
>

This is normal as the plugin's informations is surely missing in your
local repo. 

>
>  
>
> Because my project pom refer to this dependency maven try to download it
> from my organization repository, this works but I get this warning.
>
> Indeed, there is no checksum file for my projects installed on my
> organization repository, why? Does maven don't create this file
> automatically?
>

Yes, using deploy goal. 

> Is it because I use install-file goal? 

Right :-) 


-- 
OQube < software engineering \ génie logiciel >
Arnaud Bailly, Dr.
\web> http://www.oqube.com


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org