[Building Sakai] Trunk mixing snapshot versions and not building

Anthony Whyte arwhyte at umich.edu
Sun Jan 10 07:16:54 PST 2010


The pre-2.6 api/util dependencies are referenced in a "Pre-K1" profile  
which, if defined properly, has to be explicitly activated in order to  
be included in the build.  In the case of basiclti the default profile  
is "K1".

As a test before building Sakai trunk I removed the following folders  
from my .m2 repo in order to force a reinstall if the dependencies  
were requested:

/basiclti (1.0-SNAPSHOT)

Pre-2.6 api and utils (note: there are no 2.7-SNAPSHOT versions of  
these api/util projects available to download)

/sakai-authz-api
/sakai-entity-api
/sakai-event-api
/sakai-site-api
/sakai-tool-api
/sakai-util
/sakai-util-api
/sakai-user-api

I then performed a regular build of Sakai trunk.  As expected the  
basiclti binaries were downloaded, installed and deployed to Tomcat.   
I encountered no build errors and Tomcat 5.5.28 started up fine.

That said, the basiclti "pre-K1" profiles in basiclti are wrong  
because the pre-K1 dependencies referenced rely on the $ 
{sakai.version} variable for their version, which is inherited from  
the <parent> master pom, currently versioned as 2.7-SNAPSHOT in  
basiclti.  As I noted above, none of the pre-2.6 apis/util listed  
above are available in a 2.7-SNAPSHOT version (for obvious reasons).

I've wanted to remove the pre-K1 profile and instead provide a 2.5  
version of basiclti with a 2.5.x branch.  This means in practice an  
additional branch to maintain--a bit of extra work which build  
profiles of this type are an attempt to obviate.  But if you look at  
the profile <activation> snippets below you'll notice that they rely  
on the discovery of the existence/non-existence of particular files  
along a particular path for activation (the K1 profile works in spite  
of this because it's activated by default).  I regard this "exists"  
approach as rather brittle and a bad practice since it assumes that a  
developer working with the code is fully cognizant of the fact that  
they must download the code to a specific local location in order for  
a profile such as "Pre-K1" to execute properly.

I prefer approaches that allow developers to download the code  
anywhere they please before installing it.

Cheers,

Anth


<id>Pre-K1</id>
             <activation>
                 <file>
                     <exists>../master/../component/pom.xml</exists>
                 </file>
             </activation>
. . . .

<id>K1</id>
             <activation>
                 <file>
                     <!--
                         Because this is relative to base pom, cannot
                         compile in a sub-diectory
                     -->
                     <exists>../master/../kernel-deploy/pom.xml</exists>
                 </file>
                 <activeByDefault>true</activeByDefault>
             </activation>
. . . .



On Jan 9, 2010, at 3:30 PM, Steven Githens wrote:

> David Horwitz wrote:
>> Odd looks like a bad dependency in basic LTI - its referencing entity
>> api which is now in kernel ... and nightly seems fine ...
>>
>>
>
> Yeah, I actually just got it to work after commenting out the  
> basiclti stuff ( see attached patch ).
>
> -s
>
>> D
>>
>> On 01/09/2010 08:39 PM, Steven Githens wrote:
>>
>>> Hi all, Happy New Year!
>>>
>>> Is anyone else having issues build fresh checkouts of trunk?  It  
>>> appears to mixing 2.8 and 2.7 versions of some things.
>>>
>>> I also used -Dmaven.repo.local to use a fresh maven repo to make  
>>> sure it wasn't any stale jars/poms I had.
>>>
>>> Cheers,
>>> Steve
>>>
>>> The error out is below:
>>>
>>> Missing:
>>> ----------
>>> 1) org.sakaiproject:sakai-entity-api:jar:2.7.0-SNAPSHOT
>>>
>>>  Try downloading the file manually from the project website.
>>>
>>>  Then, install it using the command:
>>>      mvn install:install-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-entity-api -Dversion=2.7.0-SNAPSHOT - 
>>> Dpackaging=jar -Dfile=/path/to/file
>>>
>>>  Alternatively, if you host your own repository you can deploy the  
>>> file there:
>>>      mvn deploy:deploy-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-entity-api -Dversion=2.7.0-SNAPSHOT - 
>>> Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
>>>
>>>  Path to dependency:
>>>      1) org.sakaiproject:core-deploy:pom:2.8-SNAPSHOT
>>>      2) org.sakaiproject.basiclti:basiclti-assembly:zip:tomcat- 
>>> overlay:1.0-SNAPSHOT
>>>      3) org.sakaiproject.basiclti:basiclti-util:jar:1.0-SNAPSHOT
>>>      4) org.sakaiproject:sakai-entity-api:jar:2.7.0-SNAPSHOT
>>>
>>> 2) org.sakaiproject:sakai-event-api:jar:2.7.0-SNAPSHOT
>>>
>>>  Try downloading the file manually from the project website.
>>>
>>>  Then, install it using the command:
>>>      mvn install:install-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-event-api -Dversion=2.7.0-SNAPSHOT - 
>>> Dpackaging=jar -Dfile=/path/to/file
>>>
>>>  Alternatively, if you host your own repository you can deploy the  
>>> file there:
>>>      mvn deploy:deploy-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-event-api -Dversion=2.7.0-SNAPSHOT - 
>>> Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
>>>
>>>  Path to dependency:
>>>      1) org.sakaiproject:core-deploy:pom:2.8-SNAPSHOT
>>>      2) org.sakaiproject.basiclti:basiclti-assembly:zip:tomcat- 
>>> overlay:1.0-SNAPSHOT
>>>      3) org.sakaiproject.basiclti:basiclti-util:jar:1.0-SNAPSHOT
>>>      4) org.sakaiproject:sakai-event-api:jar:2.7.0-SNAPSHOT
>>>
>>> 3) org.sakaiproject:sakai-site-api:jar:2.7.0-SNAPSHOT
>>>
>>>  Try downloading the file manually from the project website.
>>>
>>>  Then, install it using the command:
>>>      mvn install:install-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-site-api -Dversion=2.7.0-SNAPSHOT - 
>>> Dpackaging=jar -Dfile=/path/to/file
>>>
>>>  Alternatively, if you host your own repository you can deploy the  
>>> file there:
>>>      mvn deploy:deploy-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-site-api -Dversion=2.7.0-SNAPSHOT - 
>>> Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
>>>
>>>  Path to dependency:
>>>      1) org.sakaiproject:core-deploy:pom:2.8-SNAPSHOT
>>>      2) org.sakaiproject.basiclti:basiclti-assembly:zip:tomcat- 
>>> overlay:1.0-SNAPSHOT
>>>      3) org.sakaiproject.basiclti:basiclti-util:jar:1.0-SNAPSHOT
>>>      4) org.sakaiproject:sakai-site-api:jar:2.7.0-SNAPSHOT
>>>
>>> 4) org.sakaiproject:sakai-authz-api:jar:2.7.0-SNAPSHOT
>>>
>>>  Try downloading the file manually from the project website.
>>>
>>>  Then, install it using the command:
>>>      mvn install:install-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-authz-api -Dversion=2.7.0-SNAPSHOT - 
>>> Dpackaging=jar -Dfile=/path/to/file
>>>
>>>  Alternatively, if you host your own repository you can deploy the  
>>> file there:
>>>      mvn deploy:deploy-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-authz-api -Dversion=2.7.0-SNAPSHOT - 
>>> Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
>>>
>>>  Path to dependency:
>>>      1) org.sakaiproject:core-deploy:pom:2.8-SNAPSHOT
>>>      2) org.sakaiproject.basiclti:basiclti-assembly:zip:tomcat- 
>>> overlay:1.0-SNAPSHOT
>>>      3) org.sakaiproject.basiclti:basiclti-util:jar:1.0-SNAPSHOT
>>>      4) org.sakaiproject:sakai-authz-api:jar:2.7.0-SNAPSHOT
>>>
>>> 5) org.sakaiproject:sakai-tool-api:jar:2.7.0-SNAPSHOT
>>>
>>>  Try downloading the file manually from the project website.
>>>
>>>  Then, install it using the command:
>>>      mvn install:install-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-tool-api -Dversion=2.7.0-SNAPSHOT - 
>>> Dpackaging=jar -Dfile=/path/to/file
>>>
>>>  Alternatively, if you host your own repository you can deploy the  
>>> file there:
>>>      mvn deploy:deploy-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-tool-api -Dversion=2.7.0-SNAPSHOT - 
>>> Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
>>>
>>>  Path to dependency:
>>>      1) org.sakaiproject:core-deploy:pom:2.8-SNAPSHOT
>>>      2) org.sakaiproject.basiclti:basiclti-assembly:zip:tomcat- 
>>> overlay:1.0-SNAPSHOT
>>>      3) org.sakaiproject.basiclti:basiclti-util:jar:1.0-SNAPSHOT
>>>      4) org.sakaiproject:sakai-tool-api:jar:2.7.0-SNAPSHOT
>>>
>>> 6) org.sakaiproject:sakai-util-api:jar:2.7.0-SNAPSHOT
>>>
>>>  Try downloading the file manually from the project website.
>>>
>>>  Then, install it using the command:
>>>      mvn install:install-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-util-api -Dversion=2.7.0-SNAPSHOT - 
>>> Dpackaging=jar -Dfile=/path/to/file
>>>
>>>  Alternatively, if you host your own repository you can deploy the  
>>> file there:
>>>      mvn deploy:deploy-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-util-api -Dversion=2.7.0-SNAPSHOT - 
>>> Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
>>>
>>>  Path to dependency:
>>>      1) org.sakaiproject:core-deploy:pom:2.8-SNAPSHOT
>>>      2) org.sakaiproject.basiclti:basiclti-assembly:zip:tomcat- 
>>> overlay:1.0-SNAPSHOT
>>>      3) org.sakaiproject.basiclti:basiclti-util:jar:1.0-SNAPSHOT
>>>      4) org.sakaiproject:sakai-util-api:jar:2.7.0-SNAPSHOT
>>>
>>> 7) org.sakaiproject:sakai-util:jar:2.7.0-SNAPSHOT
>>>
>>>  Try downloading the file manually from the project website.
>>>
>>>  Then, install it using the command:
>>>      mvn install:install-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-util -Dversion=2.7.0-SNAPSHOT -Dpackaging=jar - 
>>> Dfile=/path/to/file
>>>
>>>  Alternatively, if you host your own repository you can deploy the  
>>> file there:
>>>      mvn deploy:deploy-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-util -Dversion=2.7.0-SNAPSHOT -Dpackaging=jar - 
>>> Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
>>>
>>>  Path to dependency:
>>>      1) org.sakaiproject:core-deploy:pom:2.8-SNAPSHOT
>>>      2) org.sakaiproject.basiclti:basiclti-assembly:zip:tomcat- 
>>> overlay:1.0-SNAPSHOT
>>>      3) org.sakaiproject.basiclti:basiclti-util:jar:1.0-SNAPSHOT
>>>      4) org.sakaiproject:sakai-util:jar:2.7.0-SNAPSHOT
>>>
>>> 8) org.sakaiproject:sakai-user-api:jar:2.7.0-SNAPSHOT
>>>
>>>  Try downloading the file manually from the project website.
>>>
>>>  Then, install it using the command:
>>>      mvn install:install-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-user-api -Dversion=2.7.0-SNAPSHOT - 
>>> Dpackaging=jar -Dfile=/path/to/file
>>>
>>>  Alternatively, if you host your own repository you can deploy the  
>>> file there:
>>>      mvn deploy:deploy-file -DgroupId=org.sakaiproject - 
>>> DartifactId=sakai-user-api -Dversion=2.7.0-SNAPSHOT - 
>>> Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
>>>
>>>  Path to dependency:
>>>      1) org.sakaiproject:core-deploy:pom:2.8-SNAPSHOT
>>>      2) org.sakaiproject.basiclti:basiclti-assembly:zip:tomcat- 
>>> overlay:1.0-SNAPSHOT
>>>      3) org.sakaiproject.basiclti:basiclti-util:jar:1.0-SNAPSHOT
>>>      4) org.sakaiproject:sakai-user-api:jar:2.7.0-SNAPSHOT
>>>
>>> ----------
>>> 8 required artifacts are missing.
>>>
>>> for artifact:
>>>  org.sakaiproject:core-deploy:pom:2.8-SNAPSHOT
>>>
>>> from the specified remote repositories:
>>>  central (http://repo1.maven.org/maven2),
>>>  sakai-maven2-snapshots (http://source.sakaiproject.org/maven2-snapshots 
>>> ),
>>>  sakai-ibiblio-mirror (http://source.sakaiproject.org/maven2- 
>>> ibiblio),
>>>  default (http://repo1.maven.org/maven2),
>>>  sakai-maven (http://source.sakaiproject.org/maven2)
>>>
>>> _______________________________________________
>>> sakai-dev mailing list
>>> sakai-dev at collab.sakaiproject.org
>>> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
>>>
>>> TO UNSUBSCRIBE: send email to sakai-dev-unsubscribe at collab.sakaiproject.org 
>>>  with a subject of "unsubscribe"
>>>
>>
>> _______________________________________________
>> sakai-dev mailing list
>> sakai-dev at collab.sakaiproject.org
>> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
>>
>> TO UNSUBSCRIBE: send email to sakai-dev-unsubscribe at collab.sakaiproject.org 
>>  with a subject of "unsubscribe"
>>
>
> Index: core-deploy/pom.xml
> ===================================================================
> --- core-deploy/pom.xml	(revision 71221)
> +++ core-deploy/pom.xml	(working copy)
> @@ -25,7 +25,6 @@
>             </activation>
>             <properties>
>                 <clean.targets>
> -                    components/basiclti-pack;
>                     components/emailtemplateservice-pack;
>                     components/coursemanagement-hibernate-pack;
>                     components/gradebook-service-pack;
> @@ -43,12 +42,14 @@
>                 <deploy.target>tomcat-overlay</deploy.target>
>             </properties>
>             <dependencies>
> +            <!--
>                 <dependency>
>                     <groupId>org.sakaiproject.basiclti</groupId>
>                     <artifactId>basiclti-assembly</artifactId>
>                     <classifier>tomcat-overlay</classifier>
>                     <type>zip</type>
>                 </dependency>
> +                -->
>                 <dependency>
>                     <groupId>org.sakaiproject.common</groupId>
>                     <artifactId>sakai-common-assembly</artifactId>
> @@ -121,7 +122,6 @@
>             <id>experimental</id>
>             <properties>
>                 <clean.targets>
> -                    components/basiclti-pack;
>                     components/coursemanagement-hibernate-pack;
>                     components/emailtemplateservice-pack;
>                     components/gradebook-service-pack;
> @@ -139,12 +139,14 @@
>                 <deploy.target>tomcat-overlay</deploy.target>
>             </properties>
>             <dependencies>
> +            <!--
>                 <dependency>
>                     <groupId>org.sakaiproject.basiclti</groupId>
>                     <artifactId>basiclti-assembly</artifactId>
>                     <classifier>tomcat-overlay</classifier>
>                     <type>zip</type>
>                 </dependency>
> +                -->
>                 <dependency>
>                     <groupId>org.sakaiproject.common</groupId>
>                     <artifactId>sakai-common-assembly</artifactId>
> Index: master/pom.xml
> ===================================================================
> --- master/pom.xml	(revision 71221)
> +++ master/pom.xml	(working copy)
> @@ -94,7 +94,7 @@
>         <sakai.xerces.impl.version>2.6.2</sakai.xerces.impl.version>
>         <sakai.xerces.api.version>2.6.2</sakai.xerces.api.version>
>         <!-- Sakai modules that are versioned separately -->
> -        <sakai.basiclti.version>1.0-SNAPSHOT</sakai.basiclti.version>
> +        <!-- <sakai.basiclti.version>1.0-SNAPSHOT</ 
> sakai.basiclti.version> -->
>         <sakai.common.version>1.0.0-b03-SNAPSHOT</ 
> sakai.common.version>
>         <sakai.edu-services.version>1.0.0-beta02-SNAPSHOT</sakai.edu- 
> services.version>
>         <sakai.ets.version>0.4.0</sakai.ets.version>
> @@ -227,6 +227,7 @@
>             </dependency>
>
>             <!-- Assemblies -->
> +<!--
>             <dependency>
>                 <groupId>org.sakaiproject.basiclti</groupId>
>                 <artifactId>basiclti-assembly</artifactId>
> @@ -234,6 +235,7 @@
>                 <classifier>tomcat-overlay</classifier>
>                 <type>zip</type>
>             </dependency>
> +            -->
>             <dependency>
>                 <groupId>org.sakaiproject.common</groupId>
>                 <artifactId>sakai-common-assembly</artifactId>
> _______________________________________________
> sakai-dev mailing list
> sakai-dev at collab.sakaiproject.org
> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
>
> TO UNSUBSCRIBE: send email to sakai-dev-unsubscribe at collab.sakaiproject.org 
>  with a subject of "unsubscribe"

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20100110/688a60d0/attachment.html 


More information about the sakai-dev mailing list