diff options
author | Martin Schreier <martin_s@apache.org> | 2022-01-09 23:14:44 +0100 |
---|---|---|
committer | Martin Schreier <martin_s@apache.org> | 2022-01-09 23:14:44 +0100 |
commit | a0c5e5a0b0ad6502b0e3c82862bf57287c6a1c15 (patch) | |
tree | 36433dbf2a2147cf3dde4a1714b09268a309d678 | |
parent | 239669209d0ca6036ec3387b9f20cb8c3da6ff42 (diff) | |
download | archiva-a0c5e5a0b0ad6502b0e3c82862bf57287c6a1c15.tar.gz archiva-a0c5e5a0b0ad6502b0e3c82862bf57287c6a1c15.zip |
Splitting configuration module. Adding mapper interface.
252 files changed, 1380 insertions, 790 deletions
diff --git a/archiva-modules/archiva-base/archiva-common/src/main/java/org/apache/archiva/common/ModelMapper.java b/archiva-modules/archiva-base/archiva-common/src/main/java/org/apache/archiva/common/ModelMapper.java new file mode 100644 index 000000000..1f7fda93b --- /dev/null +++ b/archiva-modules/archiva-base/archiva-common/src/main/java/org/apache/archiva/common/ModelMapper.java @@ -0,0 +1,78 @@ +package org.apache.archiva.common; +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +/** + * Generic interface for mapping DTOs + * + * @author Martin Schreier <martin_s@apache.org> + */ +public interface ModelMapper<S,T> +{ + /** + * Converts the source instance to a new instance of the target type. + * @param source the source instance + * @return a new instance of the target type + */ + T map(S source); + + /** + * Updates the target instance based on the source instance + * @param source the source instance + * @param target the target instance + */ + void update( S source, T target ); + + + /** + * Converts the target instance back to the source type + * @param target the target instance + * @return a new instance of the source type + */ + S reverseMap(T target); + + /** + * Updates the source instance based on the target instance + * @param target the target instance + * @param source the source instance + */ + void reverseUpdate( T target, S source); + + /** + * Returns the class name of the source type + * @return the source type + */ + Class<S> getSourceType(); + + /** + * Returns the class name of the target type + * @return the target type + */ + Class<T> getTargetType(); + + /** + * Returns <code>true</code>, if the given type are the same or supertype of the mapping types. + * @param sourceType + * @param targetType + * @param <S> + * @param <T> + * @return + */ + <S, T> boolean supports( Class<S> sourceType, Class<T> targetType ); + +} diff --git a/archiva-modules/archiva-base/archiva-common/src/main/java/org/apache/archiva/common/ModelMapperFactory.java b/archiva-modules/archiva-base/archiva-common/src/main/java/org/apache/archiva/common/ModelMapperFactory.java new file mode 100644 index 000000000..30ee0c4c3 --- /dev/null +++ b/archiva-modules/archiva-base/archiva-common/src/main/java/org/apache/archiva/common/ModelMapperFactory.java @@ -0,0 +1,40 @@ +package org.apache.archiva.common; +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +/** + * Interface that returns a given DTO mapper. + * + * @author Martin Schreier <martin_s@apache.org> + * + * @param <SB> The base source type for the model mapper + * @param <TB> The base target type for the model mapper + */ +public interface ModelMapperFactory<SB,TB> +{ + /** + * Returns a mapper for the given source and target type. If no mapper is registered for this combination, + * it will throw a {@link IllegalArgumentException} + * @param sourceType the source type for the mapping + * @param targetType the destination type + * @param <S> source type + * @param <T> destination type + * @return the mapper instance + */ + <S extends SB, T extends TB> ModelMapper<S, T> getMapper( Class<S> sourceType, Class<T> targetType ) throws IllegalArgumentException; +} diff --git a/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/pom.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/pom.xml new file mode 100644 index 000000000..bd2591722 --- /dev/null +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/pom.xml @@ -0,0 +1,44 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<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/xsd/maven-4.0.0.xsd"> + <parent> + <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <version>3.0.0-SNAPSHOT</version> + </parent> + <modelVersion>4.0.0</modelVersion> + + <artifactId>archiva-configuration-model</artifactId> + <name>Archiva Base :: Configuration :: Model</name> + + <dependencies> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-collections4</artifactId> + </dependency> + </dependencies> + +</project>
\ No newline at end of file diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/AbstractRepositoryConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/AbstractRepositoryConfiguration.java index 695f0c0c2..36c1f4e6e 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/AbstractRepositoryConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/AbstractRepositoryConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/AbstractRepositoryConnectorConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/AbstractRepositoryConnectorConfiguration.java index 5a7bc587e..aed4995db 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/AbstractRepositoryConnectorConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/AbstractRepositoryConnectorConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ArchivaDefaultConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ArchivaDefaultConfiguration.java index 3917cc8f0..c7a613b8f 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ArchivaDefaultConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ArchivaDefaultConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ArchivaRuntimeConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ArchivaRuntimeConfiguration.java index b05686092..85f20bf11 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ArchivaRuntimeConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ArchivaRuntimeConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/CacheConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/CacheConfiguration.java index 5d765edde..d14a8865a 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/CacheConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/CacheConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/Configuration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/Configuration.java index 1bd3bcef2..890986839 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/Configuration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/Configuration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,6 +18,7 @@ package org.apache.archiva.configuration; * under the License. */ + /** * Class Configuration. * @@ -769,7 +769,7 @@ public class Configuration connectors.add( proxyConfig ); java.util.Collections.sort( connectors, - org.apache.archiva.configuration.functors.ProxyConnectorConfigurationOrderComparator.getInstance() ); + org.apache.archiva.configuration.model.functors.ProxyConnectorConfigurationOrderComparator.getInstance() ); } } diff --git a/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ConfigurationModel.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ConfigurationModel.java new file mode 100644 index 000000000..6a9520aa7 --- /dev/null +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ConfigurationModel.java @@ -0,0 +1,25 @@ +package org.apache.archiva.configuration.model; +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +/** + * @author Martin Schreier <martin_s@apache.org> + */ +public interface ConfigurationModel +{ +} diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ConfigurationNames.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ConfigurationNames.java index aaa0a5df9..8a1a03fbd 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ConfigurationNames.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ConfigurationNames.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/FileLockConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/FileLockConfiguration.java index 259e3b85a..acac6d7a3 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/FileLockConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/FileLockConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/FileType.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/FileType.java index d3930c1c1..7f0ec575d 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/FileType.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/FileType.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/LdapConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/LdapConfiguration.java index 5541c7310..abed037ba 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/LdapConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/LdapConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/LdapGroupMapping.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/LdapGroupMapping.java index 05288c148..c899d4032 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/LdapGroupMapping.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/LdapGroupMapping.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/LegacyArtifactPath.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/LegacyArtifactPath.java index 695245fdc..6c7013395 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/LegacyArtifactPath.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/LegacyArtifactPath.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ManagedRepositoryConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ManagedRepositoryConfiguration.java index a8da04d6d..64c84b9f3 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ManagedRepositoryConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ManagedRepositoryConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -27,7 +26,7 @@ package org.apache.archiva.configuration; @SuppressWarnings( "all" ) public class ManagedRepositoryConfiguration extends AbstractRepositoryConfiguration - implements java.io.Serializable + implements java.io.Serializable, ConfigurationModel { //--------------------------/ diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/NetworkConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/NetworkConfiguration.java index a7eacec7e..dd1b2de16 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/NetworkConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/NetworkConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/NetworkProxyConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/NetworkProxyConfiguration.java index 234ef8a75..e18fe059f 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/NetworkProxyConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/NetworkProxyConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/OrganisationInformation.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/OrganisationInformation.java index a7f7fb62f..5e892ae20 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/OrganisationInformation.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/OrganisationInformation.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ProxyConnectorConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ProxyConnectorConfiguration.java index 944c8b670..637808a07 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ProxyConnectorConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ProxyConnectorConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ProxyConnectorRuleConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ProxyConnectorRuleConfiguration.java index 3340e0563..f555d9a45 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ProxyConnectorRuleConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/ProxyConnectorRuleConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/RedbackRuntimeConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/RedbackRuntimeConfiguration.java index 2c8992926..10a4d7f8c 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/RedbackRuntimeConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/RedbackRuntimeConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/RemoteRepositoryConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/RemoteRepositoryConfiguration.java index ca49d315c..37ff862c8 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/RemoteRepositoryConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/RemoteRepositoryConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -27,7 +26,7 @@ package org.apache.archiva.configuration; @SuppressWarnings( "all" ) public class RemoteRepositoryConfiguration extends AbstractRepositoryConfiguration - implements java.io.Serializable + implements java.io.Serializable, ConfigurationModel { //--------------------------/ diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/RepositoryCheckPath.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/RepositoryCheckPath.java index 27f766052..6fcdd0c34 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/RepositoryCheckPath.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/RepositoryCheckPath.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/RepositoryGroupConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/RepositoryGroupConfiguration.java index 877ccaadc..904a931e0 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/RepositoryGroupConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/RepositoryGroupConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -30,7 +29,7 @@ import java.util.List; */ @SuppressWarnings( "all" ) public class RepositoryGroupConfiguration extends AbstractRepositoryConfiguration - implements Serializable + implements Serializable, ConfigurationModel { //--------------------------/ diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/RepositoryScanningConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/RepositoryScanningConfiguration.java index 976eb345a..02b4d0acd 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/RepositoryScanningConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/RepositoryScanningConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/SyncConnectorConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/SyncConnectorConfiguration.java index a4f8ff901..f92bcbf94 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/SyncConnectorConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/SyncConnectorConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/UserInterfaceOptions.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/UserInterfaceOptions.java index 8d8476646..df740e7b0 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/UserInterfaceOptions.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/UserInterfaceOptions.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/WebappConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/WebappConfiguration.java index aab3660c6..372cf0085 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/WebappConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/WebappConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.model; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/functors/FiletypeSelectionPredicate.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/functors/FiletypeSelectionPredicate.java index 2573a5dc7..7bb422ca5 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/functors/FiletypeSelectionPredicate.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/functors/FiletypeSelectionPredicate.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration.functors; +package org.apache.archiva.configuration.model.functors; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration.functors; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,7 +18,7 @@ package org.apache.archiva.configuration.functors; * under the License. */ -import org.apache.archiva.configuration.FileType; +import org.apache.archiva.configuration.model.FileType; import org.apache.commons.collections4.Predicate; import org.apache.commons.lang3.StringUtils; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/functors/FiletypeToMapClosure.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/functors/FiletypeToMapClosure.java index ad8ef5c97..5b2f13219 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/functors/FiletypeToMapClosure.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/functors/FiletypeToMapClosure.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration.functors; +package org.apache.archiva.configuration.model.functors; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration.functors; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,7 +18,7 @@ package org.apache.archiva.configuration.functors; * under the License. */ -import org.apache.archiva.configuration.FileType; +import org.apache.archiva.configuration.model.FileType; import org.apache.commons.collections4.Closure; import java.util.HashMap; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/functors/NetworkProxyComparator.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/functors/NetworkProxyComparator.java index d71e32316..ae8f96b77 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/functors/NetworkProxyComparator.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/functors/NetworkProxyComparator.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration.functors; +package org.apache.archiva.configuration.model.functors; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration.functors; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,7 +18,7 @@ package org.apache.archiva.configuration.functors; * under the License. */ -import org.apache.archiva.configuration.NetworkProxyConfiguration; +import org.apache.archiva.configuration.model.NetworkProxyConfiguration; import java.util.Comparator; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/functors/NetworkProxySelectionPredicate.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/functors/NetworkProxySelectionPredicate.java index c76cfa221..b3534f2e1 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/functors/NetworkProxySelectionPredicate.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/functors/NetworkProxySelectionPredicate.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration.functors; +package org.apache.archiva.configuration.model.functors; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration.functors; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,7 +18,7 @@ package org.apache.archiva.configuration.functors; * under the License. */ -import org.apache.archiva.configuration.NetworkProxyConfiguration; +import org.apache.archiva.configuration.model.NetworkProxyConfiguration; import org.apache.commons.collections4.Predicate; import org.apache.commons.lang3.StringUtils; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/functors/ProxyConnectorConfigurationOrderComparator.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/functors/ProxyConnectorConfigurationOrderComparator.java index 05cad4baf..28d246026 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/functors/ProxyConnectorConfigurationOrderComparator.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/functors/ProxyConnectorConfigurationOrderComparator.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration.functors; +package org.apache.archiva.configuration.model.functors; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration.functors; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,7 +18,7 @@ package org.apache.archiva.configuration.functors; * under the License. */ -import org.apache.archiva.configuration.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; import java.util.Comparator; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/functors/ProxyConnectorSelectionPredicate.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/functors/ProxyConnectorSelectionPredicate.java index 2b5641f47..99a723fd6 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/functors/ProxyConnectorSelectionPredicate.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/functors/ProxyConnectorSelectionPredicate.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration.functors; +package org.apache.archiva.configuration.model.functors; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration.functors; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,7 +18,7 @@ package org.apache.archiva.configuration.functors; * under the License. */ -import org.apache.archiva.configuration.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; import org.apache.commons.collections4.Predicate; import org.apache.commons.lang3.StringUtils; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/functors/RepositoryConfigurationComparator.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/functors/RepositoryConfigurationComparator.java index 9e2b64e22..0af59d767 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/functors/RepositoryConfigurationComparator.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-model/src/main/java/org/apache/archiva/configuration/model/functors/RepositoryConfigurationComparator.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration.functors; +package org.apache.archiva.configuration.model.functors; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration.functors; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,7 +18,7 @@ package org.apache.archiva.configuration.functors; * under the License. */ -import org.apache.archiva.configuration.AbstractRepositoryConfiguration; +import org.apache.archiva.configuration.model.AbstractRepositoryConfiguration; import java.util.Comparator; diff --git a/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/pom.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/pom.xml new file mode 100644 index 000000000..5404763e4 --- /dev/null +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/pom.xml @@ -0,0 +1,176 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<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/xsd/maven-4.0.0.xsd"> + <parent> + <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <version>3.0.0-SNAPSHOT</version> + </parent> + <modelVersion>4.0.0</modelVersion> + + <artifactId>archiva-configuration-provider</artifactId> + <name>Archiva Base :: Configuration :: Provider</name> + + + <dependencies> + <dependency> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-model</artifactId> + </dependency> + + <dependency> + <groupId>org.apache.archiva</groupId> + <artifactId>archiva-common</artifactId> + </dependency> + <dependency> + <groupId>org.apache.archiva</groupId> + <artifactId>archiva-policies</artifactId> + </dependency> + <dependency> + <groupId>org.apache.archiva.components.registry</groupId> + <artifactId>archiva-components-spring-registry-api</artifactId> + <exclusions> + <exclusion> + <groupId>org.springframework</groupId> + <artifactId>spring-test</artifactId> + </exclusion> + </exclusions> + </dependency> + <dependency> + <groupId>org.springframework</groupId> + <artifactId>spring-context</artifactId> + <exclusions> + <exclusion> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + </exclusion> + </exclusions> + </dependency> + <dependency> + <groupId>org.apache.archiva.components.registry</groupId> + <artifactId>archiva-components-spring-registry-commons</artifactId> + <exclusions> + <exclusion> + <groupId>org.springframework</groupId> + <artifactId>spring-test</artifactId> + </exclusion> + </exclusions> + </dependency> + <dependency> + <groupId>org.apache.archiva.components</groupId> + <artifactId>archiva-components-expression-evaluator</artifactId> + </dependency> + + <dependency> + <groupId>jakarta.annotation</groupId> + <artifactId>jakarta.annotation-api</artifactId> + </dependency> + <dependency> + <groupId>jakarta.inject</groupId> + <artifactId>jakarta.inject-api</artifactId> + </dependency> + + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-configuration2</artifactId> + <scope>runtime</scope> + <exclusions> + <exclusion> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + </exclusion> + </exclusions> + </dependency> + + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-collections4</artifactId> + </dependency> + + + <!-- Test scope --> + + <dependency> + <groupId>org.apache.archiva</groupId> + <artifactId>archiva-test-utils</artifactId> + <version>${project.version}</version> + <scope>test</scope> + </dependency> + + <dependency> + <groupId>org.springframework</groupId> + <artifactId>spring-test</artifactId> + <scope>test</scope> + </dependency> + <dependency> + <groupId>org.apache.logging.log4j</groupId> + <artifactId>log4j-jcl</artifactId> + <scope>test</scope> + </dependency> + + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <scope>test</scope> + </dependency> + + </dependencies> + <build> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-surefire-plugin</artifactId> + <configuration> + <systemPropertyVariables> + <basedir>${basedir}</basedir> + </systemPropertyVariables> + <trimStackTrace>false</trimStackTrace> + </configuration> + </plugin> + </plugins> + <pluginManagement> + <plugins> + <plugin> + <groupId>org.apache.rat</groupId> + <artifactId>apache-rat-plugin</artifactId> + <configuration> + <excludes> + <exclude>src/main/resources/org/apache/archiva/configuration/default-archiva.xml</exclude> + <exclude>src/test/conf/maven-proxy-complete.conf</exclude> + <exclude>src/test/resources/org/apache/archiva/configuration/test-default-archiva.xml</exclude> + <exclude>nbactions.xml</exclude> + </excludes> + </configuration> + </plugin> + </plugins> + </pluginManagement> + </build> + +</project>
\ No newline at end of file diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ArchivaConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/ArchivaConfiguration.java index cf90a13d3..b71d26bb9 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ArchivaConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/ArchivaConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -22,6 +21,7 @@ package org.apache.archiva.configuration; import org.apache.archiva.components.registry.Registry; import org.apache.archiva.components.registry.RegistryException; import org.apache.archiva.components.registry.RegistryListener; +import org.apache.archiva.configuration.model.Configuration; import java.nio.file.Path; import java.util.List; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ConfigurationEvent.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/ConfigurationEvent.java index 9639effbe..5ad758c8b 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ConfigurationEvent.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/ConfigurationEvent.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ConfigurationListener.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/ConfigurationListener.java index 2abeb6371..370c61cec 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ConfigurationListener.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/ConfigurationListener.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ConfigurationRuntimeException.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/ConfigurationRuntimeException.java index 2368d201e..abf2b7038 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/ConfigurationRuntimeException.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/ConfigurationRuntimeException.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/DefaultArchivaConfiguration.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/DefaultArchivaConfiguration.java index b9db3042e..88efcf90a 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/DefaultArchivaConfiguration.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/DefaultArchivaConfiguration.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,12 +18,6 @@ package org.apache.archiva.configuration; * under the License. */ -import org.apache.archiva.configuration.functors.ProxyConnectorConfigurationOrderComparator; -import org.apache.archiva.configuration.io.registry.ConfigurationRegistryReader; -import org.apache.archiva.configuration.io.registry.ConfigurationRegistryWriter; -import org.apache.archiva.policies.AbstractUpdatePolicy; -import org.apache.archiva.policies.CachedFailuresPolicy; -import org.apache.archiva.policies.ChecksumPolicy; import org.apache.archiva.components.evaluator.DefaultExpressionEvaluator; import org.apache.archiva.components.evaluator.EvaluatorException; import org.apache.archiva.components.evaluator.ExpressionEvaluator; @@ -33,6 +26,17 @@ import org.apache.archiva.components.registry.Registry; import org.apache.archiva.components.registry.RegistryException; import org.apache.archiva.components.registry.RegistryListener; import org.apache.archiva.components.registry.commons.CommonsConfigurationRegistry; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryCheckPath; +import org.apache.archiva.configuration.model.functors.ProxyConnectorConfigurationOrderComparator; +import org.apache.archiva.configuration.provider.io.registry.ConfigurationRegistryReader; +import org.apache.archiva.configuration.provider.io.registry.ConfigurationRegistryWriter; +import org.apache.archiva.policies.AbstractUpdatePolicy; +import org.apache.archiva.policies.CachedFailuresPolicy; +import org.apache.archiva.policies.ChecksumPolicy; import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.collections4.ListUtils; import org.apache.commons.io.FileUtils; @@ -49,8 +53,18 @@ import java.nio.file.Files; import java.nio.file.InvalidPathException; import java.nio.file.Path; import java.nio.file.Paths; -import java.util.*; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; +import java.util.Collections; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Iterator; +import java.util.List; +import java.util.Locale; +import java.util.Map; import java.util.Map.Entry; +import java.util.Set; /** * <p> @@ -508,7 +522,7 @@ public class DefaultArchivaConfiguration } private void escapeCronExpressions(Configuration configuration) { - for (ManagedRepositoryConfiguration c : configuration.getManagedRepositories()) { + for ( ManagedRepositoryConfiguration c : configuration.getManagedRepositories()) { c.setRefreshCronExpression(escapeCronExpression(c.getRefreshCronExpression())); } } diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/FileTypes.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/FileTypes.java index 2415f7119..a08e4bf14 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/FileTypes.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/FileTypes.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -20,9 +19,12 @@ package org.apache.archiva.configuration; */ import org.apache.archiva.common.FileTypeUtils; -import org.apache.archiva.configuration.functors.FiletypeSelectionPredicate; import org.apache.archiva.components.registry.Registry; import org.apache.archiva.components.registry.RegistryListener; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.FileType; +import org.apache.archiva.configuration.model.RepositoryScanningConfiguration; +import org.apache.archiva.configuration.model.functors.FiletypeSelectionPredicate; import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.collections4.IterableUtils; import org.apache.commons.collections4.Predicate; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/IndeterminateConfigurationException.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/IndeterminateConfigurationException.java index 04160fab4..39054ced6 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/IndeterminateConfigurationException.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/IndeterminateConfigurationException.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/InvalidConfigurationException.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/InvalidConfigurationException.java index 55f5b3408..f65aa7d1b 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/InvalidConfigurationException.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/InvalidConfigurationException.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/MavenProxyPropertyLoader.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/MavenProxyPropertyLoader.java index 20e3f34cf..7f657f92f 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/MavenProxyPropertyLoader.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/MavenProxyPropertyLoader.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,6 +18,11 @@ package org.apache.archiva.configuration; * under the License. */ +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.NetworkProxyConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; import org.apache.archiva.policies.ReleasesPolicy; import org.apache.archiva.policies.SnapshotsPolicy; import org.apache.commons.lang3.StringUtils; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/io/registry/ConfigurationRegistryReader.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/io/registry/ConfigurationRegistryReader.java index 27146f5e6..6a89e1cf7 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/io/registry/ConfigurationRegistryReader.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/io/registry/ConfigurationRegistryReader.java @@ -1,5 +1,5 @@ -package org.apache.archiva.configuration.io.registry; +package org.apache.archiva.configuration.provider.io.registry; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -10,8 +10,7 @@ package org.apache.archiva.configuration.io.registry; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -20,8 +19,32 @@ package org.apache.archiva.configuration.io.registry; * under the License. */ -import org.apache.archiva.configuration.*; import org.apache.archiva.components.registry.Registry; +import org.apache.archiva.configuration.model.AbstractRepositoryConfiguration; +import org.apache.archiva.configuration.model.AbstractRepositoryConnectorConfiguration; +import org.apache.archiva.configuration.model.ArchivaDefaultConfiguration; +import org.apache.archiva.configuration.model.ArchivaRuntimeConfiguration; +import org.apache.archiva.configuration.model.CacheConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.FileLockConfiguration; +import org.apache.archiva.configuration.model.FileType; +import org.apache.archiva.configuration.model.LdapConfiguration; +import org.apache.archiva.configuration.model.LdapGroupMapping; +import org.apache.archiva.configuration.model.LegacyArtifactPath; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.NetworkConfiguration; +import org.apache.archiva.configuration.model.NetworkProxyConfiguration; +import org.apache.archiva.configuration.model.OrganisationInformation; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorRuleConfiguration; +import org.apache.archiva.configuration.model.RedbackRuntimeConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryCheckPath; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.RepositoryScanningConfiguration; +import org.apache.archiva.configuration.model.SyncConnectorConfiguration; +import org.apache.archiva.configuration.model.UserInterfaceOptions; +import org.apache.archiva.configuration.model.WebappConfiguration; import java.util.Iterator; import java.util.List; @@ -34,7 +57,7 @@ import java.util.List; * Generate Redback Registry input mechanism for model 'Configuration'. */ public class ConfigurationRegistryReader { - public Configuration read(Registry registry) { + public Configuration read( Registry registry) { return readConfiguration("", registry); } @@ -140,7 +163,7 @@ public class ConfigurationRegistryReader { return value; } - private AbstractRepositoryConfiguration readAbstractRepositoryConfiguration(String prefix, Registry registry) { + private AbstractRepositoryConfiguration readAbstractRepositoryConfiguration( String prefix, Registry registry) { AbstractRepositoryConfiguration value = new AbstractRepositoryConfiguration(); //String id = registry.getString( prefix + "id", value.getId() ); @@ -776,7 +799,7 @@ public class ConfigurationRegistryReader { return value; } - private RepositoryCheckPath readRepositoryCheckPath(String prefix, Registry registry) { + private RepositoryCheckPath readRepositoryCheckPath( String prefix, Registry registry) { RepositoryCheckPath value = new RepositoryCheckPath(); //String url = registry.getString( prefix + "url", value.getUrl() ); @@ -815,7 +838,7 @@ public class ConfigurationRegistryReader { return value; } - private AbstractRepositoryConnectorConfiguration readAbstractRepositoryConnectorConfiguration(String prefix, Registry registry) { + private AbstractRepositoryConnectorConfiguration readAbstractRepositoryConnectorConfiguration( String prefix, Registry registry) { AbstractRepositoryConnectorConfiguration value = new AbstractRepositoryConnectorConfiguration(); //String sourceRepoId = registry.getString( prefix + "sourceRepoId", value.getSourceRepoId() ); @@ -997,7 +1020,7 @@ public class ConfigurationRegistryReader { return value; } - private SyncConnectorConfiguration readSyncConnectorConfiguration(String prefix, Registry registry) { + private SyncConnectorConfiguration readSyncConnectorConfiguration( String prefix, Registry registry) { SyncConnectorConfiguration value = new SyncConnectorConfiguration(); //String cronExpression = registry.getString( prefix + "cronExpression", value.getCronExpression() ); diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/io/registry/ConfigurationRegistryWriter.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/io/registry/ConfigurationRegistryWriter.java index 83202f531..253eae897 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/io/registry/ConfigurationRegistryWriter.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/io/registry/ConfigurationRegistryWriter.java @@ -1,5 +1,5 @@ -package org.apache.archiva.configuration.io.registry; +package org.apache.archiva.configuration.provider.io.registry; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -10,8 +10,7 @@ package org.apache.archiva.configuration.io.registry; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -20,8 +19,32 @@ package org.apache.archiva.configuration.io.registry; * under the License. */ -import org.apache.archiva.configuration.*; import org.apache.archiva.components.registry.Registry; +import org.apache.archiva.configuration.model.AbstractRepositoryConfiguration; +import org.apache.archiva.configuration.model.AbstractRepositoryConnectorConfiguration; +import org.apache.archiva.configuration.model.ArchivaDefaultConfiguration; +import org.apache.archiva.configuration.model.ArchivaRuntimeConfiguration; +import org.apache.archiva.configuration.model.CacheConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.FileLockConfiguration; +import org.apache.archiva.configuration.model.FileType; +import org.apache.archiva.configuration.model.LdapConfiguration; +import org.apache.archiva.configuration.model.LdapGroupMapping; +import org.apache.archiva.configuration.model.LegacyArtifactPath; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.NetworkConfiguration; +import org.apache.archiva.configuration.model.NetworkProxyConfiguration; +import org.apache.archiva.configuration.model.OrganisationInformation; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorRuleConfiguration; +import org.apache.archiva.configuration.model.RedbackRuntimeConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryCheckPath; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.RepositoryScanningConfiguration; +import org.apache.archiva.configuration.model.SyncConnectorConfiguration; +import org.apache.archiva.configuration.model.UserInterfaceOptions; +import org.apache.archiva.configuration.model.WebappConfiguration; import java.util.Iterator; import java.util.List; @@ -34,7 +57,7 @@ import java.util.List; * Generate Plexus Registry output mechanism for model 'Configuration'. */ public class ConfigurationRegistryWriter { - public void write(Configuration model, Registry registry) { + public void write( Configuration model, Registry registry) { writeConfiguration("", model, registry); } @@ -172,7 +195,7 @@ public class ConfigurationRegistryWriter { } } - private void writeAbstractRepositoryConfiguration(String prefix, AbstractRepositoryConfiguration value, Registry registry) { + private void writeAbstractRepositoryConfiguration( String prefix, AbstractRepositoryConfiguration value, Registry registry) { if (value != null) { if (value.getId() != null ) { @@ -457,7 +480,7 @@ public class ConfigurationRegistryWriter { } } - private void writeRepositoryCheckPath(String prefix, RepositoryCheckPath value, Registry registry) { + private void writeRepositoryCheckPath( String prefix, RepositoryCheckPath value, Registry registry) { if (value != null) { if (value.getUrl() != null ) { @@ -472,7 +495,7 @@ public class ConfigurationRegistryWriter { } } - private void writeAbstractRepositoryConnectorConfiguration(String prefix, AbstractRepositoryConnectorConfiguration value, Registry registry) { + private void writeAbstractRepositoryConnectorConfiguration( String prefix, AbstractRepositoryConnectorConfiguration value, Registry registry) { if (value != null) { if (value.getSourceRepoId() != null ) { @@ -635,7 +658,7 @@ public class ConfigurationRegistryWriter { } } - private void writeSyncConnectorConfiguration(String prefix, SyncConnectorConfiguration value, Registry registry) { + private void writeSyncConnectorConfiguration( String prefix, SyncConnectorConfiguration value, Registry registry) { if (value != null) { if (value.getCronExpression() != null && !value.getCronExpression().equals("0 0 * * * ?") ) { @@ -748,7 +771,7 @@ public class ConfigurationRegistryWriter { } } - private void writeRepositoryScanningConfiguration(String prefix, RepositoryScanningConfiguration value, Registry registry) { + private void writeRepositoryScanningConfiguration( String prefix, RepositoryScanningConfiguration value, Registry registry) { if (value != null) { if (value.getFileTypes() != null && value.getFileTypes().size() > 0 ) { @@ -807,7 +830,7 @@ public class ConfigurationRegistryWriter { } } - private void writeOrganisationInformation(String prefix, OrganisationInformation value, Registry registry) { + private void writeOrganisationInformation( String prefix, OrganisationInformation value, Registry registry) { if (value != null) { if (value.getName() != null ) { @@ -827,7 +850,7 @@ public class ConfigurationRegistryWriter { } } - private void writeWebappConfiguration(String prefix, WebappConfiguration value, Registry registry) { + private void writeWebappConfiguration( String prefix, WebappConfiguration value, Registry registry) { if (value != null) { if (value.getUi() != null ) { @@ -836,7 +859,7 @@ public class ConfigurationRegistryWriter { } } - private void writeUserInterfaceOptions(String prefix, UserInterfaceOptions value, Registry registry) { + private void writeUserInterfaceOptions( String prefix, UserInterfaceOptions value, Registry registry) { if (value != null) { String showFindArtifacts = "showFindArtifacts"; registry.setBoolean(prefix + showFindArtifacts, value.isShowFindArtifacts()); @@ -854,7 +877,7 @@ public class ConfigurationRegistryWriter { } } - private void writeNetworkConfiguration(String prefix, NetworkConfiguration value, Registry registry) { + private void writeNetworkConfiguration( String prefix, NetworkConfiguration value, Registry registry) { if (value != null) { if (value.getMaxTotal() != 30 ) { @@ -871,7 +894,7 @@ public class ConfigurationRegistryWriter { } } - private void writeArchivaRuntimeConfiguration(String prefix, ArchivaRuntimeConfiguration value, Registry registry) { + private void writeArchivaRuntimeConfiguration( String prefix, ArchivaRuntimeConfiguration value, Registry registry) { if (value != null) { if (value.getUrlFailureCacheConfiguration() != null ) { @@ -916,7 +939,7 @@ public class ConfigurationRegistryWriter { } } - private void writeRedbackRuntimeConfiguration(String prefix, RedbackRuntimeConfiguration value, Registry registry) { + private void writeRedbackRuntimeConfiguration( String prefix, RedbackRuntimeConfiguration value, Registry registry) { if (value != null) { String migratedFromRedbackConfiguration = "migratedFromRedbackConfiguration"; registry.setBoolean(prefix + migratedFromRedbackConfiguration, value.isMigratedFromRedbackConfiguration()); @@ -977,7 +1000,7 @@ public class ConfigurationRegistryWriter { } } - private void writeArchivaDefaultConfiguration(String prefix, ArchivaDefaultConfiguration value, Registry registry) { + private void writeArchivaDefaultConfiguration( String prefix, ArchivaDefaultConfiguration value, Registry registry) { if (value != null) { if (value.getDefaultCheckPaths() != null && value.getDefaultCheckPaths().size() > 0 ) { @@ -993,7 +1016,7 @@ public class ConfigurationRegistryWriter { } } - private void writeLdapConfiguration(String prefix, LdapConfiguration value, Registry registry) { + private void writeLdapConfiguration( String prefix, LdapConfiguration value, Registry registry) { if (value != null) { if (value.getHostName() != null ) { @@ -1057,7 +1080,7 @@ public class ConfigurationRegistryWriter { } } - private void writeFileLockConfiguration(String prefix, FileLockConfiguration value, Registry registry) { + private void writeFileLockConfiguration( String prefix, FileLockConfiguration value, Registry registry) { if (value != null) { String skipLocking = "skipLocking"; registry.setBoolean(prefix + skipLocking, value.isSkipLocking()); @@ -1069,7 +1092,7 @@ public class ConfigurationRegistryWriter { } } - private void writeCacheConfiguration(String prefix, CacheConfiguration value, Registry registry) { + private void writeCacheConfiguration( String prefix, CacheConfiguration value, Registry registry) { if (value != null) { if (value.getTimeToIdleSeconds() != -1 ) { diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/util/ConfigMapper.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/util/ConfigMapper.java index f55dbbc66..d03137a95 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/java/org/apache/archiva/configuration/util/ConfigMapper.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/java/org/apache/archiva/configuration/provider/util/ConfigMapper.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration.util; +package org.apache.archiva.configuration.provider.util; /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/resources/META-INF/spring-context.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/resources/META-INF/spring-context.xml index 3fe1e381d..3fe1e381d 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/resources/META-INF/spring-context.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/resources/META-INF/spring-context.xml diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/resources/org/apache/archiva/configuration/default-archiva.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/resources/org/apache/archiva/configuration/default-archiva.xml index 5f3731dab..5f3731dab 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/resources/org/apache/archiva/configuration/default-archiva.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/main/resources/org/apache/archiva/configuration/default-archiva.xml diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/archiva-0.9.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/archiva-0.9.xml index c8032436a..c8032436a 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/archiva-0.9.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/archiva-0.9.xml diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/archiva-1.3.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/archiva-1.3.xml index 8575ebd12..8575ebd12 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/archiva-1.3.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/archiva-1.3.xml diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/archiva-v1.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/archiva-v1.xml index 2b05c9251..2b05c9251 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/archiva-v1.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/archiva-v1.xml diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/autodetect-v1.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/autodetect-v1.xml index 29f3775bb..29f3775bb 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/autodetect-v1.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/autodetect-v1.xml diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/conf-base.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/conf-base.xml index 84ab085d0..84ab085d0 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/conf-base.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/conf-base.xml diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/conf-single-list-elements.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/conf-single-list-elements.xml index 3e3d4dc97..3e3d4dc97 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/conf-single-list-elements.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/conf-single-list-elements.xml diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/conf-user.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/conf-user.xml index 61c4dadc2..61c4dadc2 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/conf-user.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/conf-user.xml diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/corrupt.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/corrupt.xml index b4469289a..b4469289a 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/corrupt.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/corrupt.xml diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/escape-cron-expressions.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/escape-cron-expressions.xml index 547e8c0b5..547e8c0b5 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/escape-cron-expressions.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/escape-cron-expressions.xml diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/maven-proxy-complete.conf b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/maven-proxy-complete.conf index dd98bba12..dd98bba12 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/maven-proxy-complete.conf +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/maven-proxy-complete.conf diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/repository-manager.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/repository-manager.xml index 8fabacf5b..8fabacf5b 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/conf/repository-manager.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/conf/repository-manager.xml diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/ArchivaConfigurationMRM789Test.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/ArchivaConfigurationMRM789Test.java index d7b4c6f0c..606749692 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/ArchivaConfigurationMRM789Test.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/ArchivaConfigurationMRM789Test.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,6 +18,11 @@ package org.apache.archiva.configuration; * under the License. */ +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryScanningConfiguration; +import org.apache.archiva.configuration.model.UserInterfaceOptions; +import org.apache.archiva.configuration.model.WebappConfiguration; import org.apache.archiva.test.utils.ArchivaSpringJUnit4ClassRunner; import org.apache.commons.io.FileUtils; import org.apache.commons.lang3.StringUtils; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/ArchivaConfigurationTest.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/ArchivaConfigurationTest.java index 9a882d3e2..ae2079b19 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/ArchivaConfigurationTest.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/ArchivaConfigurationTest.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -20,12 +19,21 @@ package org.apache.archiva.configuration; */ import org.apache.archiva.components.registry.RegistryException; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.LegacyArtifactPath; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.NetworkProxyConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.RepositoryScanningConfiguration; +import org.apache.archiva.configuration.model.UserInterfaceOptions; +import org.apache.archiva.configuration.model.WebappConfiguration; import org.apache.archiva.test.utils.ArchivaSpringJUnit4ClassRunner; import org.apache.commons.io.FileUtils; import org.apache.commons.lang3.StringUtils; import org.junit.Test; import org.junit.runner.RunWith; -import org.mockito.Mockito; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.context.ApplicationContext; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/ConfigurationTest.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/ConfigurationTest.java index 2a5e9b447..599bf92e5 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/ConfigurationTest.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/ConfigurationTest.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,6 +18,10 @@ package org.apache.archiva.configuration; * under the License. */ +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.NetworkProxyConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; import org.apache.archiva.test.utils.ArchivaBlockJUnit4ClassRunner; import org.junit.Test; import org.junit.runner.RunWith; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/FileTypesTest.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/FileTypesTest.java index 83874b7a0..38921e3e2 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/FileTypesTest.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/FileTypesTest.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/LegacyArtifactPathTest.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/LegacyArtifactPathTest.java index c36a93b71..38e7dfb60 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/LegacyArtifactPathTest.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/LegacyArtifactPathTest.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,6 +18,7 @@ package org.apache.archiva.configuration; * under the License. */ +import org.apache.archiva.configuration.model.LegacyArtifactPath; import org.apache.archiva.test.utils.ArchivaBlockJUnit4ClassRunner; import org.junit.Test; import org.junit.runner.RunWith; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/MavenProxyPropertyLoaderTest.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/MavenProxyPropertyLoaderTest.java index dfc41e949..892cf322e 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/MavenProxyPropertyLoaderTest.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/MavenProxyPropertyLoaderTest.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration; +package org.apache.archiva.configuration.provider; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,6 +18,10 @@ package org.apache.archiva.configuration; * under the License. */ +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.NetworkProxyConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; import org.apache.archiva.test.utils.ArchivaBlockJUnit4ClassRunner; import org.junit.Before; import org.junit.Test; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/functors/ProxyConnectorConfigurationOrderComparatorTest.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/functors/ProxyConnectorConfigurationOrderComparatorTest.java index 458014f12..b5873f52b 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/functors/ProxyConnectorConfigurationOrderComparatorTest.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/functors/ProxyConnectorConfigurationOrderComparatorTest.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration.functors; +package org.apache.archiva.configuration.provider.functors; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration.functors; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,7 +18,8 @@ package org.apache.archiva.configuration.functors; * under the License. */ -import org.apache.archiva.configuration.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.functors.ProxyConnectorConfigurationOrderComparator; import org.apache.archiva.test.utils.ArchivaBlockJUnit4ClassRunner; import org.apache.commons.lang3.StringUtils; import org.junit.Test; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/functors/RepositoryConfigurationComparatorTest.java b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/functors/RepositoryConfigurationComparatorTest.java index 2dd659c86..0423351ac 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/java/org/apache/archiva/configuration/functors/RepositoryConfigurationComparatorTest.java +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/java/org/apache/archiva/configuration/provider/functors/RepositoryConfigurationComparatorTest.java @@ -1,4 +1,4 @@ -package org.apache.archiva.configuration.functors; +package org.apache.archiva.configuration.provider.functors; /* * Licensed to the Apache Software Foundation (ASF) under one @@ -9,8 +9,7 @@ package org.apache.archiva.configuration.functors; * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 - * + * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY @@ -19,8 +18,9 @@ package org.apache.archiva.configuration.functors; * under the License. */ -import org.apache.archiva.configuration.AbstractRepositoryConfiguration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.AbstractRepositoryConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.functors.RepositoryConfigurationComparator; import org.apache.archiva.test.utils.ArchivaBlockJUnit4ClassRunner; import org.junit.Test; import org.junit.runner.RunWith; diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/resources/log4j2-test.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/resources/log4j2-test.xml index 03547df43..03547df43 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/resources/log4j2-test.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/resources/log4j2-test.xml diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/resources/org/apache/archiva/configuration/test-default-archiva.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/resources/org/apache/archiva/configuration/test-default-archiva.xml index dc1215e69..dc1215e69 100755 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/resources/org/apache/archiva/configuration/test-default-archiva.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/resources/org/apache/archiva/configuration/test-default-archiva.xml diff --git a/archiva-modules/archiva-base/archiva-configuration/src/test/resources/spring-context.xml b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/resources/spring-context.xml index 4eb7b5be6..4f63c9839 100755 --- a/archiva-modules/archiva-base/archiva-configuration/src/test/resources/spring-context.xml +++ b/archiva-modules/archiva-base/archiva-configuration/archiva-configuration-provider/src/test/resources/spring-context.xml @@ -29,17 +29,17 @@ <context:property-placeholder system-properties-mode="OVERRIDE"/> - <bean name="archivaConfiguration#test-defaults-default-repo-location-exists" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-defaults-default-repo-location-exists" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#empty"/> </bean> <bean name="registry#empty" class="org.apache.archiva.components.registry.commons.CommonsConfigurationRegistry"/> - <bean name="archivaConfiguration#test-defaults" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-defaults" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#emptydef"/> </bean> <bean name="registry#emptydef" class="org.apache.archiva.components.registry.commons.CommonsConfigurationRegistry"/> - <bean name="archivaConfiguration#test-upgrade-09" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-upgrade-09" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-upgrade-09"/> </bean> @@ -58,7 +58,7 @@ </property> </bean> - <bean name="archivaConfiguration#test-upgrade-1.3" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-upgrade-1.3" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-upgrade-1.3"/> </bean> @@ -75,7 +75,7 @@ </property> </bean> - <bean name="archivaConfiguration#test-configuration" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-configuration" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#configured"/> </bean> @@ -94,7 +94,7 @@ </bean> - <bean name="archivaConfiguration#test-autodetect-v1" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-autodetect-v1" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-autodetect-v1"/> </bean> @@ -113,7 +113,7 @@ </property> </bean> - <bean name="archivaConfiguration#test-archiva-v1" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-archiva-v1" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-archiva-v1"/> </bean> @@ -131,7 +131,7 @@ </property> </bean> - <bean name="archivaConfiguration#test-save" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-save" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-save"/> </bean> @@ -148,7 +148,7 @@ </property> </bean> - <bean name="archivaConfiguration#test-save-user-defaults" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-save-user-defaults" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-save-user-defaults"/> </bean> @@ -167,7 +167,7 @@ </property> </bean> - <bean name="archivaConfiguration#test-save-user-fallback" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-save-user-fallback" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-save-user-fallback"/> </bean> @@ -186,7 +186,7 @@ </property> </bean> - <bean name="archivaConfiguration#test-save-user" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-save-user" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-save-user"/> </bean> @@ -206,7 +206,7 @@ </bean> - <bean name="archivaConfiguration#test-configuration-both" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-configuration-both" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-configuration-both"/> </bean> @@ -226,7 +226,7 @@ </bean> - <bean name="archivaConfiguration#test-read-saved" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-read-saved" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-read-saved"/> </bean> @@ -244,7 +244,7 @@ </bean> - <bean name="archivaConfiguration#test-cron-expressions" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-cron-expressions" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-cron-expressions"/> <property name="userConfigFilename" value="${basedir}/target/test/test-file.xml"/> </bean> @@ -263,7 +263,7 @@ </bean> - <bean name="archivaConfiguration#test-remove-central" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-remove-central" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-remove-central"/> </bean> @@ -281,7 +281,7 @@ </bean> - <bean name="archivaConfiguration#test-not-allowed-to-write-to-both" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-not-allowed-to-write-to-both" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-not-allowed-to-write-to-both"/> <property name="userConfigFilename" value="/../../..//target/*intentionally:invalid*/.m2/archiva-user.xml"/> <property name="altConfigFilename" value="/../../..//target/*intentionally:invalid*/conf/archiva.xml"/> @@ -302,7 +302,7 @@ </property> </bean> - <bean name="archivaConfiguration#test-not-allowed-to-write-to-user" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-not-allowed-to-write-to-user" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-not-allowed-to-write-to-user"/> <property name="userConfigFilename" value="${basedir}/target/*intentionally:invalid*/.m2/archiva-user.xml"/> <property name="altConfigFilename" value="${basedir}/target/test-appserver-base/conf/archiva.xml"/> diff --git a/archiva-modules/archiva-base/archiva-configuration/pom.xml b/archiva-modules/archiva-base/archiva-configuration/pom.xml index 485245199..aff864c2f 100644 --- a/archiva-modules/archiva-base/archiva-configuration/pom.xml +++ b/archiva-modules/archiva-base/archiva-configuration/pom.xml @@ -25,147 +25,21 @@ <version>3.0.0-SNAPSHOT</version> </parent> <modelVersion>4.0.0</modelVersion> + <groupId>org.apache.archiva.configuration</groupId> <artifactId>archiva-configuration</artifactId> <name>Archiva Base :: Configuration</name> + <version>3.0.0-SNAPSHOT</version> + <packaging>pom</packaging> <properties> <site.staging.base>${project.parent.parent.basedir}</site.staging.base> </properties> + <modules> + <module>archiva-configuration-model</module> + <module>archiva-configuration-provider</module> + </modules> <dependencies> - <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-common</artifactId> - </dependency> - <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-policies</artifactId> - </dependency> - <dependency> - <groupId>org.apache.archiva.components.registry</groupId> - <artifactId>archiva-components-spring-registry-api</artifactId> - <exclusions> - <exclusion> - <groupId>org.springframework</groupId> - <artifactId>spring-test</artifactId> - </exclusion> - </exclusions> - </dependency> - <dependency> - <groupId>org.springframework</groupId> - <artifactId>spring-context</artifactId> - <exclusions> - <exclusion> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - </exclusion> - </exclusions> - </dependency> - <dependency> - <groupId>org.apache.archiva.components.registry</groupId> - <artifactId>archiva-components-spring-registry-commons</artifactId> - <exclusions> - <exclusion> - <groupId>org.springframework</groupId> - <artifactId>spring-test</artifactId> - </exclusion> - </exclusions> - </dependency> - <dependency> - <groupId>org.apache.archiva.components</groupId> - <artifactId>archiva-components-expression-evaluator</artifactId> - </dependency> - - <dependency> - <groupId>jakarta.annotation</groupId> - <artifactId>jakarta.annotation-api</artifactId> - </dependency> - <dependency> - <groupId>jakarta.inject</groupId> - <artifactId>jakarta.inject-api</artifactId> - </dependency> - - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-configuration2</artifactId> - <scope>runtime</scope> - <exclusions> - <exclusion> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - </exclusion> - </exclusions> - </dependency> - - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-lang3</artifactId> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-collections4</artifactId> - </dependency> - - - <!-- Test scope --> - - <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-test-utils</artifactId> - <version>${project.version}</version> - <scope>test</scope> - </dependency> - - <dependency> - <groupId>org.springframework</groupId> - <artifactId>spring-test</artifactId> - <scope>test</scope> - </dependency> - <dependency> - <groupId>org.apache.logging.log4j</groupId> - <artifactId>log4j-jcl</artifactId> - <scope>test</scope> - </dependency> - - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <scope>test</scope> - </dependency> </dependencies> - <build> - <plugins> - <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-surefire-plugin</artifactId> - <configuration> - <systemPropertyVariables> - <basedir>${basedir}</basedir> - </systemPropertyVariables> - <trimStackTrace>false</trimStackTrace> - </configuration> - </plugin> - </plugins> - <pluginManagement> - <plugins> - <plugin> - <groupId>org.apache.rat</groupId> - <artifactId>apache-rat-plugin</artifactId> - <configuration> - <excludes> - <exclude>src/main/resources/org/apache/archiva/configuration/default-archiva.xml</exclude> - <exclude>src/test/conf/maven-proxy-complete.conf</exclude> - <exclude>src/test/resources/org/apache/archiva/configuration/test-default-archiva.xml</exclude> - <exclude>nbactions.xml</exclude> - </excludes> - </configuration> - </plugin> - </plugins> - </pluginManagement> - </build> </project> diff --git a/archiva-modules/archiva-base/archiva-configuration/src/main/mdo/configuration.mdo b/archiva-modules/archiva-base/archiva-configuration/src/main/mdo/configuration.mdo index 746f2c472..b8c5a7104 100644 --- a/archiva-modules/archiva-base/archiva-configuration/src/main/mdo/configuration.mdo +++ b/archiva-modules/archiva-base/archiva-configuration/src/main/mdo/configuration.mdo @@ -336,7 +336,7 @@ connectors.add( proxyConfig ); java.util.Collections.sort( connectors, - org.apache.archiva.configuration.functors.ProxyConnectorConfigurationOrderComparator.getInstance() ); + org.apache.archiva.configuration.provider.functors.ProxyConnectorConfigurationOrderComparator.getInstance() ); } } diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/pom.xml b/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/pom.xml index a86d0a1fe..42844565e 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/pom.xml +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/pom.xml @@ -82,8 +82,8 @@ <scope>test</scope> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> <scope>test</scope> </dependency> <dependency> diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/src/main/resources/archetype-resources/src/main/java/SimpleArtifactConsumer.java b/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/src/main/resources/archetype-resources/src/main/java/SimpleArtifactConsumer.java index e9f0cc036..c6dab3538 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/src/main/resources/archetype-resources/src/main/java/SimpleArtifactConsumer.java +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/src/main/resources/archetype-resources/src/main/java/SimpleArtifactConsumer.java @@ -21,8 +21,8 @@ package $package; import org.apache.archiva.components.registry.Registry; import org.apache.archiva.components.registry.RegistryListener; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.consumers.AbstractMonitoredConsumer; import org.apache.archiva.consumers.ConsumerException; import org.apache.archiva.consumers.KnownRepositoryContentConsumer; diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/src/main/resources/archetype-resources/src/test/java/RepositoryProviderMock.java b/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/src/main/resources/archetype-resources/src/test/java/RepositoryProviderMock.java index 10f9f2d45..a77d0ebc4 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/src/main/resources/archetype-resources/src/test/java/RepositoryProviderMock.java +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/src/main/resources/archetype-resources/src/test/java/RepositoryProviderMock.java @@ -19,9 +19,9 @@ package $package; * under the License. */ -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.event.EventHandler; import org.apache.archiva.repository.base.managed.BasicManagedRepository; import org.apache.archiva.repository.base.remote.BasicRemoteRepository; diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/src/main/resourcesstatic/archetype-resources/pom.xml b/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/src/main/resourcesstatic/archetype-resources/pom.xml index 81a77435a..ac5f5ba2c 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/src/main/resourcesstatic/archetype-resources/pom.xml +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-consumer-archetype/src/main/resourcesstatic/archetype-resources/pom.xml @@ -52,8 +52,8 @@ <version>${archiva.version}</version> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> <version>${archiva.version}</version> </dependency> <dependency> diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/pom.xml b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/pom.xml index 3502aa3ee..abad21899 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/pom.xml +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/pom.xml @@ -34,8 +34,8 @@ <dependencies> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/ArtifactMissingChecksumsConsumer.java b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/ArtifactMissingChecksumsConsumer.java index 559de35e0..cbb7a2ac4 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/ArtifactMissingChecksumsConsumer.java +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/ArtifactMissingChecksumsConsumer.java @@ -20,8 +20,8 @@ package org.apache.archiva.consumers.core; */ import org.apache.archiva.checksum.*; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.consumers.AbstractMonitoredConsumer; import org.apache.archiva.consumers.ConsumerException; import org.apache.archiva.consumers.KnownRepositoryContentConsumer; diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/AutoRemoveConsumer.java b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/AutoRemoveConsumer.java index 89b014a7b..ffa022e40 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/AutoRemoveConsumer.java +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/AutoRemoveConsumer.java @@ -19,9 +19,9 @@ package org.apache.archiva.consumers.core; * under the License. */ -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ConfigurationNames; -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.ConfigurationNames; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.consumers.AbstractMonitoredConsumer; import org.apache.archiva.consumers.ConsumerException; import org.apache.archiva.consumers.KnownRepositoryContentConsumer; diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/MetadataUpdaterConsumer.java b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/MetadataUpdaterConsumer.java index 5c7985491..4410c5477 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/MetadataUpdaterConsumer.java +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/MetadataUpdaterConsumer.java @@ -19,7 +19,7 @@ package org.apache.archiva.consumers.core; * under the License. */ -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.consumers.AbstractMonitoredConsumer; import org.apache.archiva.consumers.ConsumerException; import org.apache.archiva.consumers.KnownRepositoryContentConsumer; diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/repository/RepositoryPurgeConsumer.java b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/repository/RepositoryPurgeConsumer.java index 24779a77e..86bf774bf 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/repository/RepositoryPurgeConsumer.java +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/main/java/org/apache/archiva/consumers/core/repository/RepositoryPurgeConsumer.java @@ -19,9 +19,9 @@ package org.apache.archiva.consumers.core.repository; * under the License. */ -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ConfigurationNames; -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.ConfigurationNames; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.consumers.AbstractMonitoredConsumer; import org.apache.archiva.consumers.ConsumerException; import org.apache.archiva.consumers.KnownRepositoryContentConsumer; diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/AbstractArtifactConsumerTest.java b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/AbstractArtifactConsumerTest.java index 8a50d78a4..721f270a4 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/AbstractArtifactConsumerTest.java +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/AbstractArtifactConsumerTest.java @@ -20,9 +20,9 @@ package org.apache.archiva.consumers.core; */ import org.apache.archiva.common.utils.BaseFile; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.FileType; -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.FileType; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.consumers.KnownRepositoryContentConsumer; import org.apache.archiva.consumers.functors.ConsumerWantsFilePredicate; import org.apache.archiva.repository.RepositoryRegistry; diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/mock/repository/RepositoryProviderMock.java b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/mock/repository/RepositoryProviderMock.java index a74ae2461..3cb612339 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/mock/repository/RepositoryProviderMock.java +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/mock/repository/RepositoryProviderMock.java @@ -18,9 +18,9 @@ package org.apache.archiva.consumers.core.mock.repository; * under the License. */ -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.event.EventHandler; import org.apache.archiva.repository.base.managed.BasicManagedRepository; import org.apache.archiva.repository.base.remote.BasicRemoteRepository; diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/repository/CleanupReleasedSnapshotsRepositoryPurgeTest.java b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/repository/CleanupReleasedSnapshotsRepositoryPurgeTest.java index 2a60d710c..c3273cf6f 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/repository/CleanupReleasedSnapshotsRepositoryPurgeTest.java +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/repository/CleanupReleasedSnapshotsRepositoryPurgeTest.java @@ -21,7 +21,7 @@ package org.apache.archiva.consumers.core.repository; import org.apache.archiva.admin.model.managed.ManagedRepositoryAdmin; import org.apache.archiva.admin.repository.managed.DefaultManagedRepositoryAdmin; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.metadata.model.ArtifactMetadata; import org.apache.archiva.metadata.model.MetadataFacet; import org.apache.archiva.repository.base.ArchivaRepositoryRegistry; diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/repository/RepositoryPurgeConsumerTest.java b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/repository/RepositoryPurgeConsumerTest.java index 209d050d3..ba5568ad3 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/repository/RepositoryPurgeConsumerTest.java +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/java/org/apache/archiva/consumers/core/repository/RepositoryPurgeConsumerTest.java @@ -20,9 +20,9 @@ package org.apache.archiva.consumers.core.repository; */ import org.apache.archiva.common.utils.BaseFile; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.FileType; -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.FileType; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.consumers.KnownRepositoryContentConsumer; import org.apache.archiva.consumers.functors.ConsumerWantsFilePredicate; import org.apache.archiva.metadata.model.ArtifactMetadata; diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/resources/spring-context-cleanup-released-snapshots.xml b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/resources/spring-context-cleanup-released-snapshots.xml index 95c203340..32eb6357d 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/resources/spring-context-cleanup-released-snapshots.xml +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/resources/spring-context-cleanup-released-snapshots.xml @@ -27,7 +27,7 @@ http://www.springframework.org/schema/context/spring-context-3.0.xsd http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx.xsd" default-lazy-init="true"> - <bean name="archivaConfiguration#cleanup-released-snapshots" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#cleanup-released-snapshots" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#cleanup-released-snapshots"/> </bean> <alias name="archivaConfiguration#cleanup-released-snapshots" alias="archivaConfiguration"/> diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/resources/spring-context-purge-consumer-test.xml b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/resources/spring-context-purge-consumer-test.xml index 0657f9551..4b970df9c 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/resources/spring-context-purge-consumer-test.xml +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-core-consumers/src/test/resources/spring-context-purge-consumer-test.xml @@ -38,7 +38,7 @@ <property name="filetypes" ref="filetypes#retention-count"/> </bean> - <bean name="archivaConfiguration#retention-count" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#retention-count" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#retention-count"/> </bean> @@ -62,7 +62,7 @@ </property> </bean> - <bean name="filetypes#retention-count" class="org.apache.archiva.configuration.FileTypes"> + <bean name="filetypes#retention-count" class="org.apache.archiva.configuration.provider.FileTypes"> <property name="archivaConfiguration" ref="archivaConfiguration#retention-count"/> </bean> @@ -75,7 +75,7 @@ <property name="filetypes" ref="filetypes#days-old"/> </bean> - <bean name="archivaConfiguration#days-old" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#days-old" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#days-old"/> </bean> @@ -96,7 +96,7 @@ </property> </bean> - <bean name="filetypes#days-old" class="org.apache.archiva.configuration.FileTypes"> + <bean name="filetypes#days-old" class="org.apache.archiva.configuration.provider.FileTypes"> <property name="archivaConfiguration" ref="archivaConfiguration#days-old"/> </bean> diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-indexer-consumers/pom.xml b/archiva-modules/archiva-base/archiva-consumers/archiva-indexer-consumers/pom.xml index 84c501651..261ddf871 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-indexer-consumers/pom.xml +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-indexer-consumers/pom.xml @@ -34,8 +34,8 @@ <dependencies> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-indexer-consumers/src/main/java/org/apache/archiva/consumers/lucene/NexusIndexerConsumer.java b/archiva-modules/archiva-base/archiva-consumers/archiva-indexer-consumers/src/main/java/org/apache/archiva/consumers/lucene/NexusIndexerConsumer.java index e03557ebf..e4673205e 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-indexer-consumers/src/main/java/org/apache/archiva/consumers/lucene/NexusIndexerConsumer.java +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-indexer-consumers/src/main/java/org/apache/archiva/consumers/lucene/NexusIndexerConsumer.java @@ -20,9 +20,9 @@ package org.apache.archiva.consumers.lucene; */ import org.apache.archiva.common.utils.PathUtil; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ConfigurationNames; -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.ConfigurationNames; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.consumers.AbstractMonitoredConsumer; import org.apache.archiva.consumers.ConsumerException; import org.apache.archiva.consumers.KnownRepositoryContentConsumer; diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-indexer-consumers/src/test/java/org/apache/archiva/consumers/lucene/NexusIndexerConsumerTest.java b/archiva-modules/archiva-base/archiva-consumers/archiva-indexer-consumers/src/test/java/org/apache/archiva/consumers/lucene/NexusIndexerConsumerTest.java index cf2768584..d5bcb077f 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-indexer-consumers/src/test/java/org/apache/archiva/consumers/lucene/NexusIndexerConsumerTest.java +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-indexer-consumers/src/test/java/org/apache/archiva/consumers/lucene/NexusIndexerConsumerTest.java @@ -22,8 +22,8 @@ package org.apache.archiva.consumers.lucene; import junit.framework.TestCase; import org.apache.archiva.common.utils.PathUtil; import org.apache.archiva.components.taskqueue.TaskQueueException; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.repository.ReleaseScheme; import org.apache.archiva.repository.base.ArchivaRepositoryRegistry; import org.apache.archiva.repository.base.RepositoryHandlerDependencies; diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-metadata-consumer/pom.xml b/archiva-modules/archiva-base/archiva-consumers/archiva-metadata-consumer/pom.xml index f23955a1c..3c552e672 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-metadata-consumer/pom.xml +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-metadata-consumer/pom.xml @@ -38,8 +38,8 @@ <artifactId>archiva-consumer-api</artifactId> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/archiva-base/archiva-consumers/archiva-metadata-consumer/src/main/java/org/apache/archiva/consumers/metadata/ArchivaMetadataCreationConsumer.java b/archiva-modules/archiva-base/archiva-consumers/archiva-metadata-consumer/src/main/java/org/apache/archiva/consumers/metadata/ArchivaMetadataCreationConsumer.java index f694d5af4..9234108fc 100644 --- a/archiva-modules/archiva-base/archiva-consumers/archiva-metadata-consumer/src/main/java/org/apache/archiva/consumers/metadata/ArchivaMetadataCreationConsumer.java +++ b/archiva-modules/archiva-base/archiva-consumers/archiva-metadata-consumer/src/main/java/org/apache/archiva/consumers/metadata/ArchivaMetadataCreationConsumer.java @@ -20,9 +20,9 @@ package org.apache.archiva.consumers.metadata; */ import org.apache.archiva.common.utils.VersionUtil; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ConfigurationNames; -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.ConfigurationNames; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.consumers.AbstractMonitoredConsumer; import org.apache.archiva.consumers.ConsumerException; import org.apache.archiva.consumers.KnownRepositoryContentConsumer; diff --git a/archiva-modules/archiva-base/archiva-proxy/pom.xml b/archiva-modules/archiva-base/archiva-proxy/pom.xml index 2a63d5041..dc3c7da0d 100644 --- a/archiva-modules/archiva-base/archiva-proxy/pom.xml +++ b/archiva-modules/archiva-base/archiva-proxy/pom.xml @@ -34,8 +34,8 @@ <dependencies> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/archiva-base/archiva-proxy/src/main/java/org/apache/archiva/proxy/base/ArchivaProxyRegistry.java b/archiva-modules/archiva-base/archiva-proxy/src/main/java/org/apache/archiva/proxy/base/ArchivaProxyRegistry.java index a86cb3701..02a2c1bf2 100644 --- a/archiva-modules/archiva-base/archiva-proxy/src/main/java/org/apache/archiva/proxy/base/ArchivaProxyRegistry.java +++ b/archiva-modules/archiva-base/archiva-proxy/src/main/java/org/apache/archiva/proxy/base/ArchivaProxyRegistry.java @@ -18,9 +18,9 @@ package org.apache.archiva.proxy.base; * under the License. */ -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.NetworkProxyConfiguration; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.NetworkProxyConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; import org.apache.archiva.policies.Policy; import org.apache.archiva.policies.PolicyOption; import org.apache.archiva.policies.PolicyUtil; diff --git a/archiva-modules/archiva-base/archiva-proxy/src/main/java/org/apache/archiva/proxy/base/DefaultRepositoryProxyHandler.java b/archiva-modules/archiva-base/archiva-proxy/src/main/java/org/apache/archiva/proxy/base/DefaultRepositoryProxyHandler.java index 44c6c92b0..f0bfe6baa 100644 --- a/archiva-modules/archiva-base/archiva-proxy/src/main/java/org/apache/archiva/proxy/base/DefaultRepositoryProxyHandler.java +++ b/archiva-modules/archiva-base/archiva-proxy/src/main/java/org/apache/archiva/proxy/base/DefaultRepositoryProxyHandler.java @@ -23,9 +23,9 @@ import org.apache.archiva.checksum.ChecksumUtil; import org.apache.archiva.common.filelock.FileLockManager; import org.apache.archiva.common.utils.PathUtil; import org.apache.archiva.components.taskqueue.TaskQueueException; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; -import org.apache.archiva.configuration.ProxyConnectorRuleConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorRuleConfiguration; import org.apache.archiva.policies.DownloadErrorPolicy; import org.apache.archiva.policies.DownloadPolicy; import org.apache.archiva.policies.Policy; diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/pom.xml b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/pom.xml index 341d2a3c3..8c231f2c1 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/pom.xml +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/pom.xml @@ -34,8 +34,8 @@ <dependencies> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/AbstractRepositoryAdmin.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/AbstractRepositoryAdmin.java index f1c947572..d2cbb499a 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/AbstractRepositoryAdmin.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/AbstractRepositoryAdmin.java @@ -22,10 +22,10 @@ import org.apache.archiva.admin.model.AuditInformation; import org.apache.archiva.admin.model.RepositoryAdminException; import org.apache.archiva.admin.model.RepositoryCommonValidator; import org.apache.archiva.admin.model.beans.AbstractRepository; -import org.apache.archiva.configuration.AbstractRepositoryConfiguration; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.IndeterminateConfigurationException; +import org.apache.archiva.configuration.model.AbstractRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.provider.IndeterminateConfigurationException; import org.apache.archiva.metadata.model.facets.AuditEvent; import org.apache.archiva.components.registry.Registry; import org.apache.archiva.redback.users.User; diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/DefaultRepositoryCommonValidator.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/DefaultRepositoryCommonValidator.java index 7375942fe..df739e7a8 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/DefaultRepositoryCommonValidator.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/DefaultRepositoryCommonValidator.java @@ -23,8 +23,8 @@ import org.apache.archiva.admin.model.RepositoryCommonValidator; import org.apache.archiva.admin.model.beans.AbstractRepository; import org.apache.archiva.admin.model.beans.ManagedRepository; import org.apache.archiva.admin.model.managed.ManagedRepositoryAdmin; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; import org.apache.archiva.components.registry.Registry; import org.apache.archiva.components.scheduler.CronExpressionValidator; import org.apache.commons.lang3.StringUtils; diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/admin/DefaultArchivaAdministration.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/admin/DefaultArchivaAdministration.java index dec2caa86..8db4ebe72 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/admin/DefaultArchivaAdministration.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/admin/DefaultArchivaAdministration.java @@ -23,9 +23,9 @@ import org.apache.archiva.admin.model.RepositoryAdminException; import org.apache.archiva.admin.model.admin.ArchivaAdministration; import org.apache.archiva.admin.model.beans.*; import org.apache.archiva.admin.repository.AbstractRepositoryAdmin; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.UserInterfaceOptions; -import org.apache.archiva.configuration.WebappConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.UserInterfaceOptions; +import org.apache.archiva.configuration.model.WebappConfiguration; import org.apache.archiva.metadata.model.facets.AuditEvent; import org.apache.commons.lang3.StringEscapeUtils; import org.apache.commons.lang3.StringUtils; @@ -54,7 +54,7 @@ public class DefaultArchivaAdministration { List<LegacyArtifactPath> legacyArtifactPaths = new ArrayList<>( getArchivaConfiguration().getConfiguration().getLegacyArtifactPaths().size() ); - for ( org.apache.archiva.configuration.LegacyArtifactPath legacyArtifactPath : getArchivaConfiguration().getConfiguration().getLegacyArtifactPaths() ) + for ( org.apache.archiva.configuration.model.LegacyArtifactPath legacyArtifactPath : getArchivaConfiguration().getConfiguration().getLegacyArtifactPaths() ) { legacyArtifactPaths.add( getModelMapper().map( legacyArtifactPath, LegacyArtifactPath.class ) ); @@ -69,7 +69,7 @@ public class DefaultArchivaAdministration Configuration configuration = getArchivaConfiguration().getConfiguration(); configuration.addLegacyArtifactPath( getModelMapper().map( legacyArtifactPath, - org.apache.archiva.configuration.LegacyArtifactPath.class ) ); + org.apache.archiva.configuration.model.LegacyArtifactPath.class ) ); saveConfiguration( configuration ); triggerAuditEvent( "", "", AuditEvent.ADD_LEGACY_PATH, auditInformation ); @@ -80,8 +80,8 @@ public class DefaultArchivaAdministration throws RepositoryAdminException { Configuration configuration = getArchivaConfiguration().getConfiguration(); - org.apache.archiva.configuration.LegacyArtifactPath legacyArtifactPath = - new org.apache.archiva.configuration.LegacyArtifactPath(); + org.apache.archiva.configuration.model.LegacyArtifactPath legacyArtifactPath = + new org.apache.archiva.configuration.model.LegacyArtifactPath(); legacyArtifactPath.setPath( path ); configuration.removeLegacyArtifactPath( legacyArtifactPath ); @@ -97,7 +97,7 @@ public class DefaultArchivaAdministration { Configuration configuration = getArchivaConfiguration().getConfiguration(); - org.apache.archiva.configuration.FileType fileType = getFileTypeById( fileTypeId, configuration ); + org.apache.archiva.configuration.model.FileType fileType = getFileTypeById( fileTypeId, configuration ); if ( fileType == null ) { return; @@ -120,7 +120,7 @@ public class DefaultArchivaAdministration { Configuration configuration = getArchivaConfiguration().getConfiguration(); - org.apache.archiva.configuration.FileType fileType = getFileTypeById( fileTypeId, configuration ); + org.apache.archiva.configuration.model.FileType fileType = getFileTypeById( fileTypeId, configuration ); if ( fileType == null ) { return; @@ -135,7 +135,7 @@ public class DefaultArchivaAdministration public FileType getFileType( String fileTypeId ) throws RepositoryAdminException { - org.apache.archiva.configuration.FileType fileType = + org.apache.archiva.configuration.model.FileType fileType = getFileTypeById( fileTypeId, getArchivaConfiguration().getConfiguration() ); if ( fileType == null ) { @@ -156,7 +156,7 @@ public class DefaultArchivaAdministration } configuration.getRepositoryScanning().addFileType( - getModelMapper().map( fileType, org.apache.archiva.configuration.FileType.class ) ); + getModelMapper().map( fileType, org.apache.archiva.configuration.model.FileType.class ) ); saveConfiguration( configuration ); } @@ -165,7 +165,7 @@ public class DefaultArchivaAdministration throws RepositoryAdminException { Configuration configuration = getArchivaConfiguration().getConfiguration(); - org.apache.archiva.configuration.FileType fileType = new org.apache.archiva.configuration.FileType(); + org.apache.archiva.configuration.model.FileType fileType = new org.apache.archiva.configuration.model.FileType(); fileType.setId( fileTypeId ); configuration.getRepositoryScanning().removeFileType( fileType ); saveConfiguration( configuration ); @@ -253,14 +253,14 @@ public class DefaultArchivaAdministration public List<FileType> getFileTypes() throws RepositoryAdminException { - List<org.apache.archiva.configuration.FileType> configFileTypes = + List<org.apache.archiva.configuration.model.FileType> configFileTypes = getArchivaConfiguration().getConfiguration().getRepositoryScanning().getFileTypes(); if ( configFileTypes == null || configFileTypes.isEmpty() ) { return Collections.emptyList(); } List<FileType> fileTypes = new ArrayList<>( configFileTypes.size() ); - for ( org.apache.archiva.configuration.FileType fileType : configFileTypes ) + for ( org.apache.archiva.configuration.model.FileType fileType : configFileTypes ) { fileTypes.add( getModelMapper().map( fileType, FileType.class ) ); } @@ -287,7 +287,7 @@ public class DefaultArchivaAdministration public OrganisationInformation getOrganisationInformation() throws RepositoryAdminException { - org.apache.archiva.configuration.OrganisationInformation organisationInformation = + org.apache.archiva.configuration.model.OrganisationInformation organisationInformation = getArchivaConfiguration().getConfiguration().getOrganisationInfo(); if ( organisationInformation == null ) { @@ -329,9 +329,9 @@ public class DefaultArchivaAdministration if ( organisationInformation != null ) { organisationInformation.setName( convertName( organisationInformation.getName() )); - org.apache.archiva.configuration.OrganisationInformation organisationInformationModel = + org.apache.archiva.configuration.model.OrganisationInformation organisationInformationModel = getModelMapper( ).map( organisationInformation, - org.apache.archiva.configuration.OrganisationInformation.class ); + org.apache.archiva.configuration.model.OrganisationInformation.class ); configuration.setOrganisationInfo( organisationInformationModel ); } else @@ -382,7 +382,7 @@ public class DefaultArchivaAdministration public NetworkConfiguration getNetworkConfiguration() throws RepositoryAdminException { - org.apache.archiva.configuration.NetworkConfiguration networkConfiguration = + org.apache.archiva.configuration.model.NetworkConfiguration networkConfiguration = getArchivaConfiguration().getConfiguration().getNetworkConfiguration(); if ( networkConfiguration == null ) @@ -404,7 +404,7 @@ public class DefaultArchivaAdministration else { configuration.setNetworkConfiguration( getModelMapper().map( networkConfiguration, - org.apache.archiva.configuration.NetworkConfiguration.class ) ); + org.apache.archiva.configuration.model.NetworkConfiguration.class ) ); } // setupWagon( networkConfiguration ); saveConfiguration( configuration ); @@ -415,9 +415,9 @@ public class DefaultArchivaAdministration // //------------------------- - private org.apache.archiva.configuration.FileType getFileTypeById( String id, Configuration configuration ) + private org.apache.archiva.configuration.model.FileType getFileTypeById( String id, Configuration configuration ) { - for ( org.apache.archiva.configuration.FileType fileType : configuration.getRepositoryScanning().getFileTypes() ) + for ( org.apache.archiva.configuration.model.FileType fileType : configuration.getRepositoryScanning().getFileTypes() ) { if ( StringUtils.equals( id, fileType.getId() ) ) { diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/group/DefaultRepositoryGroupAdmin.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/group/DefaultRepositoryGroupAdmin.java index a6276a844..f30c849a6 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/group/DefaultRepositoryGroupAdmin.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/group/DefaultRepositoryGroupAdmin.java @@ -27,13 +27,12 @@ import org.apache.archiva.admin.model.beans.RepositoryGroup; import org.apache.archiva.admin.model.group.RepositoryGroupAdmin; import org.apache.archiva.admin.model.managed.ManagedRepositoryAdmin; import org.apache.archiva.admin.repository.AbstractRepositoryAdmin; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.event.Event; import org.apache.archiva.event.EventHandler; import org.apache.archiva.event.EventType; import org.apache.archiva.metadata.model.facets.AuditEvent; -import org.apache.archiva.indexer.merger.MergedRemoteIndexesScheduler; import org.apache.archiva.repository.EditableRepositoryGroup; import org.apache.archiva.repository.RepositoryException; import org.apache.archiva.repository.RepositoryRegistry; @@ -47,11 +46,6 @@ import org.springframework.stereotype.Service; import javax.annotation.PostConstruct; import javax.inject.Inject; -import javax.inject.Named; -import java.io.IOException; -import java.nio.file.Files; -import java.nio.file.Path; -import java.nio.file.Paths; import java.util.ArrayList; import java.util.HashMap; import java.util.List; diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/managed/DefaultManagedRepositoryAdmin.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/managed/DefaultManagedRepositoryAdmin.java index 7a8a98291..5b6dae25b 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/managed/DefaultManagedRepositoryAdmin.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/managed/DefaultManagedRepositoryAdmin.java @@ -25,9 +25,9 @@ import org.apache.archiva.admin.model.managed.ManagedRepositoryAdmin; import org.apache.archiva.admin.repository.AbstractRepositoryAdmin; import org.apache.archiva.components.cache.Cache; import org.apache.archiva.components.taskqueue.TaskQueueException; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; import org.apache.archiva.indexer.ArchivaIndexManager; import org.apache.archiva.indexer.IndexManagerFactory; import org.apache.archiva.indexer.IndexUpdateFailedException; @@ -63,7 +63,6 @@ import java.io.IOException; import java.nio.file.Path; import java.nio.file.Paths; import java.util.ArrayList; -import java.util.Collection; import java.util.List; import java.util.Map; import java.util.stream.Collectors; diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/networkproxy/DefaultNetworkProxyAdmin.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/networkproxy/DefaultNetworkProxyAdmin.java index b6ccc73ff..7fd43ec3c 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/networkproxy/DefaultNetworkProxyAdmin.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/networkproxy/DefaultNetworkProxyAdmin.java @@ -23,8 +23,8 @@ import org.apache.archiva.admin.model.RepositoryAdminException; import org.apache.archiva.admin.model.beans.NetworkProxy; import org.apache.archiva.admin.model.networkproxy.NetworkProxyAdmin; import org.apache.archiva.admin.repository.AbstractRepositoryAdmin; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.NetworkProxyConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.NetworkProxyConfiguration; import org.apache.archiva.metadata.model.facets.AuditEvent; import org.apache.archiva.repository.RemoteRepository; import org.apache.archiva.repository.RepositoryException; diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/proxyconnector/DefaultProxyConnectorAdmin.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/proxyconnector/DefaultProxyConnectorAdmin.java index 4a8f452ba..e6ec28b42 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/proxyconnector/DefaultProxyConnectorAdmin.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/proxyconnector/DefaultProxyConnectorAdmin.java @@ -24,9 +24,9 @@ import org.apache.archiva.admin.model.beans.ProxyConnector; import org.apache.archiva.admin.model.proxyconnector.ProxyConnectorAdmin; import org.apache.archiva.admin.model.proxyconnector.ProxyConnectorOrderComparator; import org.apache.archiva.admin.repository.AbstractRepositoryAdmin; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; -import org.apache.archiva.configuration.functors.ProxyConnectorSelectionPredicate; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.functors.ProxyConnectorSelectionPredicate; import org.apache.archiva.metadata.model.facets.AuditEvent; import org.apache.archiva.repository.RepositoryRegistry; import org.apache.commons.collections4.IterableUtils; diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/proxyconnectorrule/DefaultProxyConnectorRuleAdmin.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/proxyconnectorrule/DefaultProxyConnectorRuleAdmin.java index 9dbc37429..b6dd64bcc 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/proxyconnectorrule/DefaultProxyConnectorRuleAdmin.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/proxyconnectorrule/DefaultProxyConnectorRuleAdmin.java @@ -25,9 +25,9 @@ import org.apache.archiva.admin.model.beans.ProxyConnectorRule; import org.apache.archiva.proxy.model.ProxyConnectorRuleType; import org.apache.archiva.admin.model.proxyconnectorrule.ProxyConnectorRuleAdmin; import org.apache.archiva.admin.repository.AbstractRepositoryAdmin; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; -import org.apache.archiva.configuration.ProxyConnectorRuleConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorRuleConfiguration; import org.apache.commons.lang3.StringUtils; import org.slf4j.Logger; import org.slf4j.LoggerFactory; diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/remote/DefaultRemoteRepositoryAdmin.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/remote/DefaultRemoteRepositoryAdmin.java index 4a845beea..427f52e27 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/remote/DefaultRemoteRepositoryAdmin.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/remote/DefaultRemoteRepositoryAdmin.java @@ -23,9 +23,9 @@ import org.apache.archiva.admin.model.RepositoryAdminException; import org.apache.archiva.admin.model.remote.RemoteRepositoryAdmin; import org.apache.archiva.admin.repository.AbstractRepositoryAdmin; import org.apache.archiva.common.utils.PathUtil; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryCheckPath; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryCheckPath; import org.apache.archiva.metadata.model.facets.AuditEvent; import org.apache.archiva.repository.RemoteRepository; import org.apache.archiva.repository.RepositoryCredentials; diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/DefaultArchivaRuntimeConfigurationAdmin.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/DefaultArchivaRuntimeConfigurationAdmin.java index b6b1eb41b..2413c7194 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/DefaultArchivaRuntimeConfigurationAdmin.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/DefaultArchivaRuntimeConfigurationAdmin.java @@ -24,9 +24,9 @@ import org.apache.archiva.admin.model.beans.CacheConfiguration; import org.apache.archiva.admin.model.beans.FileLockConfiguration; import org.apache.archiva.admin.model.runtime.ArchivaRuntimeConfigurationAdmin; import org.apache.archiva.admin.repository.AbstractRepositoryAdmin; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.IndeterminateConfigurationException; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.provider.IndeterminateConfigurationException; import org.apache.archiva.components.cache.Cache; import org.apache.archiva.components.registry.RegistryException; import org.springframework.stereotype.Service; @@ -146,7 +146,7 @@ public class DefaultArchivaRuntimeConfigurationAdmin } protected ArchivaRuntimeConfiguration build( - org.apache.archiva.configuration.ArchivaRuntimeConfiguration archivaRuntimeConfiguration ) + org.apache.archiva.configuration.model.ArchivaRuntimeConfiguration archivaRuntimeConfiguration ) { if ( archivaRuntimeConfiguration == null ) { @@ -175,24 +175,24 @@ public class DefaultArchivaRuntimeConfigurationAdmin return res; } - protected org.apache.archiva.configuration.ArchivaRuntimeConfiguration build( + protected org.apache.archiva.configuration.model.ArchivaRuntimeConfiguration build( ArchivaRuntimeConfiguration archivaRuntimeConfiguration ) { if ( archivaRuntimeConfiguration == null ) { - return new org.apache.archiva.configuration.ArchivaRuntimeConfiguration(); + return new org.apache.archiva.configuration.model.ArchivaRuntimeConfiguration(); } - org.apache.archiva.configuration.ArchivaRuntimeConfiguration res = + org.apache.archiva.configuration.model.ArchivaRuntimeConfiguration res = getModelMapper().map( archivaRuntimeConfiguration, - org.apache.archiva.configuration.ArchivaRuntimeConfiguration.class ); + org.apache.archiva.configuration.model.ArchivaRuntimeConfiguration.class ); if ( archivaRuntimeConfiguration.getUrlFailureCacheConfiguration() != null ) { res.setUrlFailureCacheConfiguration( getModelMapper().map( archivaRuntimeConfiguration.getUrlFailureCacheConfiguration(), - org.apache.archiva.configuration.CacheConfiguration.class ) ); + org.apache.archiva.configuration.model.CacheConfiguration.class ) ); } @@ -200,7 +200,7 @@ public class DefaultArchivaRuntimeConfigurationAdmin { res.setFileLockConfiguration( getModelMapper().map( archivaRuntimeConfiguration.getFileLockConfiguration(), - org.apache.archiva.configuration.FileLockConfiguration.class ) ); + org.apache.archiva.configuration.model.FileLockConfiguration.class ) ); } return res; diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/DefaultRedbackRuntimeConfigurationAdmin.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/DefaultRedbackRuntimeConfigurationAdmin.java index d15990189..9c6afe659 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/DefaultRedbackRuntimeConfigurationAdmin.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/DefaultRedbackRuntimeConfigurationAdmin.java @@ -25,15 +25,14 @@ import org.apache.archiva.admin.model.beans.LdapGroupMapping; import org.apache.archiva.admin.model.beans.RedbackRuntimeConfiguration; import org.apache.archiva.admin.model.runtime.RedbackRuntimeConfigurationAdmin; import org.apache.archiva.admin.repository.AbstractRepositoryAdmin; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.IndeterminateConfigurationException; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.provider.IndeterminateConfigurationException; import org.apache.archiva.components.cache.Cache; import org.apache.archiva.components.registry.RegistryException; -import org.apache.archiva.configuration.util.ConfigMapper; +import org.apache.archiva.configuration.provider.util.ConfigMapper; import org.apache.archiva.redback.configuration.UserConfiguration; import org.apache.archiva.redback.configuration.UserConfigurationException; -import org.apache.archiva.redback.configuration.UserConfigurationKeys; import org.apache.archiva.redback.users.User; import org.apache.commons.lang3.StringUtils; import org.slf4j.Logger; @@ -349,7 +348,7 @@ public class DefaultRedbackRuntimeConfigurationAdmin public void updateRedbackRuntimeConfiguration( RedbackRuntimeConfiguration redbackRuntimeConfiguration ) throws RepositoryAdminException { - org.apache.archiva.configuration.RedbackRuntimeConfiguration runtimeConfiguration = + org.apache.archiva.configuration.model.RedbackRuntimeConfiguration runtimeConfiguration = build( redbackRuntimeConfiguration ); Configuration configuration = archivaConfiguration.getConfiguration(); configuration.setRedbackRuntimeConfiguration( runtimeConfiguration ); @@ -368,7 +367,7 @@ public class DefaultRedbackRuntimeConfigurationAdmin } private RedbackRuntimeConfiguration build( - org.apache.archiva.configuration.RedbackRuntimeConfiguration runtimeConfiguration ) + org.apache.archiva.configuration.model.RedbackRuntimeConfiguration runtimeConfiguration ) { RedbackRuntimeConfiguration redbackRuntimeConfiguration = getModelMapper().map( runtimeConfiguration, RedbackRuntimeConfiguration.class ); @@ -396,13 +395,13 @@ public class DefaultRedbackRuntimeConfigurationAdmin redbackRuntimeConfiguration.setUsersCacheConfiguration( new CacheConfiguration() ); } - List<org.apache.archiva.configuration.LdapGroupMapping> mappings = runtimeConfiguration.getLdapGroupMappings(); + List<org.apache.archiva.configuration.model.LdapGroupMapping> mappings = runtimeConfiguration.getLdapGroupMappings(); if ( mappings != null && mappings.size() > 0 ) { List<LdapGroupMapping> ldapGroupMappings = new ArrayList<>( mappings.size() ); - for ( org.apache.archiva.configuration.LdapGroupMapping mapping : mappings ) + for ( org.apache.archiva.configuration.model.LdapGroupMapping mapping : mappings ) { ldapGroupMappings.add( new LdapGroupMapping( mapping.getGroup(), mapping.getRoleNames() ) ); } @@ -426,19 +425,19 @@ public class DefaultRedbackRuntimeConfigurationAdmin LDAP_MAPPER.getAllAttributes( ).stream( ).forEach( att -> properties.remove( att ) ); } - private org.apache.archiva.configuration.RedbackRuntimeConfiguration build( + private org.apache.archiva.configuration.model.RedbackRuntimeConfiguration build( RedbackRuntimeConfiguration redbackRuntimeConfiguration ) { - org.apache.archiva.configuration.RedbackRuntimeConfiguration res = + org.apache.archiva.configuration.model.RedbackRuntimeConfiguration res = getModelMapper().map( redbackRuntimeConfiguration, - org.apache.archiva.configuration.RedbackRuntimeConfiguration.class ); + org.apache.archiva.configuration.model.RedbackRuntimeConfiguration.class ); if ( redbackRuntimeConfiguration.getLdapConfiguration() == null ) { redbackRuntimeConfiguration.setLdapConfiguration( new LdapConfiguration() ); } res.setLdapConfiguration( getModelMapper().map( redbackRuntimeConfiguration.getLdapConfiguration(), - org.apache.archiva.configuration.LdapConfiguration.class ) ); + org.apache.archiva.configuration.model.LdapConfiguration.class ) ); if ( redbackRuntimeConfiguration.getUsersCacheConfiguration() == null ) { @@ -446,21 +445,21 @@ public class DefaultRedbackRuntimeConfigurationAdmin } res.setUsersCacheConfiguration( getModelMapper().map( redbackRuntimeConfiguration.getUsersCacheConfiguration(), - org.apache.archiva.configuration.CacheConfiguration.class ) ); + org.apache.archiva.configuration.model.CacheConfiguration.class ) ); List<LdapGroupMapping> ldapGroupMappings = redbackRuntimeConfiguration.getLdapGroupMappings(); if ( ldapGroupMappings != null && ldapGroupMappings.size() > 0 ) { - List<org.apache.archiva.configuration.LdapGroupMapping> mappings = + List<org.apache.archiva.configuration.model.LdapGroupMapping> mappings = new ArrayList<>( ldapGroupMappings.size() ); for ( LdapGroupMapping ldapGroupMapping : ldapGroupMappings ) { - org.apache.archiva.configuration.LdapGroupMapping mapping = - new org.apache.archiva.configuration.LdapGroupMapping(); + org.apache.archiva.configuration.model.LdapGroupMapping mapping = + new org.apache.archiva.configuration.model.LdapGroupMapping(); mapping.setGroup( ldapGroupMapping.getGroup() ); mapping.setRoleNames( new ArrayList<>( ldapGroupMapping.getRoleNames() ) ); mappings.add( mapping ); diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/mock/ArchivaIndexManagerMock.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/mock/ArchivaIndexManagerMock.java index 6fbfa9589..0557fdb7b 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/mock/ArchivaIndexManagerMock.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/mock/ArchivaIndexManagerMock.java @@ -21,7 +21,7 @@ package org.apache.archiva.admin.mock; import org.apache.archiva.common.filelock.DefaultFileLockManager; import org.apache.archiva.common.utils.PathUtil; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.indexer.ArchivaIndexManager; import org.apache.archiva.indexer.ArchivaIndexingContext; import org.apache.archiva.indexer.IndexCreationFailedException; diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/repository/AbstractRepositoryAdminTest.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/repository/AbstractRepositoryAdminTest.java index 2d84e474f..9d7a9661f 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/repository/AbstractRepositoryAdminTest.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/repository/AbstractRepositoryAdminTest.java @@ -27,7 +27,7 @@ import org.apache.archiva.admin.model.managed.ManagedRepositoryAdmin; import org.apache.archiva.admin.model.proxyconnector.ProxyConnectorAdmin; import org.apache.archiva.admin.model.proxyconnectorrule.ProxyConnectorRuleAdmin; import org.apache.archiva.admin.model.remote.RemoteRepositoryAdmin; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.redback.role.RoleManager; import org.apache.archiva.redback.users.User; import org.apache.archiva.redback.users.memory.SimpleUser; diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/repository/managed/ManagedRepositoryAdminTest.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/repository/managed/ManagedRepositoryAdminTest.java index 2e542d5cc..2378d49e5 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/repository/managed/ManagedRepositoryAdminTest.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/test/java/org/apache/archiva/admin/repository/managed/ManagedRepositoryAdminTest.java @@ -21,7 +21,7 @@ package org.apache.archiva.admin.repository.managed; import org.apache.archiva.admin.model.beans.ManagedRepository; import org.apache.archiva.admin.repository.AbstractRepositoryAdminTest; import org.apache.archiva.common.utils.FileUtils; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.metadata.model.facets.AuditEvent; import org.apache.archiva.repository.RepositoryRegistry; import org.apache.archiva.security.common.ArchivaRoleConstants; diff --git a/archiva-modules/archiva-base/archiva-repository-api/pom.xml b/archiva-modules/archiva-base/archiva-repository-api/pom.xml index be94705fe..4ae27d9e3 100644 --- a/archiva-modules/archiva-base/archiva-repository-api/pom.xml +++ b/archiva-modules/archiva-base/archiva-repository-api/pom.xml @@ -52,8 +52,8 @@ <artifactId>archiva-model</artifactId> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.springframework</groupId> diff --git a/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryContentFactory.java b/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryContentFactory.java index 537a043a6..3ea75b266 100644 --- a/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryContentFactory.java +++ b/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryContentFactory.java @@ -19,10 +19,10 @@ package org.apache.archiva.repository; * under the License. */ -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ConfigurationNames; import org.apache.archiva.components.registry.Registry; import org.apache.archiva.components.registry.RegistryListener; +import org.apache.archiva.configuration.model.ConfigurationNames; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.springframework.context.ApplicationContext; import org.springframework.stereotype.Service; diff --git a/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryHandler.java b/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryHandler.java index ee7f1e4e1..8ed6c37da 100644 --- a/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryHandler.java +++ b/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryHandler.java @@ -17,8 +17,8 @@ package org.apache.archiva.repository; * under the License. */ -import org.apache.archiva.configuration.AbstractRepositoryConfiguration; -import org.apache.archiva.configuration.Configuration; +import org.apache.archiva.configuration.model.AbstractRepositoryConfiguration; +import org.apache.archiva.configuration.model.Configuration; import org.apache.archiva.repository.validation.CheckedResult; import org.apache.archiva.repository.validation.RepositoryChecker; import org.apache.archiva.repository.validation.RepositoryValidator; @@ -141,6 +141,19 @@ public interface RepositoryHandler<R extends Repository, C extends AbstractRepos putWithCheck( C repositoryConfiguration, RepositoryChecker<R, D> checker ) throws RepositoryException; /** + * Adds or updates a repository from the given configuration data. The resulting repository is + * checked by the default repository checker of the handler instance and the result is returned. + * If the checker returns a valid result, the registry is updated and configuration is saved. + * + * @param repositoryConfiguration the repository configuration + * @return the repository and the check result as map of attributes -> list of validation errors + * @throws RepositoryException if the creation or update failed + */ + CheckedResult<R, Map<String, List<ValidationError>>> + putWithCheck( C repositoryConfiguration ) throws RepositoryException; + + + /** * Removes the given repository from the registry and updates references and saves the new configuration. * * @param id The repository identifier diff --git a/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryHandlerManager.java b/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryHandlerManager.java index d3270d184..f47bb184a 100644 --- a/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryHandlerManager.java +++ b/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryHandlerManager.java @@ -17,7 +17,7 @@ package org.apache.archiva.repository; * under the License. */ -import org.apache.archiva.configuration.AbstractRepositoryConfiguration; +import org.apache.archiva.configuration.model.AbstractRepositoryConfiguration; import org.apache.archiva.event.Event; import org.apache.archiva.event.EventHandler; diff --git a/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryProvider.java b/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryProvider.java index 813acb61d..89005f662 100644 --- a/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryProvider.java +++ b/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryProvider.java @@ -19,9 +19,9 @@ package org.apache.archiva.repository; * under the License. */ -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.event.EventHandler; import org.apache.archiva.repository.event.RepositoryEvent; diff --git a/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryRegistry.java b/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryRegistry.java index 718045e29..1c6123a83 100644 --- a/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryRegistry.java +++ b/archiva-modules/archiva-base/archiva-repository-api/src/main/java/org/apache/archiva/repository/RepositoryRegistry.java @@ -19,11 +19,11 @@ package org.apache.archiva.repository; * under the License. */ -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.event.EventSource; import org.apache.archiva.indexer.ArchivaIndexManager; import org.apache.archiva.indexer.IndexUpdateFailedException; @@ -191,6 +191,16 @@ public interface RepositoryRegistry extends EventSource, RepositoryHandlerManage ManagedRepository putRepository( ManagedRepositoryConfiguration managedRepositoryConfiguration, Configuration configuration ) throws RepositoryException; /** + * Validates the given repository configuration and adds the repository persistent to the registry, if it is valid. + * If the validation was not successful, the repository will not be added or persistet, and it will return the list of validation errors. + * + * @param configuration the managed repository configuration + * @return the managed repository or a list of validation errors + * @throws RepositoryException if there are errors while adding the repository + */ + CheckedResult<ManagedRepository, Map<String, List<ValidationError>>> putRepositoryAndValidate( ManagedRepositoryConfiguration configuration) throws RepositoryException; + + /** * Adds or updates the given repository group. If a repository group with the given id exists already, it is updated * from the data of the given instance. Otherwise a new repository is created and updated by the data of the given instance. * @@ -265,6 +275,19 @@ public interface RepositoryRegistry extends EventSource, RepositoryHandlerManage * Adds or updates the given remote repository. If a remote repository with the given id exists already, it is updated * from the data of the given configuration. Otherwise a new repository is created and updated by the data of the given configuration. * + * The remoteRepositoryConfiguration is validated before adding to the registry and persisting. If the validation fails, + * it is not registered or updated. + * + * @param remoteRepositoryConfiguration the remote repository configuration + * @return the repository instance, that was created or updated + * @throws RepositoryException if an error occurred while creating or updating the instance + */ + CheckedResult<RemoteRepository, Map<String, List<ValidationError>>> putRepositoryAndValidate( RemoteRepositoryConfiguration remoteRepositoryConfiguration ) throws RepositoryException; + + /** + * Adds or updates the given remote repository. If a remote repository with the given id exists already, it is updated + * from the data of the given configuration. Otherwise a new repository is created and updated by the data of the given configuration. + * * This method can be used, if the archiva configuration should not be saved. It will only update the given configuration object. * * @param remoteRepositoryConfiguration the remote repository configuration diff --git a/archiva-modules/archiva-base/archiva-repository-layer/pom.xml b/archiva-modules/archiva-base/archiva-repository-layer/pom.xml index c68e4bce6..b9b6f4558 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/pom.xml +++ b/archiva-modules/archiva-base/archiva-repository-layer/pom.xml @@ -54,8 +54,8 @@ <artifactId>archiva-repository-api</artifactId> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/AbstractRepositoryHandler.java b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/AbstractRepositoryHandler.java index 9e316a7fe..0e17aacd6 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/AbstractRepositoryHandler.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/AbstractRepositoryHandler.java @@ -18,9 +18,9 @@ package org.apache.archiva.repository.base; */ import org.apache.archiva.components.registry.RegistryException; -import org.apache.archiva.configuration.AbstractRepositoryConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.IndeterminateConfigurationException; +import org.apache.archiva.configuration.model.AbstractRepositoryConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.provider.IndeterminateConfigurationException; import org.apache.archiva.event.Event; import org.apache.archiva.event.EventManager; import org.apache.archiva.event.EventType; @@ -214,7 +214,13 @@ public abstract class AbstractRepositoryHandler<R extends Repository, C extends } - protected abstract C findRepositoryConfiguration(Configuration configuration, String id); + @Override + public CheckedResult<R, Map<String, List<ValidationError>>> putWithCheck( C repositoryConfiguration ) throws RepositoryException + { + return putWithCheck( repositoryConfiguration, getValidator( ) ); + } + + protected abstract C findRepositoryConfiguration( Configuration configuration, String id); protected abstract void removeRepositoryConfiguration(Configuration configuration, C repoConfiguration ); diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/ArchivaRepositoryRegistry.java b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/ArchivaRepositoryRegistry.java index a2c7dc39f..1d0c32207 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/ArchivaRepositoryRegistry.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/ArchivaRepositoryRegistry.java @@ -20,15 +20,15 @@ package org.apache.archiva.repository.base; */ import org.apache.archiva.components.registry.RegistryException; -import org.apache.archiva.configuration.AbstractRepositoryConfiguration; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ConfigurationEvent; -import org.apache.archiva.configuration.ConfigurationListener; -import org.apache.archiva.configuration.IndeterminateConfigurationException; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.AbstractRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.provider.ConfigurationEvent; +import org.apache.archiva.configuration.provider.ConfigurationListener; +import org.apache.archiva.configuration.provider.IndeterminateConfigurationException; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.event.Event; import org.apache.archiva.event.EventHandler; import org.apache.archiva.event.EventManager; @@ -563,6 +563,17 @@ public class ArchivaRepositoryRegistry implements ConfigurationListener, EventHa } } + @Override + public CheckedResult<ManagedRepository, Map<String, List<ValidationError>>> putRepositoryAndValidate( ManagedRepositoryConfiguration configuration ) throws RepositoryException + { + rwLock.writeLock().lock(); + try { + return managedRepositoryHandler.putWithCheck( configuration ); + } finally + { + rwLock.writeLock( ).unlock( ); + } + } /** * Adds a new repository group to the current list, or replaces the repository group definition with @@ -620,7 +631,7 @@ public class ArchivaRepositoryRegistry implements ConfigurationListener, EventHa rwLock.writeLock( ).lock( ); try { - return groupHandler.putWithCheck( repositoryGroupConfiguration, groupHandler.getValidator( ) ); + return groupHandler.putWithCheck( repositoryGroupConfiguration ); } finally { @@ -695,6 +706,18 @@ public class ArchivaRepositoryRegistry implements ConfigurationListener, EventHa } } + @Override + public CheckedResult<RemoteRepository, Map<String, List<ValidationError>>> putRepositoryAndValidate( RemoteRepositoryConfiguration remoteRepositoryConfiguration ) throws RepositoryException + { + rwLock.writeLock().lock(); + try { + return remoteRepositoryHandler.putWithCheck( remoteRepositoryConfiguration ); + } finally + { + rwLock.writeLock().unlock(); + } + } + /** * Adds a new repository or updates the repository with the same id. The given configuration object is updated, but * the configuration is not saved. diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/ConfigurationHandler.java b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/ConfigurationHandler.java index 9278e022a..b54e385a1 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/ConfigurationHandler.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/ConfigurationHandler.java @@ -18,10 +18,10 @@ package org.apache.archiva.repository.base; */ import org.apache.archiva.components.registry.RegistryException; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ConfigurationListener; -import org.apache.archiva.configuration.IndeterminateConfigurationException; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.provider.ConfigurationListener; +import org.apache.archiva.configuration.provider.IndeterminateConfigurationException; import org.springframework.stereotype.Service; import java.util.concurrent.locks.ReentrantReadWriteLock; diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/group/RepositoryGroupHandler.java b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/group/RepositoryGroupHandler.java index 9285de888..547a66659 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/group/RepositoryGroupHandler.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/group/RepositoryGroupHandler.java @@ -18,10 +18,10 @@ package org.apache.archiva.repository.base.group; */ import org.apache.archiva.components.registry.RegistryException; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.IndeterminateConfigurationException; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.provider.IndeterminateConfigurationException; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.indexer.merger.MergedRemoteIndexesScheduler; import org.apache.archiva.repository.EditableRepository; import org.apache.archiva.repository.EditableRepositoryGroup; diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/managed/ManagedRepositoryHandler.java b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/managed/ManagedRepositoryHandler.java index 0ed99ecc7..bdcbf04d8 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/managed/ManagedRepositoryHandler.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/managed/ManagedRepositoryHandler.java @@ -18,9 +18,9 @@ package org.apache.archiva.repository.base.managed; */ import org.apache.archiva.components.registry.RegistryException; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.IndeterminateConfigurationException; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.provider.IndeterminateConfigurationException; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.indexer.ArchivaIndexManager; import org.apache.archiva.indexer.IndexCreationFailedException; import org.apache.archiva.indexer.IndexManagerFactory; diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/remote/RemoteRepositoryHandler.java b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/remote/RemoteRepositoryHandler.java index ea1f19c91..9d9417f86 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/remote/RemoteRepositoryHandler.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/base/remote/RemoteRepositoryHandler.java @@ -18,10 +18,10 @@ package org.apache.archiva.repository.base.remote; */ import org.apache.archiva.components.registry.RegistryException; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.IndeterminateConfigurationException; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.provider.IndeterminateConfigurationException; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; import org.apache.archiva.indexer.ArchivaIndexManager; import org.apache.archiva.indexer.IndexCreationFailedException; import org.apache.archiva.indexer.IndexManagerFactory; diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/metadata/base/MetadataTools.java b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/metadata/base/MetadataTools.java index cb8b6eb4d..2a385ba5d 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/metadata/base/MetadataTools.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/main/java/org/apache/archiva/repository/metadata/base/MetadataTools.java @@ -25,12 +25,12 @@ import org.apache.archiva.common.utils.VersionComparator; import org.apache.archiva.common.utils.VersionUtil; import org.apache.archiva.components.registry.Registry; import org.apache.archiva.components.registry.RegistryListener; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ConfigurationEvent; -import org.apache.archiva.configuration.ConfigurationListener; -import org.apache.archiva.configuration.ConfigurationNames; -import org.apache.archiva.configuration.FileTypes; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ConfigurationEvent; +import org.apache.archiva.configuration.provider.ConfigurationListener; +import org.apache.archiva.configuration.model.ConfigurationNames; +import org.apache.archiva.configuration.provider.FileTypes; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; import org.apache.archiva.model.ArchivaRepositoryMetadata; import org.apache.archiva.model.Plugin; import org.apache.archiva.model.SnapshotVersion; diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/ArchivaRepositoryRegistryTest.java b/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/ArchivaRepositoryRegistryTest.java index e4bb05230..d1f58e263 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/ArchivaRepositoryRegistryTest.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/ArchivaRepositoryRegistryTest.java @@ -19,10 +19,10 @@ package org.apache.archiva.repository.base; * under the License. */ -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; import org.apache.archiva.repository.ManagedRepository; import org.apache.archiva.repository.ReleaseScheme; import org.apache.archiva.repository.RemoteRepository; diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/group/RepositoryGroupHandlerTest.java b/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/group/RepositoryGroupHandlerTest.java index ea65a2e0e..fb607e427 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/group/RepositoryGroupHandlerTest.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/group/RepositoryGroupHandlerTest.java @@ -21,11 +21,11 @@ package org.apache.archiva.repository.base.group; import org.apache.archiva.common.filelock.DefaultFileLockManager; import org.apache.archiva.common.filelock.FileLockManager; import org.apache.archiva.common.utils.FileUtils; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.indexer.merger.MergedRemoteIndexesScheduler; import org.apache.archiva.repository.EditableRepositoryGroup; import org.apache.archiva.repository.ManagedRepository; diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/managed/BasicManagedRepositoryValidatorTest.java b/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/managed/BasicManagedRepositoryValidatorTest.java index 2fe4f671e..a5ed4b5b0 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/managed/BasicManagedRepositoryValidatorTest.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/managed/BasicManagedRepositoryValidatorTest.java @@ -20,7 +20,7 @@ package org.apache.archiva.repository.base.managed; import org.apache.archiva.common.filelock.DefaultFileLockManager; import org.apache.archiva.common.filelock.FileLockManager; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.repository.EditableManagedRepository; import org.apache.archiva.repository.ManagedRepository; import org.apache.archiva.repository.RepositoryException; diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/managed/ManagedRepositoryHandlerTest.java b/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/managed/ManagedRepositoryHandlerTest.java index 8811d4a46..fb6505de7 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/managed/ManagedRepositoryHandlerTest.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/managed/ManagedRepositoryHandlerTest.java @@ -21,11 +21,10 @@ package org.apache.archiva.repository.base.managed; import org.apache.archiva.common.filelock.DefaultFileLockManager; import org.apache.archiva.common.filelock.FileLockManager; import org.apache.archiva.common.utils.FileUtils; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.indexer.IndexManagerFactory; -import org.apache.archiva.indexer.merger.MergedRemoteIndexesScheduler; import org.apache.archiva.repository.EditableManagedRepository; import org.apache.archiva.repository.ManagedRepository; import org.apache.archiva.repository.Repository; @@ -41,7 +40,6 @@ import org.apache.archiva.repository.validation.RepositoryValidator; import org.apache.archiva.repository.validation.ValidationError; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.extension.ExtendWith; -import org.mockito.Mock; import org.mockito.junit.jupiter.MockitoExtension; import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.junit.jupiter.SpringExtension; diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/remote/RemoteRepositoryHandlerTest.java b/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/remote/RemoteRepositoryHandlerTest.java index f596b8e23..b23c7f92f 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/remote/RemoteRepositoryHandlerTest.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/base/remote/RemoteRepositoryHandlerTest.java @@ -21,9 +21,9 @@ package org.apache.archiva.repository.base.remote; import org.apache.archiva.common.filelock.DefaultFileLockManager; import org.apache.archiva.common.filelock.FileLockManager; import org.apache.archiva.common.utils.FileUtils; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; import org.apache.archiva.indexer.IndexManagerFactory; import org.apache.archiva.repository.EditableRemoteRepository; import org.apache.archiva.repository.RemoteRepository; diff --git a/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/mock/RepositoryProviderMock.java b/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/mock/RepositoryProviderMock.java index 5a3a4736d..3a0707367 100644 --- a/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/mock/RepositoryProviderMock.java +++ b/archiva-modules/archiva-base/archiva-repository-layer/src/test/java/org/apache/archiva/repository/mock/RepositoryProviderMock.java @@ -19,9 +19,9 @@ package org.apache.archiva.repository.mock; * under the License. */ -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.event.EventHandler; import org.apache.archiva.repository.*; import org.apache.archiva.event.Event; diff --git a/archiva-modules/archiva-base/archiva-repository-scanner/pom.xml b/archiva-modules/archiva-base/archiva-repository-scanner/pom.xml index c57a4ba1e..11131f74d 100644 --- a/archiva-modules/archiva-base/archiva-repository-scanner/pom.xml +++ b/archiva-modules/archiva-base/archiva-repository-scanner/pom.xml @@ -38,8 +38,8 @@ <artifactId>archiva-consumer-api</artifactId> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/archiva-base/archiva-repository-scanner/src/main/java/org/apache/archiva/repository/scanner/DefaultRepositoryScanner.java b/archiva-modules/archiva-base/archiva-repository-scanner/src/main/java/org/apache/archiva/repository/scanner/DefaultRepositoryScanner.java index 650162bd5..0fd0c3cac 100644 --- a/archiva-modules/archiva-base/archiva-repository-scanner/src/main/java/org/apache/archiva/repository/scanner/DefaultRepositoryScanner.java +++ b/archiva-modules/archiva-base/archiva-repository-scanner/src/main/java/org/apache/archiva/repository/scanner/DefaultRepositoryScanner.java @@ -19,7 +19,7 @@ package org.apache.archiva.repository.scanner; * under the License. */ -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.consumers.ConsumerException; import org.apache.archiva.consumers.InvalidRepositoryContentConsumer; import org.apache.archiva.consumers.KnownRepositoryContentConsumer; diff --git a/archiva-modules/archiva-base/archiva-repository-scanner/src/main/java/org/apache/archiva/repository/scanner/RepositoryContentConsumers.java b/archiva-modules/archiva-base/archiva-repository-scanner/src/main/java/org/apache/archiva/repository/scanner/RepositoryContentConsumers.java index 0795fa557..5457202a2 100644 --- a/archiva-modules/archiva-base/archiva-repository-scanner/src/main/java/org/apache/archiva/repository/scanner/RepositoryContentConsumers.java +++ b/archiva-modules/archiva-base/archiva-repository-scanner/src/main/java/org/apache/archiva/repository/scanner/RepositoryContentConsumers.java @@ -23,7 +23,7 @@ import org.apache.archiva.admin.model.RepositoryAdminException; import org.apache.archiva.admin.model.admin.ArchivaAdministration; import org.apache.archiva.common.utils.BaseFile; import org.apache.archiva.common.utils.PathUtil; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.consumers.ConsumerException; import org.apache.archiva.consumers.InvalidRepositoryContentConsumer; import org.apache.archiva.consumers.KnownRepositoryContentConsumer; diff --git a/archiva-modules/archiva-base/archiva-repository-scanner/src/test/java/org/apache/archiva/repository/scanner/ArchivaAdministrationStub.java b/archiva-modules/archiva-base/archiva-repository-scanner/src/test/java/org/apache/archiva/repository/scanner/ArchivaAdministrationStub.java index d3eadfdfa..ca43b6569 100644 --- a/archiva-modules/archiva-base/archiva-repository-scanner/src/test/java/org/apache/archiva/repository/scanner/ArchivaAdministrationStub.java +++ b/archiva-modules/archiva-base/archiva-repository-scanner/src/test/java/org/apache/archiva/repository/scanner/ArchivaAdministrationStub.java @@ -26,7 +26,7 @@ import org.apache.archiva.admin.model.beans.LegacyArtifactPath; import org.apache.archiva.admin.model.beans.NetworkConfiguration; import org.apache.archiva.admin.model.beans.OrganisationInformation; import org.apache.archiva.admin.model.beans.UiConfiguration; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.springframework.stereotype.Service; import java.util.List; diff --git a/archiva-modules/archiva-base/archiva-repository-scanner/src/test/java/org/apache/archiva/repository/scanner/RepositoryContentConsumersTest.java b/archiva-modules/archiva-base/archiva-repository-scanner/src/test/java/org/apache/archiva/repository/scanner/RepositoryContentConsumersTest.java index b2bfd5191..40b0e9e77 100644 --- a/archiva-modules/archiva-base/archiva-repository-scanner/src/test/java/org/apache/archiva/repository/scanner/RepositoryContentConsumersTest.java +++ b/archiva-modules/archiva-base/archiva-repository-scanner/src/test/java/org/apache/archiva/repository/scanner/RepositoryContentConsumersTest.java @@ -20,7 +20,7 @@ package org.apache.archiva.repository.scanner; */ import junit.framework.TestCase; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.consumers.InvalidRepositoryContentConsumer; import org.apache.archiva.consumers.KnownRepositoryContentConsumer; import org.apache.archiva.repository.base.managed.BasicManagedRepository; diff --git a/archiva-modules/archiva-base/archiva-repository-scanner/src/test/resources/spring-context.xml b/archiva-modules/archiva-base/archiva-repository-scanner/src/test/resources/spring-context.xml index 219f7144a..a77f925e2 100644 --- a/archiva-modules/archiva-base/archiva-repository-scanner/src/test/resources/spring-context.xml +++ b/archiva-modules/archiva-base/archiva-repository-scanner/src/test/resources/spring-context.xml @@ -24,7 +24,7 @@ http://www.springframework.org/schema/beans/spring-beans-3.0.xsd" default-lazy-init="true"> - <bean name="archivaConfiguration#test-conf" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-conf" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#configured"/> </bean> diff --git a/archiva-modules/archiva-maven/archiva-maven-indexer/pom.xml b/archiva-modules/archiva-maven/archiva-maven-indexer/pom.xml index f2855f681..b49e39c7d 100644 --- a/archiva-modules/archiva-maven/archiva-maven-indexer/pom.xml +++ b/archiva-modules/archiva-maven/archiva-maven-indexer/pom.xml @@ -77,8 +77,8 @@ <artifactId>archiva-model</artifactId> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> diff --git a/archiva-modules/archiva-maven/archiva-maven-indexer/src/main/java/org/apache/archiva/maven/indexer/MavenIndexManager.java b/archiva-modules/archiva-maven/archiva-maven-indexer/src/main/java/org/apache/archiva/maven/indexer/MavenIndexManager.java index 512c74194..da4d1b779 100644 --- a/archiva-modules/archiva-maven/archiva-maven-indexer/src/main/java/org/apache/archiva/maven/indexer/MavenIndexManager.java +++ b/archiva-modules/archiva-maven/archiva-maven-indexer/src/main/java/org/apache/archiva/maven/indexer/MavenIndexManager.java @@ -20,7 +20,7 @@ package org.apache.archiva.maven.indexer; import org.apache.archiva.common.utils.FileUtils; import org.apache.archiva.common.utils.PathUtil; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.indexer.ArchivaIndexManager; import org.apache.archiva.indexer.ArchivaIndexingContext; import org.apache.archiva.indexer.IndexCreationFailedException; diff --git a/archiva-modules/archiva-maven/archiva-maven-indexer/src/test/java/org/apache/archiva/maven/indexer/search/AbstractMavenRepositorySearch.java b/archiva-modules/archiva-maven/archiva-maven-indexer/src/test/java/org/apache/archiva/maven/indexer/search/AbstractMavenRepositorySearch.java index 4cdc10dba..3ff27e379 100644 --- a/archiva-modules/archiva-maven/archiva-maven-indexer/src/test/java/org/apache/archiva/maven/indexer/search/AbstractMavenRepositorySearch.java +++ b/archiva-modules/archiva-maven/archiva-maven-indexer/src/test/java/org/apache/archiva/maven/indexer/search/AbstractMavenRepositorySearch.java @@ -20,10 +20,9 @@ package org.apache.archiva.maven.indexer.search; import junit.framework.TestCase; import org.apache.archiva.common.utils.FileUtils; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ConfigurationListener; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.indexer.ArchivaIndexingContext; import org.apache.archiva.indexer.search.SearchResultHit; import org.apache.archiva.indexer.search.SearchResults; diff --git a/archiva-modules/archiva-maven/archiva-maven-proxy/pom.xml b/archiva-modules/archiva-maven/archiva-maven-proxy/pom.xml index 611964236..653256609 100644 --- a/archiva-modules/archiva-maven/archiva-maven-proxy/pom.xml +++ b/archiva-modules/archiva-maven/archiva-maven-proxy/pom.xml @@ -78,8 +78,8 @@ <artifactId>archiva-model</artifactId> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/AbstractProxyTestCase.java b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/AbstractProxyTestCase.java index ae3589333..5fd12f264 100644 --- a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/AbstractProxyTestCase.java +++ b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/AbstractProxyTestCase.java @@ -18,11 +18,11 @@ package org.apache.archiva.maven.proxy; * under the License. */ -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ArchivaRuntimeConfiguration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.ArchivaRuntimeConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; import org.apache.archiva.policies.CachedFailuresPolicy; import org.apache.archiva.policies.ChecksumPolicy; import org.apache.archiva.policies.PolicyOption; diff --git a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/HttpProxyTransferTest.java b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/HttpProxyTransferTest.java index 9d47b1bc7..f8ec13f00 100644 --- a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/HttpProxyTransferTest.java +++ b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/HttpProxyTransferTest.java @@ -18,10 +18,10 @@ package org.apache.archiva.maven.proxy; * under the License. */ -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.NetworkProxyConfiguration; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.NetworkProxyConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; import org.apache.archiva.policies.CachedFailuresPolicy; import org.apache.archiva.policies.ChecksumPolicy; import org.apache.archiva.policies.PropagateErrorsDownloadPolicy; diff --git a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/MetadataTransferTest.java b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/MetadataTransferTest.java index 530b0561f..bec37cf1b 100644 --- a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/MetadataTransferTest.java +++ b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/MetadataTransferTest.java @@ -20,7 +20,7 @@ package org.apache.archiva.maven.proxy; import org.apache.archiva.common.filelock.DefaultFileLockManager; import org.apache.archiva.common.utils.VersionUtil; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; import org.apache.archiva.model.ArchivaRepositoryMetadata; import org.apache.archiva.model.Plugin; import org.apache.archiva.model.SnapshotVersion; diff --git a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/MockConfiguration.java b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/MockConfiguration.java index 2cf6a105a..5116078ec 100644 --- a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/MockConfiguration.java +++ b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/MockConfiguration.java @@ -18,12 +18,15 @@ package org.apache.archiva.maven.proxy; * under the License. */ -import org.apache.archiva.configuration.*; +import org.apache.archiva.configuration.model.ArchivaRuntimeConfiguration; +import org.apache.archiva.configuration.model.FileType; +import org.apache.archiva.configuration.model.RepositoryScanningConfiguration; +import org.apache.archiva.configuration.provider.*; import org.apache.archiva.components.registry.Registry; import org.apache.archiva.components.registry.RegistryException; import org.apache.archiva.components.registry.RegistryListener; +import org.apache.archiva.configuration.model.Configuration; import org.apache.commons.lang3.StringUtils; -import org.mockito.Mockito; import org.springframework.stereotype.Service; import javax.annotation.PostConstruct; diff --git a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/mock/repository/RepositoryProviderMock.java b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/mock/repository/RepositoryProviderMock.java index 3c9efe8a6..90dfb5824 100644 --- a/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/mock/repository/RepositoryProviderMock.java +++ b/archiva-modules/archiva-maven/archiva-maven-proxy/src/test/java/org/apache/archiva/maven/proxy/mock/repository/RepositoryProviderMock.java @@ -18,9 +18,9 @@ package org.apache.archiva.maven.proxy.mock.repository; * under the License. */ -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.event.EventHandler; import org.apache.archiva.repository.base.managed.BasicManagedRepository; import org.apache.archiva.repository.base.remote.BasicRemoteRepository; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/pom.xml b/archiva-modules/archiva-maven/archiva-maven-repository/pom.xml index f415c77e3..7c042b5c7 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/pom.xml +++ b/archiva-modules/archiva-maven/archiva-maven-repository/pom.xml @@ -212,8 +212,8 @@ </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva.maven</groupId> diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/MavenRepositoryProvider.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/MavenRepositoryProvider.java index 636b8c988..87a263a03 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/MavenRepositoryProvider.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/MavenRepositoryProvider.java @@ -19,11 +19,11 @@ package org.apache.archiva.maven.repository; */ import org.apache.archiva.common.filelock.FileLockManager; -import org.apache.archiva.configuration.AbstractRepositoryConfiguration; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.AbstractRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.event.Event; import org.apache.archiva.event.EventHandler; import org.apache.archiva.repository.EditableManagedRepository; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/content/ManagedDefaultRepositoryContent.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/content/ManagedDefaultRepositoryContent.java index e9818dc63..4b9d27d51 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/content/ManagedDefaultRepositoryContent.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/content/ManagedDefaultRepositoryContent.java @@ -21,7 +21,7 @@ package org.apache.archiva.maven.repository.content; import org.apache.archiva.common.filelock.FileLockManager; import org.apache.archiva.common.utils.FileUtils; import org.apache.archiva.common.utils.VersionUtil; -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.maven.metadata.MavenMetadataReader; import org.apache.archiva.repository.EditableManagedRepository; import org.apache.archiva.repository.ItemDeleteStatus; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/content/MavenContentProvider.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/content/MavenContentProvider.java index eb80f7746..bea96aa0f 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/content/MavenContentProvider.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/content/MavenContentProvider.java @@ -19,7 +19,7 @@ package org.apache.archiva.maven.repository.content; */ import org.apache.archiva.common.filelock.FileLockManager; -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.maven.repository.metadata.storage.ArtifactMappingProvider; import org.apache.archiva.metadata.repository.storage.RepositoryPathTranslator; import org.apache.archiva.repository.ManagedRepository; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/merge/Maven2RepositoryMerger.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/merge/Maven2RepositoryMerger.java index 4bb7fb9a4..1bc75f21d 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/merge/Maven2RepositoryMerger.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/main/java/org/apache/archiva/maven/repository/merge/Maven2RepositoryMerger.java @@ -21,9 +21,9 @@ package org.apache.archiva.maven.repository.merge; import org.apache.archiva.common.filelock.DefaultFileLockManager; import org.apache.archiva.common.utils.VersionComparator; import org.apache.archiva.common.utils.VersionUtil; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.filter.Filter; import org.apache.archiva.maven.metadata.MavenMetadataReader; import org.apache.archiva.metadata.model.ArtifactMetadata; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/MavenRepositoryProviderTest.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/MavenRepositoryProviderTest.java index dcd3b7f37..98472de02 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/MavenRepositoryProviderTest.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/MavenRepositoryProviderTest.java @@ -19,10 +19,10 @@ package org.apache.archiva.maven.repository; */ import org.apache.archiva.common.utils.FileUtils; -import org.apache.archiva.configuration.ArchivaRuntimeConfiguration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.ArchivaRuntimeConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.repository.EditableRepositoryGroup; import org.apache.archiva.repository.ManagedRepository; import org.apache.archiva.repository.ReleaseScheme; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/content/ManagedDefaultRepositoryContentTest.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/content/ManagedDefaultRepositoryContentTest.java index 83930a1cd..5cebdf53a 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/content/ManagedDefaultRepositoryContentTest.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/content/ManagedDefaultRepositoryContentTest.java @@ -20,9 +20,9 @@ package org.apache.archiva.maven.repository.content; import org.apache.archiva.common.filelock.FileLockManager; import org.apache.archiva.common.utils.VersionComparator; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.FileType; -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.FileType; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.maven.metadata.MavenMetadataReader; import org.apache.archiva.maven.repository.MavenManagedRepository; import org.apache.archiva.maven.repository.metadata.storage.ArtifactMappingProvider; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/content/MavenRepositoryRequestInfoTest.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/content/MavenRepositoryRequestInfoTest.java index 1cfdc4709..764a57113 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/content/MavenRepositoryRequestInfoTest.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/content/MavenRepositoryRequestInfoTest.java @@ -20,9 +20,9 @@ package org.apache.archiva.maven.repository.content; import org.apache.archiva.common.filelock.FileLockManager; import org.apache.archiva.common.utils.FileUtils; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.FileType; -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.FileType; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.maven.repository.MavenManagedRepository; import org.apache.archiva.maven.repository.metadata.storage.ArtifactMappingProvider; import org.apache.archiva.metadata.repository.storage.RepositoryPathTranslator; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/dependency/tree/DependencyTreeBuilderTestMaven3.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/dependency/tree/DependencyTreeBuilderTestMaven3.java index c78ae5f9d..b5e251373 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/dependency/tree/DependencyTreeBuilderTestMaven3.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/dependency/tree/DependencyTreeBuilderTestMaven3.java @@ -19,9 +19,9 @@ package org.apache.archiva.maven.repository.dependency.tree; */ import junit.framework.TestCase; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.maven.model.Artifact; import org.apache.archiva.maven.model.TreeEntry; import org.apache.archiva.repository.RepositoryRegistry; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/merge/Maven2RepositoryMergerTest.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/merge/Maven2RepositoryMergerTest.java index 780d1b729..a36891a7c 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/merge/Maven2RepositoryMergerTest.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/merge/Maven2RepositoryMergerTest.java @@ -19,10 +19,10 @@ package org.apache.archiva.maven.repository.merge; */ import junit.framework.TestCase; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryScanningConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryScanningConfiguration; import org.apache.archiva.metadata.model.ArtifactMetadata; import org.apache.archiva.metadata.repository.MetadataRepository; import org.apache.archiva.metadata.repository.MetadataRepositoryException; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/MetadataToolsTest.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/MetadataToolsTest.java index 03d94f346..e7557ccc3 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/MetadataToolsTest.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/MetadataToolsTest.java @@ -19,7 +19,7 @@ package org.apache.archiva.maven.repository.metadata; */ import org.apache.archiva.common.utils.VersionComparator; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; import org.apache.archiva.maven.repository.AbstractRepositoryLayerTestCase; import org.apache.archiva.maven.repository.MavenManagedRepository; import org.apache.archiva.maven.repository.metadata.storage.mock.MockConfiguration; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/Maven2RepositoryMetadataResolverMRM1411RepoGroupTest.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/Maven2RepositoryMetadataResolverMRM1411RepoGroupTest.java index 730593083..0e33ad1d4 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/Maven2RepositoryMetadataResolverMRM1411RepoGroupTest.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/Maven2RepositoryMetadataResolverMRM1411RepoGroupTest.java @@ -19,12 +19,12 @@ package org.apache.archiva.maven.repository.metadata.storage; */ import junit.framework.TestCase; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.filter.AllFilter; import org.apache.archiva.filter.Filter; import org.apache.archiva.metadata.model.ArtifactMetadata; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/Maven2RepositoryMetadataResolverMRM1411Test.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/Maven2RepositoryMetadataResolverMRM1411Test.java index c9d5c0222..5c2a6cd55 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/Maven2RepositoryMetadataResolverMRM1411Test.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/Maven2RepositoryMetadataResolverMRM1411Test.java @@ -19,11 +19,11 @@ package org.apache.archiva.maven.repository.metadata.storage; */ import junit.framework.TestCase; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; import org.apache.archiva.filter.AllFilter; import org.apache.archiva.filter.Filter; import org.apache.archiva.metadata.model.ArtifactMetadata; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/Maven2RepositoryMetadataResolverTest.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/Maven2RepositoryMetadataResolverTest.java index 109ccacb1..6f5f72c1d 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/Maven2RepositoryMetadataResolverTest.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/Maven2RepositoryMetadataResolverTest.java @@ -19,12 +19,12 @@ package org.apache.archiva.maven.repository.metadata.storage; */ import junit.framework.TestCase; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryScanningConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryScanningConfiguration; import org.apache.archiva.filter.AllFilter; import org.apache.archiva.filter.ExcludesFilter; import org.apache.archiva.filter.Filter; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/mock/MockConfiguration.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/mock/MockConfiguration.java index a5de3eaeb..41a1368c3 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/mock/MockConfiguration.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/metadata/storage/mock/MockConfiguration.java @@ -21,13 +21,13 @@ package org.apache.archiva.maven.repository.metadata.storage.mock; import org.apache.archiva.components.registry.Registry; import org.apache.archiva.components.registry.RegistryException; import org.apache.archiva.components.registry.RegistryListener; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ArchivaRuntimeConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ConfigurationListener; -import org.apache.archiva.configuration.FileType; -import org.apache.archiva.configuration.IndeterminateConfigurationException; -import org.apache.archiva.configuration.RepositoryScanningConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.ArchivaRuntimeConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.provider.ConfigurationListener; +import org.apache.archiva.configuration.model.FileType; +import org.apache.archiva.configuration.provider.IndeterminateConfigurationException; +import org.apache.archiva.configuration.model.RepositoryScanningConfiguration; import org.apache.commons.lang3.StringUtils; import org.springframework.stereotype.Service; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/ArchivaIndexManagerMock.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/ArchivaIndexManagerMock.java index 0fadd50b3..e10df3148 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/ArchivaIndexManagerMock.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/ArchivaIndexManagerMock.java @@ -21,7 +21,7 @@ package org.apache.archiva.maven.repository.mock; import org.apache.archiva.common.filelock.DefaultFileLockManager; import org.apache.archiva.common.utils.FileUtils; import org.apache.archiva.common.utils.PathUtil; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.indexer.ArchivaIndexManager; import org.apache.archiva.indexer.ArchivaIndexingContext; import org.apache.archiva.indexer.IndexCreationFailedException; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/configuration/MockRepoAdmin.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/configuration/MockRepoAdmin.java index f069d8374..814ca0624 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/configuration/MockRepoAdmin.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/configuration/MockRepoAdmin.java @@ -29,10 +29,10 @@ import org.apache.archiva.admin.model.networkproxy.NetworkProxyAdmin; import org.apache.archiva.admin.model.proxyconnector.ProxyConnectorAdmin; import org.apache.archiva.admin.model.proxyconnector.ProxyConnectorOrderComparator; import org.apache.archiva.admin.model.remote.RemoteRepositoryAdmin; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; import org.apache.commons.lang3.StringUtils; import org.modelmapper.ModelMapper; import org.springframework.stereotype.Service; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/configuration/StubConfiguration.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/configuration/StubConfiguration.java index 474fd4a7b..71416f32b 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/configuration/StubConfiguration.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/configuration/StubConfiguration.java @@ -21,11 +21,11 @@ package org.apache.archiva.maven.repository.mock.configuration; import org.apache.archiva.components.registry.Registry; import org.apache.archiva.components.registry.RegistryException; import org.apache.archiva.components.registry.RegistryListener; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ConfigurationListener; -import org.apache.archiva.configuration.IndeterminateConfigurationException; -import org.apache.archiva.configuration.RepositoryScanningConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.provider.ConfigurationListener; +import org.apache.archiva.configuration.provider.IndeterminateConfigurationException; +import org.apache.archiva.configuration.model.RepositoryScanningConfiguration; import org.apache.commons.lang3.StringUtils; import org.springframework.stereotype.Service; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/configuration/TestConfiguration.java b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/configuration/TestConfiguration.java index d398be9d0..59758f7ea 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/configuration/TestConfiguration.java +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/java/org/apache/archiva/maven/repository/mock/configuration/TestConfiguration.java @@ -3,10 +3,10 @@ package org.apache.archiva.maven.repository.mock.configuration; import org.apache.archiva.components.registry.Registry; import org.apache.archiva.components.registry.RegistryException; import org.apache.archiva.components.registry.RegistryListener; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ConfigurationListener; -import org.apache.archiva.configuration.IndeterminateConfigurationException; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.provider.ConfigurationListener; +import org.apache.archiva.configuration.provider.IndeterminateConfigurationException; import org.apache.commons.lang3.StringUtils; import org.springframework.stereotype.Service; diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/resources/spring-context-repo-request-test.xml b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/resources/spring-context-repo-request-test.xml index 40d036ee4..7c6966d91 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/resources/spring-context-repo-request-test.xml +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/resources/spring-context-repo-request-test.xml @@ -28,7 +28,7 @@ <context:property-placeholder system-properties-mode="OVERRIDE"/> <context:component-scan base-package="org.apache.archiva.maven.repository.content" /> - <bean name="archivaConfiguration#repo-request-test" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#repo-request-test" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#configured"/> </bean> diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/resources/spring-context-storage.xml b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/resources/spring-context-storage.xml index bd9567de8..866d1193b 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/resources/spring-context-storage.xml +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/resources/spring-context-storage.xml @@ -55,7 +55,7 @@ <property name="configuration" ref="archivaConfiguration#default"/> </bean> - <bean name="filetypes" class="org.apache.archiva.configuration.FileTypes"> + <bean name="filetypes" class="org.apache.archiva.configuration.provider.FileTypes"> <property name="archivaConfiguration" ref="archivaConfiguration#default"/> </bean> diff --git a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/resources/spring-context.xml b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/resources/spring-context.xml index 63dc0de2e..f976c3469 100644 --- a/archiva-modules/archiva-maven/archiva-maven-repository/src/test/resources/spring-context.xml +++ b/archiva-modules/archiva-maven/archiva-maven-repository/src/test/resources/spring-context.xml @@ -31,7 +31,7 @@ <context:component-scan base-package="org.apache.archiva.repository,org.apache.archiva.configuration,org.apache.archiva.metadata.repository,org.apache.archiva.maven.repository.mock"/> - <bean name="archivaConfiguration#test" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> </bean> <alias name="archivaConfiguration#test" alias="archivaConfiguration#default"/> <alias name="archivaConfiguration#test" alias="archivaConfiguration"/> @@ -56,7 +56,7 @@ <property name="configuration" ref="archivaConfiguration#default"/> </bean> - <bean name="filetypes" class="org.apache.archiva.configuration.FileTypes"> + <bean name="filetypes" class="org.apache.archiva.configuration.provider.FileTypes"> <property name="archivaConfiguration" ref="archivaConfiguration#default"/> </bean> diff --git a/archiva-modules/archiva-maven/archiva-maven-scheduler/pom.xml b/archiva-modules/archiva-maven/archiva-maven-scheduler/pom.xml index e9f49ec72..d0105b39d 100644 --- a/archiva-modules/archiva-maven/archiva-maven-scheduler/pom.xml +++ b/archiva-modules/archiva-maven/archiva-maven-scheduler/pom.xml @@ -53,8 +53,8 @@ <artifactId>archiva-storage-api</artifactId> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/archiva-maven/archiva-maven-scheduler/src/main/java/org/apache/archiva/maven/scheduler/indexing/DefaultDownloadRemoteIndexScheduler.java b/archiva-modules/archiva-maven/archiva-maven-scheduler/src/main/java/org/apache/archiva/maven/scheduler/indexing/DefaultDownloadRemoteIndexScheduler.java index 7ff7e0869..a5aee2ebe 100644 --- a/archiva-modules/archiva-maven/archiva-maven-scheduler/src/main/java/org/apache/archiva/maven/scheduler/indexing/DefaultDownloadRemoteIndexScheduler.java +++ b/archiva-modules/archiva-maven/archiva-maven-scheduler/src/main/java/org/apache/archiva/maven/scheduler/indexing/DefaultDownloadRemoteIndexScheduler.java @@ -21,9 +21,9 @@ import org.apache.archiva.proxy.ProxyRegistry; import org.apache.archiva.proxy.model.NetworkProxy; import org.apache.archiva.scheduler.indexing.DownloadRemoteIndexException; import org.apache.archiva.scheduler.indexing.DownloadRemoteIndexScheduler; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ConfigurationEvent; -import org.apache.archiva.configuration.ConfigurationListener; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ConfigurationEvent; +import org.apache.archiva.configuration.provider.ConfigurationListener; import org.apache.archiva.indexer.UnsupportedBaseContextException; import org.apache.archiva.maven.common.proxy.WagonFactory; import org.apache.archiva.repository.RepositoryRegistry; diff --git a/archiva-modules/archiva-maven/archiva-maven-scheduler/src/test/resources/spring-context.xml b/archiva-modules/archiva-maven/archiva-maven-scheduler/src/test/resources/spring-context.xml index 3393cdf02..1b759eebb 100644 --- a/archiva-modules/archiva-maven/archiva-maven-scheduler/src/test/resources/spring-context.xml +++ b/archiva-modules/archiva-maven/archiva-maven-scheduler/src/test/resources/spring-context.xml @@ -39,7 +39,7 @@ </bean> <!-- wire up more basic configuration so it doesn't overwrite any config files --> - <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#default"/> </bean> diff --git a/archiva-modules/archiva-scheduler/archiva-scheduler-indexing/pom.xml b/archiva-modules/archiva-scheduler/archiva-scheduler-indexing/pom.xml index 1908333fd..5f086d81b 100644 --- a/archiva-modules/archiva-scheduler/archiva-scheduler-indexing/pom.xml +++ b/archiva-modules/archiva-scheduler/archiva-scheduler-indexing/pom.xml @@ -42,8 +42,8 @@ </dependency> <!-- <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> --> <dependency> diff --git a/archiva-modules/archiva-scheduler/archiva-scheduler-repository-api/pom.xml b/archiva-modules/archiva-scheduler/archiva-scheduler-repository-api/pom.xml index 73e987ece..38227f549 100644 --- a/archiva-modules/archiva-scheduler/archiva-scheduler-repository-api/pom.xml +++ b/archiva-modules/archiva-scheduler/archiva-scheduler-repository-api/pom.xml @@ -71,8 +71,8 @@ --> <!-- <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.slf4j</groupId> diff --git a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/pom.xml b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/pom.xml index 019d52b2d..d14466188 100644 --- a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/pom.xml +++ b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/pom.xml @@ -61,8 +61,8 @@ <artifactId>archiva-model</artifactId> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/main/java/org/apache/archiva/scheduler/repository/DefaultRepositoryArchivaTaskScheduler.java b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/main/java/org/apache/archiva/scheduler/repository/DefaultRepositoryArchivaTaskScheduler.java index da624e214..e11b5369f 100644 --- a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/main/java/org/apache/archiva/scheduler/repository/DefaultRepositoryArchivaTaskScheduler.java +++ b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/main/java/org/apache/archiva/scheduler/repository/DefaultRepositoryArchivaTaskScheduler.java @@ -20,10 +20,10 @@ package org.apache.archiva.scheduler.repository; */ import org.apache.archiva.common.ArchivaException; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ConfigurationEvent; -import org.apache.archiva.configuration.ConfigurationListener; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ConfigurationEvent; +import org.apache.archiva.configuration.provider.ConfigurationListener; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.metadata.repository.MetadataRepository; import org.apache.archiva.metadata.repository.MetadataRepositoryException; import org.apache.archiva.metadata.repository.RepositorySession; diff --git a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/AbstractArchivaRepositoryScanningTaskExecutorTest.java b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/AbstractArchivaRepositoryScanningTaskExecutorTest.java index bbe99bb34..b282a5800 100644 --- a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/AbstractArchivaRepositoryScanningTaskExecutorTest.java +++ b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/AbstractArchivaRepositoryScanningTaskExecutorTest.java @@ -21,8 +21,8 @@ package org.apache.archiva.scheduler.repository; import junit.framework.TestCase; import org.apache.archiva.common.utils.FileUtils; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.metadata.repository.MetadataRepository; import org.apache.archiva.metadata.repository.stats.model.RepositoryStatisticsManager; import org.apache.archiva.mock.MockRepositorySessionFactory; diff --git a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/mock/ArchivaIndexManagerMock.java b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/mock/ArchivaIndexManagerMock.java index 296262d0b..25e5c1a35 100644 --- a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/mock/ArchivaIndexManagerMock.java +++ b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/mock/ArchivaIndexManagerMock.java @@ -21,7 +21,7 @@ package org.apache.archiva.scheduler.repository.mock; import org.apache.archiva.common.filelock.DefaultFileLockManager; import org.apache.archiva.common.utils.FileUtils; import org.apache.archiva.common.utils.PathUtil; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.indexer.ArchivaIndexManager; import org.apache.archiva.indexer.ArchivaIndexingContext; import org.apache.archiva.indexer.IndexCreationFailedException; diff --git a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/mock/MockArchivaAdministration.java b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/mock/MockArchivaAdministration.java index a6894839f..ff7188a68 100644 --- a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/mock/MockArchivaAdministration.java +++ b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/mock/MockArchivaAdministration.java @@ -25,7 +25,7 @@ import org.apache.archiva.admin.model.beans.LegacyArtifactPath; import org.apache.archiva.admin.model.beans.NetworkConfiguration; import org.apache.archiva.admin.model.beans.OrganisationInformation; import org.apache.archiva.admin.model.beans.UiConfiguration; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import java.util.ArrayList; import java.util.List; diff --git a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/mock/MockRemoteRepositoryAdmin.java b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/mock/MockRemoteRepositoryAdmin.java index 4db51d33d..26b85c701 100644 --- a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/mock/MockRemoteRepositoryAdmin.java +++ b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/java/org/apache/archiva/scheduler/repository/mock/MockRemoteRepositoryAdmin.java @@ -21,7 +21,7 @@ import org.apache.archiva.admin.model.AuditInformation; import org.apache.archiva.admin.model.RepositoryAdminException; import org.apache.archiva.admin.model.beans.RemoteRepository; import org.apache.archiva.admin.model.remote.RemoteRepositoryAdmin; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import java.util.List; import java.util.Map; diff --git a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/resources/spring-context.xml b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/resources/spring-context.xml index cdb04cd34..e9b431141 100755 --- a/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/resources/spring-context.xml +++ b/archiva-modules/archiva-scheduler/archiva-scheduler-repository/src/test/resources/spring-context.xml @@ -47,7 +47,7 @@ <alias name="repositoryStatisticsManager#test" alias="repositoryStatisticsManager#default"/> - <bean name="archivaConfiguration#test-repository-scanning" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#test-repository-scanning" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test-configured"/> </bean> diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/pom.xml b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/pom.xml index ac1b0623c..3075d15be 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/pom.xml +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/pom.xml @@ -96,6 +96,10 @@ <groupId>jakarta.annotation</groupId> <artifactId>jakarta.annotation-api</artifactId> </dependency> + <dependency> + <groupId>jakarta.inject</groupId> + <artifactId>jakarta.inject-api</artifactId> + </dependency> <dependency> diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/Artifact.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/Artifact.java index 980bab270..8bde08190 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/Artifact.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/Artifact.java @@ -25,7 +25,7 @@ import java.io.Serializable; * @author Martin Stockhammer <martin_s@apache.org> */ @Schema(name="Artifact", description = "Information about artifacts") -public class Artifact implements Serializable +public class Artifact implements Serializable, RestModel { private static final long serialVersionUID = 7581578317346876555L; private String name; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ArtifactTransferRequest.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ArtifactTransferRequest.java index 5a517786f..f9477b7a5 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ArtifactTransferRequest.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ArtifactTransferRequest.java @@ -24,7 +24,7 @@ import java.io.Serializable; /** * @author Martin Stockhammer <martin_s@apache.org> */ -public class ArtifactTransferRequest implements Serializable +public class ArtifactTransferRequest implements Serializable, RestModel { private static final long serialVersionUID = -7377281345536573342L; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/BeanInformation.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/BeanInformation.java index 0d28a539d..ce8ec07a7 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/BeanInformation.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/BeanInformation.java @@ -45,7 +45,7 @@ import java.util.Objects; */ @XmlRootElement(name="beanInformation") @Schema(name="BeanInformation",description = "Information about a bean instance.") -public class BeanInformation implements Serializable +public class BeanInformation implements Serializable, RestModel { private static final long serialVersionUID = -432385743277355987L; private String id; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/CacheConfiguration.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/CacheConfiguration.java index 1e58a6780..56cbaa2ab 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/CacheConfiguration.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/CacheConfiguration.java @@ -30,7 +30,7 @@ import java.io.Serializable; @XmlRootElement( name = "cacheConfiguration" ) @Schema(name="CacheConfiguration",description = "Cache configuration attributes") public class CacheConfiguration - implements Serializable + implements Serializable, RestModel { private static final long serialVersionUID = 5479989049980673894L; /** diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/FileInfo.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/FileInfo.java index 359d1cbe8..52105d6b2 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/FileInfo.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/FileInfo.java @@ -45,7 +45,7 @@ import java.time.ZoneOffset; * @author Martin Stockhammer <martin_s@apache.org> */ @Schema(name="FileInfo",description = "Information about a file stored in the repository") -public class FileInfo implements Serializable +public class FileInfo implements Serializable, RestModel { private static final long serialVersionUID = 900497784542880195L; private OffsetDateTime modified; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/IndexingTask.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/IndexingTask.java index 42f25cb24..abd0c16da 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/IndexingTask.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/IndexingTask.java @@ -25,7 +25,7 @@ import java.io.Serializable; * @author Martin Stockhammer <martin_s@apache.org> */ @Schema(name="IndexingTask",description = "Information about indexing tasks") -public class IndexingTask implements Serializable +public class IndexingTask implements Serializable, RestModel { private static final long serialVersionUID = -1947200162602613310L; private String repositoryId = ""; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/LdapConfiguration.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/LdapConfiguration.java index 15372cd5a..c93c44818 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/LdapConfiguration.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/LdapConfiguration.java @@ -50,7 +50,7 @@ import java.util.TreeMap; */ @XmlRootElement(name="ldapConfiguration") @Schema(name="LdapConfiguration", description = "LDAP configuration attributes") -public class LdapConfiguration implements Serializable +public class LdapConfiguration implements Serializable, RestModel { private static final long serialVersionUID = -4736767846016398583L; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/MergeConfiguration.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/MergeConfiguration.java index 053e12993..6340a6df4 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/MergeConfiguration.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/MergeConfiguration.java @@ -50,7 +50,7 @@ import static org.apache.archiva.indexer.ArchivaIndexManager.DEFAULT_INDEX_PATH; */ @XmlRootElement(name="mergeConfiguration") @Schema(name="MergeConfiguration", description = "Configuration settings for index merge of remote repositories.") -public class MergeConfiguration implements Serializable +public class MergeConfiguration implements Serializable, RestModel { private static final long serialVersionUID = -3629274059574459133L; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/Repository.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/Repository.java index d0979649f..be5aeebbd 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/Repository.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/Repository.java @@ -46,7 +46,7 @@ import java.util.Locale; * @since 3.0 */ @Schema(description = "Repository data") -public class Repository implements Serializable +public class Repository implements Serializable, RestModel { private static final long serialVersionUID = -4741025877287175182L; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/RepositoryGroup.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/RepositoryGroup.java index 6f64a5191..1572d7cd6 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/RepositoryGroup.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/RepositoryGroup.java @@ -49,7 +49,7 @@ import java.util.stream.Collectors; */ @XmlRootElement(name="repositoryGroup") @Schema(name="RepositoryGroup", description = "Information about a repository group, which combines multiple repositories as one virtual repository.") -public class RepositoryGroup implements Serializable +public class RepositoryGroup implements Serializable, RestModel { private static final long serialVersionUID = -7319687481737616081L; private String id; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/RepositoryStatistics.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/RepositoryStatistics.java index ab2c916f7..bb8afcb6f 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/RepositoryStatistics.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/RepositoryStatistics.java @@ -51,7 +51,7 @@ import java.util.TreeMap; */ @XmlRootElement(name="repositoryStatistics") @Schema(name="RepositoryStatistics", description = "Statistics data") -public class RepositoryStatistics implements Serializable +public class RepositoryStatistics implements Serializable, RestModel { private static final long serialVersionUID = 7943367882738452531L; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/RestModel.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/RestModel.java new file mode 100644 index 000000000..1f063283e --- /dev/null +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/RestModel.java @@ -0,0 +1,26 @@ +package org.apache.archiva.rest.api.v2.model; +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +/** + * Marker interface that represents a model instance for REST services + * @author Martin Schreier <martin_s@apache.org> + */ +public interface RestModel +{ +} diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ScanStatus.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ScanStatus.java index 4e4659487..8023126da 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ScanStatus.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ScanStatus.java @@ -29,7 +29,7 @@ import java.util.stream.Collectors; * @author Martin Stockhammer <martin_s@apache.org> */ @Schema(name="ScanStatus", description = "Status of repository scan tasks") -public class ScanStatus implements Serializable +public class ScanStatus implements Serializable, RestModel { private boolean scanRunning = false; private int scanQueued = 0; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ScanTask.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ScanTask.java index 15e42d8e5..c9efa0108 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ScanTask.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ScanTask.java @@ -26,7 +26,7 @@ import java.io.Serializable; * @author Martin Stockhammer <martin_s@apache.org> */ @Schema(name="ScanTask", description = "Repository scan task information") -public class ScanTask implements Serializable +public class ScanTask implements Serializable, RestModel { private static final long serialVersionUID = -681163357370848098L; private String repositoryId=""; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/SecurityConfiguration.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/SecurityConfiguration.java index a3c062920..b955e139c 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/SecurityConfiguration.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/SecurityConfiguration.java @@ -49,7 +49,7 @@ import java.util.TreeMap; */ @XmlRootElement(name = "securityConfiguration") @Schema(name = "SecurityConfiguration", description = "Security configuration attributes.") -public class SecurityConfiguration implements Serializable +public class SecurityConfiguration implements Serializable, RestModel { private static final long serialVersionUID = -4186866365979053029L; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ValidationError.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ValidationError.java index d8e51cb70..4e741a62a 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ValidationError.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/ValidationError.java @@ -31,7 +31,7 @@ import java.util.stream.Collectors; */ @XmlRootElement(name = "validationError") @Schema(name = "ValidationError", description = "A validation error.") -public class ValidationError implements Serializable +public class ValidationError implements Serializable, RestModel { private static final long serialVersionUID = 2079020598090660171L; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/map/MavenRepositoryMapper.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/map/MavenRepositoryMapper.java new file mode 100644 index 000000000..d95dae4e3 --- /dev/null +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/map/MavenRepositoryMapper.java @@ -0,0 +1,72 @@ +package org.apache.archiva.rest.api.v2.model.map; +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +import org.apache.archiva.common.ModelMapper; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.rest.api.v2.model.MavenManagedRepository; + +/** + * @author Martin Schreier <martin_s@apache.org> + */ +public class MavenRepositoryMapper implements RestMapper<MavenManagedRepository, ManagedRepositoryConfiguration> +{ + @Override + public ManagedRepositoryConfiguration map( MavenManagedRepository source ) + { + return null; + } + + @Override + public void update( MavenManagedRepository source, ManagedRepositoryConfiguration target ) + { + + } + + @Override + public MavenManagedRepository reverseMap( ManagedRepositoryConfiguration target ) + { + return null; + } + + @Override + public void reverseUpdate( ManagedRepositoryConfiguration target, MavenManagedRepository source ) + { + + } + + @Override + public Class<MavenManagedRepository> getSourceType( ) + { + return MavenManagedRepository.class; + } + + @Override + public Class<ManagedRepositoryConfiguration> getTargetType( ) + { + return ManagedRepositoryConfiguration.class; + } + + @Override + public <S, T> boolean supports( Class<S> sourceType, Class<T> targetType ) + { + return ( + sourceType.isAssignableFrom( getSourceType() ) && + targetType.isAssignableFrom( getTargetType() ) ); + } +} diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/map/RestMapper.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/map/RestMapper.java new file mode 100644 index 000000000..36e6ee192 --- /dev/null +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/map/RestMapper.java @@ -0,0 +1,29 @@ +package org.apache.archiva.rest.api.v2.model.map; +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +import org.apache.archiva.common.ModelMapper; +import org.apache.archiva.configuration.model.ConfigurationModel; +import org.apache.archiva.rest.api.v2.model.RestModel; + +/** + * @author Martin Schreier <martin_s@apache.org> + */ +public interface RestMapper<S extends RestModel, T extends ConfigurationModel> extends ModelMapper<S,T> +{ +} diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/map/ServiceMapperFactory.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/map/ServiceMapperFactory.java new file mode 100644 index 000000000..7d9ee87a7 --- /dev/null +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-api/src/main/java/org/apache/archiva/rest/api/v2/model/map/ServiceMapperFactory.java @@ -0,0 +1,76 @@ +package org.apache.archiva.rest.api.v2.model.map; +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +import org.apache.archiva.common.ModelMapper; +import org.apache.archiva.common.ModelMapperFactory; +import org.apache.archiva.configuration.model.ConfigurationModel; +import org.apache.archiva.rest.api.v2.model.RestModel; +import org.springframework.stereotype.Service; + +import javax.annotation.PostConstruct; +import javax.inject.Inject; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * @author Martin Schreier <martin_s@apache.org> + */ +@Service("modelMapperFactory#rest") +public class ServiceMapperFactory implements ModelMapperFactory<RestModel, ConfigurationModel> +{ + @Inject + List<ModelMapper> modelMapperList; + + Map<Class<? extends RestModel>, Map<Class<? extends ConfigurationModel>,ModelMapper<? extends RestModel, ? extends ConfigurationModel>>> modelMap; + + @PostConstruct + void initMapper() { + modelMap = new HashMap<>( ); + for ( ModelMapper<?, ?> mapper : modelMapperList ) + { + if (!mapper.supports( RestModel.class, ConfigurationModel.class )) { + continue; + } + Class<? extends RestModel> sType = (Class<? extends RestModel>) mapper.getSourceType( ); + Class<? extends ConfigurationModel> tType = (Class<? extends ConfigurationModel>) mapper.getTargetType( ); + Map<Class<? extends ConfigurationModel>, ModelMapper<? extends RestModel, ? extends ConfigurationModel>> tMap; + if (modelMap.containsKey( sType )) { + tMap = modelMap.get( sType ); + } else { + tMap = new HashMap<>( ); + } + tMap.put( tType, (ModelMapper<? extends RestModel, ? extends ConfigurationModel>) mapper ); + } + } + + @Override + public <S extends RestModel, T extends ConfigurationModel> ModelMapper<S, T> getMapper( Class<S> sourceType, Class<T> targetType ) throws IllegalArgumentException + { + if (!modelMap.containsKey( sourceType )) { + throw new IllegalArgumentException( "No mapper defined for the given source type "+sourceType ); + } + Map<Class<? extends ConfigurationModel>, ModelMapper<? extends RestModel, ? extends ConfigurationModel>> tMap = modelMap.get( sourceType ); + if ( !tMap.containsKey( targetType ) ) + { + throw new IllegalArgumentException( "No mapper defined for the given target type "+targetType ); + } + return (ModelMapper<S, T>) tMap.get( targetType ); + } +} diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/main/java/org/apache/archiva/rest/v2/svc/DefaultRepositoryGroupService.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/main/java/org/apache/archiva/rest/v2/svc/DefaultRepositoryGroupService.java index ede4fbb46..5a681ff54 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/main/java/org/apache/archiva/rest/v2/svc/DefaultRepositoryGroupService.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/main/java/org/apache/archiva/rest/v2/svc/DefaultRepositoryGroupService.java @@ -36,7 +36,7 @@ package org.apache.archiva.rest.v2.svc;/* import org.apache.archiva.components.rest.model.PagedResult; import org.apache.archiva.components.rest.util.QueryHelper; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.repository.EditableRepositoryGroup; import org.apache.archiva.repository.RepositoryException; import org.apache.archiva.repository.RepositoryRegistry; diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/main/java/org/apache/archiva/rest/v2/svc/maven/DefaultMavenManagedRepositoryService.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/main/java/org/apache/archiva/rest/v2/svc/maven/DefaultMavenManagedRepositoryService.java index 498000f61..f62fef2e0 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/main/java/org/apache/archiva/rest/v2/svc/maven/DefaultMavenManagedRepositoryService.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/main/java/org/apache/archiva/rest/v2/svc/maven/DefaultMavenManagedRepositoryService.java @@ -22,6 +22,7 @@ import org.apache.archiva.admin.model.RepositoryAdminException; import org.apache.archiva.admin.model.managed.ManagedRepositoryAdmin; import org.apache.archiva.components.rest.model.PagedResult; import org.apache.archiva.components.rest.util.QueryHelper; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.redback.authentication.AuthenticationResult; import org.apache.archiva.redback.authorization.AuthorizationException; import org.apache.archiva.redback.rest.services.RedbackAuthenticationThreadLocal; @@ -121,6 +122,12 @@ public class DefaultMavenManagedRepositoryService implements MavenManagedReposit return new AuditInformation( user, remoteAddr ); } + public static ManagedRepositoryConfiguration toConfig(MavenManagedRepository repo) { + ManagedRepositoryConfiguration cfg = new ManagedRepositoryConfiguration( ); + return cfg; + + } + @Override public PagedResult<MavenManagedRepository> getManagedRepositories( final String searchTerm, final Integer offset, final Integer limit, final List<String> orderBy, @@ -188,7 +195,10 @@ public class DefaultMavenManagedRepositoryService implements MavenManagedReposit repoBean.setDeleteReleasedSnapshots( repository.isDeleteSnapshotsOfRelease() ); repoBean.setSkipPackedIndexCreation( repository.isSkipPackedIndexCreation() ); repoBean.setRetentionCount( repository.getRetentionCount() ); - repoBean.setRetentionPeriod( repository.getRetentionPeriod().getDays() ); + if (repository.getRetentionPeriod()!=null) + { + repoBean.setRetentionPeriod( repository.getRetentionPeriod( ).getDays( ) ); + } repoBean.setIndexDirectory( repository.getIndexPath() ); repoBean.setPackedIndexDirectory( repository.getPackedIndexPath() ); repoBean.setLayout( repository.getLayout() ); diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/java/org/apache/archiva/rest/v2/svc/maven/NativeMavenManagedRepositoryServiceTest.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/java/org/apache/archiva/rest/v2/svc/maven/NativeMavenManagedRepositoryServiceTest.java index 9a8f932be..3dffabed1 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/java/org/apache/archiva/rest/v2/svc/maven/NativeMavenManagedRepositoryServiceTest.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/java/org/apache/archiva/rest/v2/svc/maven/NativeMavenManagedRepositoryServiceTest.java @@ -25,6 +25,7 @@ import org.apache.archiva.rest.api.v2.svc.RestConfiguration; import org.apache.archiva.rest.v2.svc.AbstractNativeRestServices; import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.BeforeAll; +import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.MethodOrderer; import org.junit.jupiter.api.Order; @@ -33,7 +34,9 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.api.TestInstance; import org.junit.jupiter.api.TestMethodOrder; +import java.util.HashMap; import java.util.List; +import java.util.Map; import static io.restassured.RestAssured.given; import static io.restassured.http.ContentType.JSON; @@ -84,6 +87,34 @@ public class NativeMavenManagedRepositoryServiceTest extends AbstractNativeRestS assertEquals( "snapshots", repositories.get( 1 ).getId( ) ); } + private Response createRepository(String id, String name, String description, String token) { + Map<String, Object> jsonAsMap = new HashMap<>( ); + jsonAsMap.put( "id", id ); + jsonAsMap.put( "name", name ); + jsonAsMap.put( "description", description ); + return given( ).spec( getRequestSpec( token ) ).contentType( JSON ) + .when( ) + .body( jsonAsMap ) + .post( "" ) + .then( ).statusCode( 201 ).extract( ).response( ); + } + + + @Disabled + @Test + @Order( 2 ) + void testCreateRepository() { + String token = getAdminToken( ); + Response response = createRepository( "repo001", "Repository 001", "This is repository 001", token ); + assertNotNull( response ); + JsonPath json = response.getBody( ).jsonPath( ); + assertNotNull( json ); + assertEquals( "repo001", json.get( "id" ) ); + assertEquals( "Repository 001", json.get( "name" ) ); + assertEquals( "maven", json.get( "type" ) ); + assertEquals( "This is repository 001", json.get( "description" ) ); + } + } diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/resources/META-INF/spring-context-native-test.xml b/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/resources/META-INF/spring-context-native-test.xml index 79379ad65..226af8424 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/resources/META-INF/spring-context-native-test.xml +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/resources/META-INF/spring-context-native-test.xml @@ -47,7 +47,7 @@ </bean> <!-- wire up more basic configuration so it doesn't overwrite any config files --> - <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#default"/> </bean> diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/resources/META-INF/spring-context-test.xml b/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/resources/META-INF/spring-context-test.xml index 19eba026f..4f3750ccb 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/resources/META-INF/spring-context-test.xml +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/test/resources/META-INF/spring-context-test.xml @@ -47,7 +47,7 @@ </bean> <!-- wire up more basic configuration so it doesn't overwrite any config files --> - <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#default"/> </bean> diff --git a/archiva-modules/archiva-web/archiva-security/pom.xml b/archiva-modules/archiva-web/archiva-security/pom.xml index d2484a08e..f5f9bce4a 100644 --- a/archiva-modules/archiva-web/archiva-security/pom.xml +++ b/archiva-modules/archiva-web/archiva-security/pom.xml @@ -33,8 +33,8 @@ <dependencies> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/archiva-web/archiva-security/src/test/java/org/apache/archiva/security/AbstractSecurityTest.java b/archiva-modules/archiva-web/archiva-security/src/test/java/org/apache/archiva/security/AbstractSecurityTest.java index 550745d20..06debd40f 100644 --- a/archiva-modules/archiva-web/archiva-security/src/test/java/org/apache/archiva/security/AbstractSecurityTest.java +++ b/archiva-modules/archiva-web/archiva-security/src/test/java/org/apache/archiva/security/AbstractSecurityTest.java @@ -20,8 +20,8 @@ package org.apache.archiva.security; */ import junit.framework.TestCase; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.redback.rbac.RBACManager; import org.apache.archiva.redback.rbac.RbacObjectNotFoundException; import org.apache.archiva.redback.rbac.UserAssignment; diff --git a/archiva-modules/archiva-web/archiva-security/src/test/resources/spring-context.xml b/archiva-modules/archiva-web/archiva-security/src/test/resources/spring-context.xml index c94f9c6d5..22793a3fb 100644 --- a/archiva-modules/archiva-web/archiva-security/src/test/resources/spring-context.xml +++ b/archiva-modules/archiva-web/archiva-security/src/test/resources/spring-context.xml @@ -79,7 +79,7 @@ <alias name="servletAuthenticator" alias="servletAuthenticator#test"/> - <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#test"/> </bean> <alias name="archivaConfiguration#default" alias="archivaConfiguration"/> diff --git a/archiva-modules/archiva-web/archiva-web-common/pom.xml b/archiva-modules/archiva-web/archiva-web-common/pom.xml index cd16ed653..dc73e13a5 100644 --- a/archiva-modules/archiva-web/archiva-web-common/pom.xml +++ b/archiva-modules/archiva-web/archiva-web-common/pom.xml @@ -40,8 +40,8 @@ <artifactId>metadata-repository-api</artifactId> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/api/DefaultFileUploadService.java b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/api/DefaultFileUploadService.java index 72df50cf5..8c85c97e4 100644 --- a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/api/DefaultFileUploadService.java +++ b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/api/DefaultFileUploadService.java @@ -26,7 +26,7 @@ import org.apache.archiva.checksum.ChecksummedFile; import org.apache.archiva.common.utils.VersionComparator; import org.apache.archiva.common.utils.VersionUtil; import org.apache.archiva.components.taskqueue.TaskQueueException; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.metadata.model.facets.AuditEvent; import org.apache.archiva.model.ArchivaRepositoryMetadata; import org.apache.archiva.model.SnapshotVersion; diff --git a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/startup/SecuritySynchronization.java b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/startup/SecuritySynchronization.java index dc0d2e882..9e255a63c 100644 --- a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/startup/SecuritySynchronization.java +++ b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/startup/SecuritySynchronization.java @@ -20,9 +20,9 @@ package org.apache.archiva.web.startup; */ import org.apache.archiva.common.ArchivaException; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ConfigurationNames; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.ConfigurationNames; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.components.registry.RegistryListener; import org.apache.archiva.redback.rbac.RBACManager; import org.apache.archiva.redback.rbac.RbacManagerException; diff --git a/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/web/rss/RssFeedServletTest.java b/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/web/rss/RssFeedServletTest.java index 746c5ec82..0dfd1d957 100644 --- a/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/web/rss/RssFeedServletTest.java +++ b/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/web/rss/RssFeedServletTest.java @@ -22,7 +22,7 @@ package org.apache.archiva.web.rss; import junit.framework.TestCase; import org.apache.archiva.common.filelock.DefaultFileLockManager; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.repository.base.managed.BasicManagedRepository; import org.apache.archiva.repository.RepositoryRegistry; import org.apache.archiva.repository.storage.fs.FilesystemStorage; diff --git a/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/web/upload/UploadArtifactsTest.java b/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/web/upload/UploadArtifactsTest.java index 0487368db..a8b23cd7d 100644 --- a/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/web/upload/UploadArtifactsTest.java +++ b/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/web/upload/UploadArtifactsTest.java @@ -18,7 +18,7 @@ package org.apache.archiva.web.upload; */ import com.fasterxml.jackson.jaxrs.json.JacksonJaxbJsonProvider; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.rest.api.services.ArchivaRestServiceException; import org.apache.archiva.test.utils.ArchivaBlockJUnit4ClassRunner; import org.apache.archiva.web.AbstractRestServicesTest; diff --git a/archiva-modules/archiva-web/archiva-web-common/src/test/resources/spring-context-rss-servlet.xml b/archiva-modules/archiva-web/archiva-web-common/src/test/resources/spring-context-rss-servlet.xml index ae84b9697..7ec43de90 100644 --- a/archiva-modules/archiva-web/archiva-web-common/src/test/resources/spring-context-rss-servlet.xml +++ b/archiva-modules/archiva-web/archiva-web-common/src/test/resources/spring-context-rss-servlet.xml @@ -43,7 +43,7 @@ <alias name="securitySystem#test" alias="securitySystem"/> - <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#default"/> </bean> diff --git a/archiva-modules/archiva-web/archiva-web-common/src/test/resources/spring-context-test-common.xml b/archiva-modules/archiva-web/archiva-web-common/src/test/resources/spring-context-test-common.xml index 5bbaa7f22..dd98b2f93 100644 --- a/archiva-modules/archiva-web/archiva-web-common/src/test/resources/spring-context-test-common.xml +++ b/archiva-modules/archiva-web/archiva-web-common/src/test/resources/spring-context-test-common.xml @@ -44,7 +44,7 @@ </bean> <!-- wire up more basic configuration so it doesn't overwrite any config files --> - <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#default"/> </bean> diff --git a/archiva-modules/archiva-web/archiva-web-common/src/test/resources/spring-context-test-upload.xml b/archiva-modules/archiva-web/archiva-web-common/src/test/resources/spring-context-test-upload.xml index fb1d5213d..ee24fb4f0 100644 --- a/archiva-modules/archiva-web/archiva-web-common/src/test/resources/spring-context-test-upload.xml +++ b/archiva-modules/archiva-web/archiva-web-common/src/test/resources/spring-context-test-upload.xml @@ -46,7 +46,7 @@ </bean> <!-- wire up more basic configuration so it doesn't overwrite any config files --> - <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#default"/> </bean> diff --git a/archiva-modules/archiva-web/archiva-webapp/pom.xml b/archiva-modules/archiva-web/archiva-webapp/pom.xml index c2a2a94bb..1418bec90 100644 --- a/archiva-modules/archiva-web/archiva-webapp/pom.xml +++ b/archiva-modules/archiva-web/archiva-webapp/pom.xml @@ -283,8 +283,8 @@ <scope>runtime</scope> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> <scope>runtime</scope> </dependency> <dependency> diff --git a/archiva-modules/archiva-web/archiva-webdav/pom.xml b/archiva-modules/archiva-web/archiva-webdav/pom.xml index 8bb9fbb2f..8efc940c7 100644 --- a/archiva-modules/archiva-web/archiva-webdav/pom.xml +++ b/archiva-modules/archiva-web/archiva-webdav/pom.xml @@ -53,8 +53,8 @@ <artifactId>archiva-repository-scanner</artifactId> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> <!-- should be runtime but currently not possible due ConfigurationListener <scope>runtime</scope> --> diff --git a/archiva-modules/archiva-web/archiva-webdav/src/main/java/org/apache/archiva/webdav/ArchivaDavResourceFactory.java b/archiva-modules/archiva-web/archiva-webdav/src/main/java/org/apache/archiva/webdav/ArchivaDavResourceFactory.java index f3e8737e8..ec79dd5e1 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/main/java/org/apache/archiva/webdav/ArchivaDavResourceFactory.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/main/java/org/apache/archiva/webdav/ArchivaDavResourceFactory.java @@ -29,7 +29,7 @@ import org.apache.archiva.common.filelock.DefaultFileLockManager; import org.apache.archiva.common.filelock.FileLockManager; import org.apache.archiva.common.utils.PathUtil; import org.apache.archiva.common.utils.VersionUtil; -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.indexer.ArchivaIndexingContext; import org.apache.archiva.indexer.merger.IndexMerger; import org.apache.archiva.indexer.merger.IndexMergerException; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/main/java/org/apache/archiva/webdav/RepositoryServlet.java b/archiva-modules/archiva-web/archiva-webdav/src/main/java/org/apache/archiva/webdav/RepositoryServlet.java index ba7517fd8..763eb2454 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/main/java/org/apache/archiva/webdav/RepositoryServlet.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/main/java/org/apache/archiva/webdav/RepositoryServlet.java @@ -20,9 +20,9 @@ package org.apache.archiva.webdav; */ import org.apache.archiva.admin.model.RepositoryAdminException; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ConfigurationEvent; -import org.apache.archiva.configuration.ConfigurationListener; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ConfigurationEvent; +import org.apache.archiva.configuration.provider.ConfigurationListener; import org.apache.archiva.redback.integration.filter.authentication.HttpAuthenticator; import org.apache.archiva.repository.base.ArchivaRepositoryRegistry; import org.apache.archiva.repository.ManagedRepository; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/AbstractRepositoryServletProxiedTestCase.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/AbstractRepositoryServletProxiedTestCase.java index 3637bc40a..90605f526 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/AbstractRepositoryServletProxiedTestCase.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/AbstractRepositoryServletProxiedTestCase.java @@ -22,8 +22,8 @@ package org.apache.archiva.webdav; import com.gargoylesoftware.htmlunit.WebClient; import org.apache.archiva.common.utils.FileUtils; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; import org.apache.archiva.policies.*; import org.apache.commons.lang3.StringUtils; import org.eclipse.jetty.server.HttpConnectionFactory; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/AbstractRepositoryServletTestCase.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/AbstractRepositoryServletTestCase.java index dd699581d..adf584694 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/AbstractRepositoryServletTestCase.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/AbstractRepositoryServletTestCase.java @@ -25,10 +25,10 @@ import com.gargoylesoftware.htmlunit.WebClient; import com.gargoylesoftware.htmlunit.WebRequest; import com.gargoylesoftware.htmlunit.WebResponse; import junit.framework.TestCase; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RemoteRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RemoteRepositoryConfiguration; import org.apache.archiva.repository.ManagedRepository; import org.apache.archiva.repository.RepositoryException; import org.apache.archiva.repository.base.ArchivaRepositoryRegistry; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/ArchivaDavResourceFactoryTest.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/ArchivaDavResourceFactoryTest.java index 3650a9704..1afc78425 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/ArchivaDavResourceFactoryTest.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/ArchivaDavResourceFactoryTest.java @@ -28,10 +28,10 @@ import org.apache.archiva.admin.repository.DefaultRepositoryCommonValidator; import org.apache.archiva.admin.repository.group.DefaultRepositoryGroupAdmin; import org.apache.archiva.admin.repository.managed.DefaultManagedRepositoryAdmin; import org.apache.archiva.common.filelock.FileLockManager; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.FileTypes; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.provider.FileTypes; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.metadata.repository.storage.RepositoryPathTranslator; import org.apache.archiva.proxy.ProxyRegistry; import org.apache.archiva.repository.EditableManagedRepository; @@ -60,7 +60,6 @@ import org.junit.After; import org.junit.Before; import org.junit.Test; import org.junit.runner.RunWith; -import org.mockito.Mockito; import org.springframework.beans.factory.config.ConfigurableListableBeanFactory; import org.springframework.context.ApplicationContext; import org.springframework.context.ConfigurableApplicationContext; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletDeployTest.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletDeployTest.java index e29190aac..20ee8ec72 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletDeployTest.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletDeployTest.java @@ -21,7 +21,7 @@ package org.apache.archiva.webdav; import com.gargoylesoftware.htmlunit.WebRequest; import com.gargoylesoftware.htmlunit.WebResponse; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.webdav.mock.httpunit.MkColMethodWebRequest; import org.junit.After; import org.junit.Before; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletNoProxyTest.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletNoProxyTest.java index a532de1a6..d45fbc2cc 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletNoProxyTest.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletNoProxyTest.java @@ -22,7 +22,7 @@ package org.apache.archiva.webdav; import com.gargoylesoftware.htmlunit.WebRequest; import com.gargoylesoftware.htmlunit.WebResponse; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; import org.junit.After; import org.junit.Before; import org.junit.Test; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedPluginSnapshotPolicyTest.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedPluginSnapshotPolicyTest.java index 67d112f11..6a2eaacfa 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedPluginSnapshotPolicyTest.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedPluginSnapshotPolicyTest.java @@ -22,7 +22,7 @@ package org.apache.archiva.webdav; import com.gargoylesoftware.htmlunit.WebRequest; import com.gargoylesoftware.htmlunit.WebResponse; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; import org.apache.archiva.policies.PolicyOption; import org.apache.archiva.policies.SnapshotsPolicy; import org.junit.Test; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedReleasePolicyTest.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedReleasePolicyTest.java index 25643a03b..6b05673bb 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedReleasePolicyTest.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedReleasePolicyTest.java @@ -21,7 +21,7 @@ package org.apache.archiva.webdav; import com.gargoylesoftware.htmlunit.WebRequest; import com.gargoylesoftware.htmlunit.WebResponse; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; import org.apache.archiva.policies.PolicyOption; import org.apache.archiva.policies.ReleasesPolicy; import org.junit.Test; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedSnapshotPolicyTest.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedSnapshotPolicyTest.java index 67e50880f..3f5697d51 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedSnapshotPolicyTest.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedSnapshotPolicyTest.java @@ -21,8 +21,8 @@ package org.apache.archiva.webdav; import com.gargoylesoftware.htmlunit.WebRequest; import com.gargoylesoftware.htmlunit.WebResponse; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; import org.apache.archiva.policies.PolicyOption; import org.apache.archiva.policies.SnapshotsPolicy; import org.junit.After; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedTimestampedSnapshotPolicyTest.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedTimestampedSnapshotPolicyTest.java index 58fe15b46..3f968a658 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedTimestampedSnapshotPolicyTest.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletProxiedTimestampedSnapshotPolicyTest.java @@ -21,7 +21,7 @@ package org.apache.archiva.webdav; import com.gargoylesoftware.htmlunit.WebRequest; import com.gargoylesoftware.htmlunit.WebResponse; -import org.apache.archiva.configuration.ProxyConnectorConfiguration; +import org.apache.archiva.configuration.model.ProxyConnectorConfiguration; import org.apache.archiva.policies.PolicyOption; import org.apache.archiva.policies.SnapshotsPolicy; import org.junit.After; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletRepositoryGroupTest.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletRepositoryGroupTest.java index 8ec608b2f..62af4e4e5 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletRepositoryGroupTest.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletRepositoryGroupTest.java @@ -23,9 +23,9 @@ package org.apache.archiva.webdav; import com.gargoylesoftware.htmlunit.WebRequest; import com.gargoylesoftware.htmlunit.WebResponse; import org.apache.archiva.common.utils.FileUtils; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; -import org.apache.archiva.configuration.RepositoryGroupConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.RepositoryGroupConfiguration; import org.apache.archiva.maven.metadata.MavenMetadataReader; import org.apache.archiva.model.ArchivaRepositoryMetadata; import org.apache.commons.lang3.StringUtils; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletSecurityTest.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletSecurityTest.java index 48ce7f04b..465a4028d 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletSecurityTest.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletSecurityTest.java @@ -21,9 +21,9 @@ package org.apache.archiva.webdav; import junit.framework.TestCase; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.redback.authentication.AuthenticationException; import org.apache.archiva.redback.authentication.AuthenticationResult; import org.apache.archiva.redback.authorization.UnauthorizedException; @@ -47,7 +47,6 @@ import org.junit.Before; import org.junit.Rule; import org.junit.Test; import org.junit.runner.RunWith; -import org.mockito.Mockito; import org.springframework.context.ApplicationContext; import org.springframework.mock.web.MockHttpServletRequest; import org.springframework.mock.web.MockHttpServletResponse; @@ -58,9 +57,7 @@ import org.springframework.web.context.WebApplicationContext; import javax.inject.Inject; import javax.servlet.ServletContext; -import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; -import javax.servlet.http.HttpSession; import java.io.InputStream; import java.nio.charset.Charset; import java.nio.file.Files; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletTest.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletTest.java index 909d9c7c5..5682c0b44 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletTest.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/RepositoryServletTest.java @@ -21,9 +21,9 @@ package org.apache.archiva.webdav; import com.gargoylesoftware.htmlunit.WebRequest; import com.gargoylesoftware.htmlunit.WebResponse; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.repository.ManagedRepository; import org.junit.Before; import org.junit.Test; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/UnauthenticatedDavResourceFactory.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/UnauthenticatedDavResourceFactory.java index 5aadd4653..4dfaed64d 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/UnauthenticatedDavResourceFactory.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/UnauthenticatedDavResourceFactory.java @@ -19,7 +19,7 @@ package org.apache.archiva.webdav; * under the License. */ -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.jackrabbit.webdav.DavException; import org.apache.jackrabbit.webdav.DavServletRequest; import org.springframework.context.ApplicationContext; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/util/ReinitServlet.java b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/util/ReinitServlet.java index 781df5998..c3a4f909a 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/util/ReinitServlet.java +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/java/org/apache/archiva/webdav/util/ReinitServlet.java @@ -19,7 +19,7 @@ package org.apache.archiva.webdav.util; * under the License. */ -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.springframework.context.ApplicationContext; import org.springframework.web.context.support.WebApplicationContextUtils; diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/resources/repository-servlet-simple.xml b/archiva-modules/archiva-web/archiva-webdav/src/test/resources/repository-servlet-simple.xml index 59545f71a..09ecbacb0 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/resources/repository-servlet-simple.xml +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/resources/repository-servlet-simple.xml @@ -31,7 +31,7 @@ <context:annotation-config/> <context:component-scan base-package="org.apache.archiva.webdav.util,org.apache.archiva.common.plexusbridge"/> - <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#default"/> </bean> diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/resources/spring-context-servlet-security-test.xml b/archiva-modules/archiva-web/archiva-webdav/src/test/resources/spring-context-servlet-security-test.xml index 9714ece35..450ceef4a 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/resources/spring-context-servlet-security-test.xml +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/resources/spring-context-servlet-security-test.xml @@ -47,7 +47,7 @@ <bean name="servletAuthenticator" class="org.apache.archiva.webdav.MockServletAuthenticator"/> - <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#default"/> </bean> diff --git a/archiva-modules/archiva-web/archiva-webdav/src/test/resources/spring-context.xml b/archiva-modules/archiva-web/archiva-webdav/src/test/resources/spring-context.xml index c54f37936..1aba2f9f2 100644 --- a/archiva-modules/archiva-web/archiva-webdav/src/test/resources/spring-context.xml +++ b/archiva-modules/archiva-web/archiva-webdav/src/test/resources/spring-context.xml @@ -46,7 +46,7 @@ <bean name="servletAuthenticator" class="org.apache.archiva.webdav.MockServletAuthenticator"/> - <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.DefaultArchivaConfiguration"> + <bean name="archivaConfiguration#default" class="org.apache.archiva.configuration.provider.DefaultArchivaConfiguration"> <property name="registry" ref="registry#default"/> </bean> diff --git a/archiva-modules/metadata/metadata-store-provider/metadata-store-cassandra/pom.xml b/archiva-modules/metadata/metadata-store-provider/metadata-store-cassandra/pom.xml index c5be4d834..0bd365661 100644 --- a/archiva-modules/metadata/metadata-store-provider/metadata-store-cassandra/pom.xml +++ b/archiva-modules/metadata/metadata-store-provider/metadata-store-cassandra/pom.xml @@ -55,8 +55,8 @@ <artifactId>archiva-common</artifactId> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/metadata/metadata-store-provider/metadata-store-cassandra/src/main/java/org/apache/archiva/metadata/repository/cassandra/CassandraRepositorySessionFactory.java b/archiva-modules/metadata/metadata-store-provider/metadata-store-cassandra/src/main/java/org/apache/archiva/metadata/repository/cassandra/CassandraRepositorySessionFactory.java index 2f3077b3c..1790ce01f 100644 --- a/archiva-modules/metadata/metadata-store-provider/metadata-store-cassandra/src/main/java/org/apache/archiva/metadata/repository/cassandra/CassandraRepositorySessionFactory.java +++ b/archiva-modules/metadata/metadata-store-provider/metadata-store-cassandra/src/main/java/org/apache/archiva/metadata/repository/cassandra/CassandraRepositorySessionFactory.java @@ -19,7 +19,7 @@ package org.apache.archiva.metadata.repository.cassandra; * under the License. */ -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.metadata.repository.AbstractRepositorySessionFactory; import org.apache.archiva.metadata.repository.MetadataRepositoryException; import org.apache.archiva.metadata.repository.MetadataResolver; diff --git a/archiva-modules/metadata/metadata-store-provider/metadata-store-file/pom.xml b/archiva-modules/metadata/metadata-store-provider/metadata-store-file/pom.xml index 1ecb1ac4e..ea561448a 100644 --- a/archiva-modules/metadata/metadata-store-provider/metadata-store-file/pom.xml +++ b/archiva-modules/metadata/metadata-store-provider/metadata-store-file/pom.xml @@ -34,8 +34,8 @@ <dependencies> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/metadata/metadata-store-provider/metadata-store-file/src/main/java/org/apache/archiva/metadata/repository/file/FileMetadataRepository.java b/archiva-modules/metadata/metadata-store-provider/metadata-store-file/src/main/java/org/apache/archiva/metadata/repository/file/FileMetadataRepository.java index 00e68c118..3cc3d2451 100644 --- a/archiva-modules/metadata/metadata-store-provider/metadata-store-file/src/main/java/org/apache/archiva/metadata/repository/file/FileMetadataRepository.java +++ b/archiva-modules/metadata/metadata-store-provider/metadata-store-file/src/main/java/org/apache/archiva/metadata/repository/file/FileMetadataRepository.java @@ -20,8 +20,8 @@ package org.apache.archiva.metadata.repository.file; */ import org.apache.archiva.checksum.ChecksumAlgorithm; -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.metadata.QueryParameter; import org.apache.archiva.metadata.model.ArtifactMetadata; import org.apache.archiva.metadata.model.CiManagement; diff --git a/archiva-modules/metadata/metadata-store-provider/metadata-store-file/src/main/java/org/apache/archiva/metadata/repository/file/FileRepositorySessionFactory.java b/archiva-modules/metadata/metadata-store-provider/metadata-store-file/src/main/java/org/apache/archiva/metadata/repository/file/FileRepositorySessionFactory.java index 911dea071..717f68409 100644 --- a/archiva-modules/metadata/metadata-store-provider/metadata-store-file/src/main/java/org/apache/archiva/metadata/repository/file/FileRepositorySessionFactory.java +++ b/archiva-modules/metadata/metadata-store-provider/metadata-store-file/src/main/java/org/apache/archiva/metadata/repository/file/FileRepositorySessionFactory.java @@ -19,7 +19,7 @@ package org.apache.archiva.metadata.repository.file; * under the License. */ -import org.apache.archiva.configuration.ArchivaConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; import org.apache.archiva.metadata.model.MetadataFacetFactory; import org.apache.archiva.metadata.repository.AbstractRepositorySessionFactory; import org.apache.archiva.metadata.repository.MetadataRepository; diff --git a/archiva-modules/metadata/metadata-store-provider/metadata-store-file/src/test/java/org/apache/archiva/metadata/repository/file/FileMetadataRepositoryTest.java b/archiva-modules/metadata/metadata-store-provider/metadata-store-file/src/test/java/org/apache/archiva/metadata/repository/file/FileMetadataRepositoryTest.java index 4fd4bab26..0246b2ee8 100644 --- a/archiva-modules/metadata/metadata-store-provider/metadata-store-file/src/test/java/org/apache/archiva/metadata/repository/file/FileMetadataRepositoryTest.java +++ b/archiva-modules/metadata/metadata-store-provider/metadata-store-file/src/test/java/org/apache/archiva/metadata/repository/file/FileMetadataRepositoryTest.java @@ -19,9 +19,9 @@ package org.apache.archiva.metadata.repository.file; * under the License. */ -import org.apache.archiva.configuration.ArchivaConfiguration; -import org.apache.archiva.configuration.Configuration; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.provider.ArchivaConfiguration; +import org.apache.archiva.configuration.model.Configuration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.metadata.model.MetadataFacetFactory; import org.apache.archiva.metadata.repository.AbstractMetadataRepositoryTest; import org.apache.archiva.metadata.repository.MetadataRepository; diff --git a/archiva-modules/metadata/metadata-store-provider/oak-jcr/oak-jcr-lucene/pom.xml b/archiva-modules/metadata/metadata-store-provider/oak-jcr/oak-jcr-lucene/pom.xml index 06f38aa5a..961fe0d16 100644 --- a/archiva-modules/metadata/metadata-store-provider/oak-jcr/oak-jcr-lucene/pom.xml +++ b/archiva-modules/metadata/metadata-store-provider/oak-jcr/oak-jcr-lucene/pom.xml @@ -176,10 +176,6 @@ <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> - <configuration> - <source>${jdk.version}</source> - <target>${jdk.version}</target> - </configuration> </plugin> <!-- Maven Shade Plugin --> diff --git a/archiva-modules/plugins/audit/pom.xml b/archiva-modules/plugins/audit/pom.xml index af5c0b949..aea14fc96 100644 --- a/archiva-modules/plugins/audit/pom.xml +++ b/archiva-modules/plugins/audit/pom.xml @@ -33,8 +33,8 @@ <dependencies> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/plugins/audit/src/test/java/org/apache/archiva/audit/AuditManagerTest.java b/archiva-modules/plugins/audit/src/test/java/org/apache/archiva/audit/AuditManagerTest.java index f0cb5d2cc..8209c5060 100644 --- a/archiva-modules/plugins/audit/src/test/java/org/apache/archiva/audit/AuditManagerTest.java +++ b/archiva-modules/plugins/audit/src/test/java/org/apache/archiva/audit/AuditManagerTest.java @@ -20,7 +20,7 @@ package org.apache.archiva.audit; */ import junit.framework.TestCase; -import org.apache.archiva.configuration.ManagedRepositoryConfiguration; +import org.apache.archiva.configuration.model.ManagedRepositoryConfiguration; import org.apache.archiva.metadata.model.facets.AuditEvent; import org.apache.archiva.metadata.repository.MetadataRepository; import org.apache.archiva.metadata.repository.RepositorySession; diff --git a/archiva-modules/plugins/problem-reports/pom.xml b/archiva-modules/plugins/problem-reports/pom.xml index 3da850155..8b30065c0 100644 --- a/archiva-modules/plugins/problem-reports/pom.xml +++ b/archiva-modules/plugins/problem-reports/pom.xml @@ -38,8 +38,8 @@ </dependency> <!-- FIXME this deps must be removed --> <dependency> - <groupId>org.apache.archiva</groupId> - <artifactId>archiva-configuration</artifactId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> </dependency> <dependency> <groupId>org.apache.archiva</groupId> diff --git a/archiva-modules/plugins/problem-reports/src/main/java/org/apache/archiva/reports/consumers/DuplicateArtifactsConsumer.java b/archiva-modules/plugins/problem-reports/src/main/java/org/apache/archiva/reports/consumers/DuplicateArtifactsConsumer.java index 0e167a523..cd9c6cbf3 100644 --- a/archiva-modules/plugins/problem-reports/src/main/java/org/apache/archiva/reports/consumers/DuplicateArtifactsConsumer.java +++ b/archiva-modules/plugins/problem-reports/src/main/java/org/apache/archiva/reports/consumers/DuplicateArtifactsConsumer.java @@ -21,7 +21,7 @@ package org.apache.archiva.reports.consumers; import org.apache.archiva.checksum.ChecksumAlgorithm; import org.apache.archiva.checksum.ChecksummedFile; -import org.apache.archiva.configuration.FileTypes; +import org.apache.archiva.configuration.provider.FileTypes; import org.apache.archiva.consumers.AbstractMonitoredConsumer; import org.apache.archiva.consumers.ConsumerException; import org.apache.archiva.consumers.KnownRepositoryContentConsumer; @@ -344,7 +344,17 @@ <version>${project.version}</version> </dependency> <dependency> - <groupId>org.apache.archiva</groupId> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-model</artifactId> + <version>${project.version}</version> + </dependency> + <dependency> + <groupId>org.apache.archiva.configuration</groupId> + <artifactId>archiva-configuration-provider</artifactId> + <version>${project.version}</version> + </dependency> + <dependency> + <groupId>org.apache.archiva.configuration</groupId> <artifactId>archiva-configuration</artifactId> <version>${project.version}</version> </dependency> |