<modelVersion>4.0.0</modelVersion>
<artifactId>archiva-cli</artifactId>
<name>Archiva CLI</name>
- <version>1.0-SNAPSHOT</version>
- <url>http://maven.apache.org</url>
<dependencies>
<dependency>
<groupId>org.apache.maven.archiva</groupId>
Registry section = registry.getSection( KEY );
new ConfigurationRegistryWriter().write( configuration, section );
section.save();
+
+ this.configuration = configuration;
}
public void addChangeListener( RegistryListener listener )
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-quartz</artifactId>
- <version>1.0-alpha-4-SNAPSHOT</version>
+ <version>1.0-alpha-3</version>
</dependency>
<dependency>
<groupId>org.codehaus.plexus.cache</groupId>
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-taskqueue</artifactId>
- <version>1.0-alpha-6-SNAPSHOT</version>
+ <version>1.0-alpha-6</version>
</dependency>
<dependency>
<groupId>commons-lang</groupId>
unexpectedContents.equals( FileUtils.readFileToString( file, null ) ) );
}
+/* TODO: test keeps failing in the reactor - needs to be made more robust before re-enabling
public void testGetSnapshotMetadataExpired()
throws IOException, ResourceDoesNotExistException, ProxyException, ParseException
{
unexpectedContents.equals( FileUtils.readFileToString( file, null ) ) );
}
-/* TODO: test keeps failing in the reactor - needs to be made more robust before re-enabling
public void testGetMetadataNotUpdated()
throws ResourceDoesNotExistException, ProxyException, IOException
{
assertFalse( "Check content doesn't match proxy version",
unexpectedContents.equals( FileUtils.readFileToString( file, null ) ) );
}
-*/
public void testGetMetadataUpdated()
throws IOException, ResourceDoesNotExistException, ProxyException, ParseException
assertFalse( "Check content doesn't match old version",
unexpectedContents.equals( FileUtils.readFileToString( file, null ) ) );
}
+*/
public void testSnapshotNonExistant()
throws ProxyException, IOException
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
- <version>2.5</version>
+ <version>2.4</version>
<scope>provided</scope>
</dependency>
<dependency>
<version>1.0.4</version>
<scope>runtime</scope>
</dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ <version>2.2</version>
+ </dependency>
<dependency>
<groupId>org.apache.maven.wagon</groupId>
<artifactId>wagon-http-lightweight</artifactId>
<!DOCTYPE Configure PUBLIC "-//Mort Bay Consulting//DTD Configure//EN" "http://jetty.mortbay.org/configure.dtd">
<Configure class="org.mortbay.jetty.webapp.WebAppContext">
+<New id="validation_mail" class="org.mortbay.jetty.plus.naming.Resource">
+ <Arg>mail/Session</Arg>
+ <Arg>
+ <New class="org.mortbay.naming.factories.MailSessionReference">
+ <Set name="user"></Set>
+ <Set name="password"></Set>
+ <Set name="properties">
+ <New class="java.util.Properties">
+ <Put name="mail.smtp.host">localhost</Put>
+ <Put name="mail.smtp.port">25</Put> <!-- TODO: shouldn't this default? -->
+ </New>
+ </Set>
+ </New>
+ </Arg>
+</New>
+
<New id="users" class="org.mortbay.jetty.plus.naming.Resource">
<Arg>jdbc/users</Arg>
<Arg>
*/
private ConfiguredRepositoryFactory factory;
- private List databases;
-
- private String repositoryId;
-
- /**
- * @plexus.requirement
- */
- private ReportExecutor executor;
-
private Configuration configuration;
- /**
- * @plexus.requirement role="org.apache.maven.archiva.reporting.group.ReportGroup"
- */
- private Map reports;
-
- private String reportGroup = DEFAULT_REPORT_GROUP;
-
- private static final String DEFAULT_REPORT_GROUP = "health";
-
- private String filter;
-
public String execute()
throws Exception
{
- ReportGroup reportGroup = (ReportGroup) reports.get( this.reportGroup );
-
databases = new ArrayList();
if ( repositoryId != null && !repositoryId.equals( "-" ) )
return SUCCESS;
}
- private void getReport( RepositoryConfiguration repositoryConfiguration, ReportGroup reportGroup )
- throws ReportingStoreException
- {
- ArtifactRepository repository = factory.createRepository( repositoryConfiguration );
-
- ReportingDatabase database = executor.getReportDatabase( repository, reportGroup );
-
- if ( filter != null && !filter.equals( "-" ) )
- {
- database = database.getFilteredDatabase( filter );
- }
-
- databases.add( database );
- }
-
public String runReport()
throws Exception
{
return SUCCESS;
}
- private void generateReport( ReportingDatabase database, RepositoryConfiguration repositoryConfiguration,
- ReportGroup reportGroup, ArtifactRepository repository )
- throws DiscovererException, ReportingStoreException
- {
- database.setInProgress( true );
-
- List blacklistedPatterns = new ArrayList();
- if ( repositoryConfiguration.getBlackListPatterns() != null )
- {
- blacklistedPatterns.addAll( repositoryConfiguration.getBlackListPatterns() );
- }
- if ( configuration.getGlobalBlackListPatterns() != null )
- {
- blacklistedPatterns.addAll( configuration.getGlobalBlackListPatterns() );
- }
-
- ArtifactFilter filter;
- if ( repositoryConfiguration.isIncludeSnapshots() )
- {
- filter = new AcceptAllArtifactFilter();
- }
- else
- {
- filter = new SnapshotArtifactFilter();
- }
-
- try
- {
- executor.runReports( reportGroup, repository, blacklistedPatterns, filter );
- }
- finally
- {
- database.setInProgress( false );
- }
- }
-
- public void setReportGroup( String reportGroup )
- {
- this.reportGroup = reportGroup;
- }
-
- public String getReportGroup()
- {
- return reportGroup;
- }
-
- public String getRepositoryId()
- {
- return repositoryId;
- }
-
- public void setRepositoryId( String repositoryId )
- {
- this.repositoryId = repositoryId;
- }
-
- public List getDatabases()
- {
- return databases;
- }
-
public void prepare()
throws Exception
{
import org.apache.maven.project.ProjectBuildingException;
import org.apache.maven.shared.app.company.CompanyPomHandler;
import org.apache.maven.shared.app.configuration.Configuration;
-import org.apache.maven.shared.app.configuration.ConfigurationChangeException;
-import org.apache.maven.shared.app.configuration.ConfigurationStore;
-import org.apache.maven.shared.app.configuration.ConfigurationStoreException;
-import org.apache.maven.shared.app.configuration.InvalidConfigurationException;
+import org.apache.maven.shared.app.configuration.MavenAppConfiguration;
+import org.codehaus.plexus.registry.RegistryException;
import org.codehaus.plexus.security.rbac.Resource;
import org.codehaus.plexus.security.ui.web.interceptor.SecureAction;
import org.codehaus.plexus.security.ui.web.interceptor.SecureActionBundle;
/**
* @plexus.requirement
*/
- private ConfigurationStore appConfigurationStore;
+ private MavenAppConfiguration appConfigurationStore;
/**
* The configuration.
private CompanyPomHandler companyPomHandler;
public String execute()
- throws IOException, ConfigurationStoreException, InvalidConfigurationException, ConfigurationChangeException
+ throws IOException, RegistryException
{
- appConfigurationStore.storeConfiguration( configuration );
+ appConfigurationStore.save( configuration );
return SUCCESS;
}
}
public void prepare()
- throws ConfigurationStoreException, ProjectBuildingException, ArtifactMetadataRetrievalException
+ throws ProjectBuildingException, ArtifactMetadataRetrievalException
{
- configuration = appConfigurationStore.getConfigurationFromStore();
+ configuration = appConfigurationStore.getConfiguration();
companyModel = companyPomHandler.getCompanyPomModel( configuration.getCompanyPom(), createLocalRepository() );
}
import org.apache.maven.shared.app.company.CompanyPomHandler;
import org.apache.maven.shared.app.configuration.CompanyPom;
import org.apache.maven.shared.app.configuration.Configuration;
-import org.apache.maven.shared.app.configuration.ConfigurationChangeException;
-import org.apache.maven.shared.app.configuration.ConfigurationStore;
-import org.apache.maven.shared.app.configuration.ConfigurationStoreException;
-import org.apache.maven.shared.app.configuration.InvalidConfigurationException;
+import org.apache.maven.shared.app.configuration.MavenAppConfiguration;
import org.codehaus.plexus.security.rbac.Resource;
import org.codehaus.plexus.security.ui.web.interceptor.SecureAction;
import org.codehaus.plexus.security.ui.web.interceptor.SecureActionBundle;
/**
* @plexus.requirement
*/
- private ConfigurationStore appConfigurationStore;
+ private MavenAppConfiguration appConfigurationStore;
/**
* The configuration.
private Model companyModel;
public String execute()
- throws IOException, ConfigurationStoreException, InvalidConfigurationException, ConfigurationChangeException,
- ArtifactInstallationException
+ throws IOException, ArtifactInstallationException
{
// TODO: hack for passed in String[]
String[] logo = (String[]) companyModel.getProperties().get( "organization.logo" );
}
public void prepare()
- throws ConfigurationStoreException, ProjectBuildingException, ArtifactMetadataRetrievalException
+ throws ProjectBuildingException, ArtifactMetadataRetrievalException
{
- configuration = appConfigurationStore.getConfigurationFromStore();
+ configuration = appConfigurationStore.getConfiguration();
CompanyPom companyPom = configuration.getCompanyPom();
companyModel = companyPomHandler.getCompanyPomModel( companyPom, createLocalRepository() );
import org.apache.maven.archiva.web.action.AbstractConfiguredAction;
import org.apache.maven.model.Model;
import org.apache.maven.shared.app.company.CompanyPomHandler;
-import org.apache.maven.shared.app.configuration.ConfigurationStore;
+import org.apache.maven.shared.app.configuration.MavenAppConfiguration;
/**
* Stores the company information for displaying on the page.
/**
* @plexus.requirement
*/
- private ConfigurationStore appConfigurationStore;
+ private MavenAppConfiguration appConfigurationStore;
public String execute()
throws Exception
{
- Model model = handler.getCompanyPomModel( appConfigurationStore.getConfigurationFromStore().getCompanyPom(),
+ Model model = handler.getCompanyPomModel( appConfigurationStore.getConfiguration().getCompanyPom(),
createLocalRepository() );
if ( model != null )
<jndi prefix="java:comp/env" config-optional="true"/>
<xml fileName="${user.home}/.m2/archiva.xml" config-optional="true" config-name="org.apache.maven.archiva"
config-at="org.apache.maven.archiva" config-forceCreate="true"/>
- <xml fileName="${user.home}/.m2/shared.xml" config-optional="true"/>
+ <xml fileName="${user.home}/.m2/shared.xml" config-optional="true"
+ config-name="org.apache.maven.shared.app" config-at="org.apache.maven.shared.app"
+ config-forceCreate="true"/>
<properties fileName="${user.home}/.m2/security.properties" config-optional="true"
config-at="org.codehaus.plexus.security"/>
<properties fileName="${user.home}/.m2/archiva.properties" config-optional="true"
<xml fileName="${appserver.base}/conf/archiva.xml" config-optional="true"
config-at="org.apache.maven.archiva"/>
<xml fileName="${appserver.base}/conf/common.xml" config-optional="true"/>
+ <properties fileName="${appserver.base}/security.properties" config-optional="true"
+ config-at="org.codehaus.plexus.security"/>
<xml fileName="${appserver.home}/conf/archiva.xml" config-optional="true"
config-at="org.apache.maven.archiva"/>
<xml fileName="${appserver.home}/conf/common.xml" config-optional="true"/>
+ <properties fileName="${appserver.home}/security.properties" config-optional="true"
+ config-at="org.codehaus.plexus.security"/>
+ <properties fileName="org/apache/maven/archiva/security.properties" config-at="org.codehaus.plexus.security"/>
</properties>
</configuration>
</component>
<name>org.jpox.rdbms.dateTimezone</name>
<value>JDK_DEFAULT_TIMEZONE</value>
</property>
+<!--
+ <property>
+ <name>org.jpox.identifier.case</name>
+ <value>PreserveCase</value>
+ </property>
+-->
</otherProperties>
</configuration>
</component>
</components>
- <!-- Override default configuration of components -->
- <lifecycle-handler-manager implementation="org.codehaus.plexus.lifecycle.DefaultLifecycleHandlerManager">
- <default-lifecycle-handler-id>webapp</default-lifecycle-handler-id>
- <lifecycle-handlers>
- <lifecycle-handler implementation="org.codehaus.plexus.personality.plexus.PlexusLifecycleHandler">
- <id>webapp</id>
- <name>Web Application Component Lifecycle Handler</name>
- <begin-segment>
- <phase implementation="org.codehaus.plexus.personality.plexus.lifecycle.phase.LogEnablePhase"/>
- <phase implementation="org.codehaus.plexus.personality.plexus.lifecycle.phase.CompositionPhase"/>
- <phase implementation="org.codehaus.plexus.personality.plexus.lifecycle.phase.ContextualizePhase"/>
- <phase implementation="org.codehaus.plexus.xwork.ConfigurationPhase"/>
- <phase implementation="org.codehaus.plexus.personality.plexus.lifecycle.phase.ServiceablePhase"/>
- <phase implementation="org.codehaus.plexus.personality.plexus.lifecycle.phase.InitializePhase"/>
- <phase implementation="org.codehaus.plexus.personality.plexus.lifecycle.phase.StartPhase"/>
- </begin-segment>
- <suspend-segment>
- <phase implementation="org.codehaus.plexus.personality.plexus.lifecycle.phase.SuspendPhase"/>
- </suspend-segment>
- <resume-segment>
- <phase implementation="org.codehaus.plexus.personality.plexus.lifecycle.phase.ResumePhase"/>
- </resume-segment>
- <end-segment>
- <phase implementation="org.codehaus.plexus.personality.plexus.lifecycle.phase.StopPhase"/>
- <phase implementation="org.codehaus.plexus.personality.plexus.lifecycle.phase.DisposePhase"/>
- <phase implementation="org.codehaus.plexus.personality.plexus.lifecycle.phase.LogDisablePhase"/>
- </end-segment>
- </lifecycle-handler>
- </lifecycle-handlers>
- </lifecycle-handler-manager>
-
<load-on-start>
<component>
<role>org.apache.maven.archiva.scheduler.RepositoryTaskScheduler</role>
# under the License.
#
-# --------------------------------------------------------------------
-# Application Configuration
-
-application.name=Maven Archiva
-# NOTE: do not include trailing slash on application.url
-application.url=http://localhost
-application.timestamp=EEE d MMM yyyy HH:mm:ss Z
-
# --------------------------------------------------------------------
# Email Settings
-# All emails sent by the system will be from the following user name (used in conjunction with address)
-email.from.address=archiva@localhost
-email.from.name=Archiva Administrator
-
# The subject line for the email message.
email.validation.subject=Welcome to Maven Archiva
<interceptor name="pssSecureActions" class="pssSecureActionInterceptor"/>
<interceptor name="pssAutoLogin" class="pssAutoLoginInterceptor"/>
<interceptor name="pssEnvironmentChecker" class="pssEnvironmentCheckInterceptor"/>
+ <interceptor name="pssPolicyEnforcement" class="pssPolicyEnforcementInterceptor"/>
<interceptor-stack name="unconfiguredStack">
<interceptor-ref name="defaultStack"/>
<interceptor-ref name="pssEnvironmentChecker"/>
<interceptor-ref name="pssForceAdminUser"/>
<interceptor-ref name="pssAutoLogin"/>
+ <interceptor-ref name="pssPolicyEnforcement"/>
<interceptor-ref name="pssSecureActions"/>
</interceptor-stack>
<interceptor-ref name="pssEnvironmentChecker"/>
<interceptor-ref name="pssForceAdminUser"/>
<interceptor-ref name="pssAutoLogin"/>
+ <interceptor-ref name="pssPolicyEnforcement"/>
<interceptor-ref name="pssSecureActions"/>
<interceptor-ref name="configuration"/>
</interceptor-stack>
<param name="actionName">addadmin</param>
<param name="namespace">/security</param>
</result>
+ <result name="security-must-change-password" type="redirect-action">
+ <param name="actionName">password</param>
+ <param name="namespace">/security</param>
+ </result>
<!-- Generic Catchall for those action configurations that forget to
include a result for 'error' -->
</package>
- <package name="components" namespace="/components" extends="default">
+ <package name="components" namespace="/components" extends="webwork-default">
+ <default-interceptor-ref name="basicStack"/>
<action name="companyInfo" class="companyInfo">
<result>/WEB-INF/jsp/components/companyLogo.jsp</result>
</action>
<decorators defaultdir="/WEB-INF/jsp/decorators">
<excludes>
<pattern>/repository/*</pattern>
+ <pattern>/components/*</pattern>
</excludes>
-
+
<decorator name="default" page="default.jsp">
<pattern>/*</pattern>
</decorator>
</tr>
</table>
</c:if>
+</div>
</body>
</html>
<pss:ifAuthorized permission="archiva-manage-configuration">
<h5>Administration</h5>
<ul>
- <li class="expanded">
- <my:currentWWUrl action="index" namespace="/admin">Index</my:currentWWUrl>
+ <li class="none">
+ <my:currentWWUrl action="index" namespace="/admin">Settings</my:currentWWUrl>
</li>
<li class="none">
<my:currentWWUrl action="managedRepositories" namespace="/admin">Managed Repositories</my:currentWWUrl>
--- /dev/null
+#!/bin/sh
+
+CONTACTS="Andres Almiray <aalmiray@users.sourceforge.net>"
+MODE=rsync_ssh
+
+FROM=mavensync@shell.sourceforge.net:/home/groups/j/js/json-lib/htdocs/m2/repo/release
+GROUP_DIR=net/sf/json-lib/
\ No newline at end of file
</build>
</profile>
</profiles>
- <!-- TODO: remove once xwork integration, plexus container is released -->
+ <!-- TODO: remove once modello is released -->
+ <pluginRepositories>
+ <pluginRepository>
+ <id>codehaus.org</id>
+ <url>http://snapshots.repository.codehaus.org</url>
+ </pluginRepository>
+ </pluginRepositories>
+ <!-- TODO: remove once ehcache, p-sec, registry, webdav, xwork, naming released -->
<repositories>
<repository>
<id>codehaus.org</id>