directory-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Benjamin, Roy" <rbenja...@ebay.com>
Subject RE: Embedded ApacheDS examples not working
Date Thu, 29 Jul 2010 21:44:29 GMT
Thanks Kiran,

I still don't find a pom, is there a repository I need to use ?


D:\DS\apacheds-10-trunks\apacheds-archetype-webapp\src>svn up
U    main\resources\archetype-resources\src\main\java\StartStopListener.java
U    main\resources\archetype-resources\src\main\resources\log4j.properties
U    main\resources\archetype-resources\pom.xml
Updated to revision 980589.

D:\DS\apacheds-10-trunks\apacheds-archetype-webapp\src>svn status

D:\DS\apacheds-10-trunks\apacheds-archetype-webapp\src>cd ..

D:\DS\apacheds-10-trunks\apacheds-archetype-webapp>svn up
U    pom.xml
U    archetype-catalog.xml
Updated to revision 980589.

D:\DS\apacheds-10-trunks\apacheds-archetype-webapp>mvn install
[INFO] Scanning for projects...
Downloading: http://repository.corp.ebay.com/central//org/apache/directory/project/project/15/project-15.pom
[INFO] Unable to find resource 'org.apache.directory.project:project:pom:15' in repository
ebox.central (http://repository.corp.ebay.com/central/)
Downloading: http://repository.corp.ebay.com/ebox/releases//org/apache/directory/project/project/15/project-15.pom
[INFO] Unable to find resource 'org.apache.directory.project:project:pom:15' in repository
ebox.releases (http://repository.corp.ebay.com/ebox/releases/)
Downloading: http://repository.corp.ebay.com/central//org/apache/directory/project/project/15/project-15.pom
[INFO] Unable to find resource 'org.apache.directory.project:project:pom:15' in repository
central (http://repo1.maven.org/maven2)
[INFO] ------------------------------------------------------------------------
[ERROR] FATAL ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Failed to resolve artifact.

GroupId: org.apache.directory.project
ArtifactId: project
Version: 15

Reason: Unable to download the artifact from any repository

  org.apache.directory.project:project:pom:15

from the specified remote repositories:
  ebox.common (http://repository.corp.ebay.com/ebox/common/),
  ebox.releases (http://repository.corp.ebay.com/ebox/releases/),
  central (http://repository.corp.ebay.com/central/),
  ebox.3rdparty (http://repository.corp.ebay.com/ebox/3rdparty/),
  ebox.central (http://repository.corp.ebay.com/central/)



[INFO] ------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.reactor.MavenExecutionException: Cannot find parent: org.apache.directory.project:project
for project: org.apache.directory.samples:apacheds-archetype-webapp:maven-archetype:1.5.8-SNAPSHOT
for project
archetype-webapp:maven-archetype:1.5.8-SNAPSHOT
        at org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:432)
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:300)
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:137)
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:356)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
        at java.lang.reflect.Method.invoke(Method.java:599)
        at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
        at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
        at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
        at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.project.ProjectBuildingException: Cannot find parent: org.apache.directory.project:project
for project: org.apache.directory.samples:apacheds-archetype-webapp:maven-archetype:1.5.8-SNAPSHOT
es:apacheds-archetype-webapp:maven-archetype:1.5.8-SNAPSHOT
        at org.apache.maven.project.DefaultMavenProjectBuilder.assembleLineage(DefaultMavenProjectBuilder.java:1398)
        at org.apache.maven.project.DefaultMavenProjectBuilder.buildInternal(DefaultMavenProjectBuilder.java:823)
        at org.apache.maven.project.DefaultMavenProjectBuilder.buildFromSourceFileInternal(DefaultMavenProjectBuilder.java:508)
        at org.apache.maven.project.DefaultMavenProjectBuilder.build(DefaultMavenProjectBuilder.java:200)
        at org.apache.maven.DefaultMaven.getProject(DefaultMaven.java:632)
        at org.apache.maven.DefaultMaven.collectProjects(DefaultMaven.java:515)
        at org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:419)
        ... 11 more
Caused by: org.apache.maven.project.ProjectBuildingException: POM 'org.apache.directory.project:project'
not found in repository: Unable to download the artifact from any repository

  org.apache.directory.project:project:pom:15

from the specified remote repositories:
  ebox.common (http://repository.corp.ebay.com/ebox/common/),
  ebox.releases (http://repository.corp.ebay.com/ebox/releases/),
  central (http://repository.corp.ebay.com/central/),
  ebox.3rdparty (http://repository.corp.ebay.com/ebox/3rdparty/),
  ebox.central (http://repository.corp.ebay.com/central/)

 for project org.apache.directory.project:project
        at org.apache.maven.project.DefaultMavenProjectBuilder.findModelFromRepository(DefaultMavenProjectBuilder.java:605)
        at org.apache.maven.project.DefaultMavenProjectBuilder.assembleLineage(DefaultMavenProjectBuilder.java:1394)
        ... 17 more
Caused by: org.apache.maven.artifact.resolver.ArtifactNotFoundException: Unable to download
the artifact from any repository

  org.apache.directory.project:project:pom:15

from the specified remote repositories:
  ebox.common (http://repository.corp.ebay.com/ebox/common/),
  ebox.releases (http://repository.corp.ebay.com/ebox/releases/),
  central (http://repository.corp.ebay.com/central/),
  ebox.3rdparty (http://repository.corp.ebay.com/ebox/3rdparty/),
  ebox.central (http://repository.corp.ebay.com/central/)


        at org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:228)
        at org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:90)
        at org.apache.maven.project.DefaultMavenProjectBuilder.findModelFromRepository(DefaultMavenProjectBuilder.java:558)
        ... 18 more
Caused by: org.apache.maven.wagon.ResourceDoesNotExistException: Unable to download the artifact
from any repository
        at org.apache.maven.artifact.manager.DefaultWagonManager.getArtifact(DefaultWagonManager.java:349)
        at org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:216)
        ... 20 more
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1 second
[INFO] Finished at: Thu Jul 29 14:42:12 PDT 2010
[INFO] Final Memory: 2M/6M
[INFO] ------------------------------------------------------------------------
D:\DS\apacheds-10-trunks\apacheds-archetype-webapp>













































-----Original Message-----
From: ayyagarikiran@gmail.com [mailto:ayyagarikiran@gmail.com] On Behalf Of Kiran Ayyagari
Sent: Thursday, July 29, 2010 1:56 PM
To: users@directory.apache.org
Subject: Re: Embedded ApacheDS examples not working

hi Roy,

     I have updated the webapp archetype to the latest version (1.5.8-SNAPSHOT).
     There was a bug which affects the way schema loader extracts the
schema in a container
     environment (this was fixed after releasing 1.5.7 hence I used
the latest version)

    Please follow the below instructions to build the sample web app
    (note: many steps are identical to those present on the webpage[1] )

    1. either do a complete checkout and build or just run 'svn up' if
you have already checked it out

     svn co http://svn.apache.org/repos/asf/directory/samples/trunk/apacheds-archetype-webapp
     cd apacheds-archetype-webapp
     mvn install

    2. mvn archetype:generate -DarchetypeGroupId=org.apache.directory.samples \
                       -DarchetypeArtifactId=apacheds-archetype-webapp \
                       -DarchetypeVersion=1.5.8-SNAPSHOT \
                       -DgroupId=org.apache.directory.samples.embed.webapp \
                       -DartifactId=ApacheDS -Dversion=1.0-SNAPSHOT

       (note: only the archetype's version was changed, remaining all are same)

    3. running

       jetty:

        mvn  jetty:run
-Dschema.resource.location=<complete-path-to>/pacheds-all-1.5.8-SNAPSHOT.jar

      tomcat:

         a. copy the app folder from ApacheDS/target to the webapps folder

         b. set/export
JAVA_OPTS="-Dschema.resource.location=<complete-path-to>/pacheds-all-1.5.8-SNAPSHOT.jar"

         c. start the tomcat

HTH

Kiran Ayyagari



[1] http://directory.apache.org/apacheds/1.5/43-embedding-apacheds-as-a-web-application.html

On Fri, Jul 30, 2010 at 12:21 AM, Benjamin, Roy <rbenjamin@ebay.com> wrote:
> Hi,
>
> I have ApacheDS 1.5.7 installed.  I also have sources.
>
> I've found two similar examples on the ApacheDS site for running the server embedded
> in a servlet.  I can't get either one to work...
>
> ---
> One example is at: http://directory.apache.org/apacheds/1.5/43-embedding-apacheds-as-a-web-application.html
>
> I've been unable to build the example.  The first problem was that it uses org.apache.directory.server.core.DefaultDirectoryService
> which is not a public class.  So I changed the StartStopListener package to org.apache.directory.server.core,
> one compile problem solved.
>
> The example also uses:
>    org.apache.directory.server.ldap.LdapServer
>    org.apache.directory.server.protocol.shared.transport.TcpTransport
> I cannot find these classes anywhere, in 1.5.7  they seem to be a part of 1.5.6 only.
 BUT
> I cannot build 1.5.6 (which would load the jars to my local repository) because the project
> parent pom no longer exists, seems not to be in svn, or in some maven repo somewhere..
>
>
> btw.  The parent pom for the apacheds-archetype-webapp also does not seem to exist...
 ahg...
>
>
> ---
> Another example is at: https://cwiki.apache.org/DIRxSRVx10/embedding-apacheds-as-a-web-application.html
>
> I've been able to build this example, however it cannot be started in Tomcat.   The
example uses javax.naming.directory.InitialDirContext
> and Tomcat 5.5.29 explodes with exceptions trying to use this class.
>
>
> +++
> I can send stack traces etc... but first am I using the correct list?
>
> Should these examples work?  What release of ApacheDS ?   How to build ?
>
> Thanks
> Roy
>
>
>

Mime
View raw message