-
Notifications
You must be signed in to change notification settings - Fork 27
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9b0062a
commit 7d9cd23
Showing
153 changed files
with
6,464 additions
and
2 deletions.
There are no files selected for viewing
Submodule manager
deleted from
4a687d
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<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"> | ||
<modelVersion>4.0.0</modelVersion> | ||
<parent> | ||
<groupId>org.jboss.forge.furnace</groupId> | ||
<artifactId>furnace-manager-parent</artifactId> | ||
<version>2.0.0-SNAPSHOT</version> | ||
</parent> | ||
<artifactId>furnace-manager-api</artifactId> | ||
<name>Furnace - Manager API</name> | ||
|
||
<dependencies> | ||
<dependency> | ||
<groupId>org.jboss.forge.furnace</groupId> | ||
<artifactId>furnace-manager-spi</artifactId> | ||
</dependency> | ||
</dependencies> | ||
</project> | ||
|
118 changes: 118 additions & 0 deletions
118
manager/api/src/main/java/org/jboss/forge/furnace/manager/AddonManager.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,118 @@ | ||
/* | ||
* Copyright 2013 Red Hat, Inc. and/or its affiliates. | ||
* | ||
* Licensed under the Eclipse Public License version 1.0, available at | ||
* http://www.eclipse.org/legal/epl-v10.html | ||
*/ | ||
|
||
package org.jboss.forge.furnace.manager; | ||
|
||
import org.jboss.forge.furnace.addons.AddonId; | ||
import org.jboss.forge.furnace.manager.request.DeployRequest; | ||
import org.jboss.forge.furnace.manager.request.DisableRequest; | ||
import org.jboss.forge.furnace.manager.request.EnableRequest; | ||
import org.jboss.forge.furnace.manager.request.InstallRequest; | ||
import org.jboss.forge.furnace.manager.request.RemoveRequest; | ||
import org.jboss.forge.furnace.manager.spi.AddonInfo; | ||
import org.jboss.forge.furnace.repositories.AddonRepository; | ||
import org.jboss.forge.furnace.services.Exported; | ||
|
||
/** | ||
* Responsible for installing, removing, enabling, and disabling {@link AddonId} instances in any registered | ||
* {@link AddonRepository}. | ||
* | ||
* @author <a href="mailto:ggastald@redhat.com">George Gastaldi</a> | ||
* @author <a href="mailto:lincolnbaxter@gmail.com">Lincoln Baxter, III</a> | ||
*/ | ||
@Exported | ||
public interface AddonManager | ||
{ | ||
/** | ||
* @param id the addon to be informed | ||
* @return information about the {@link AddonId}, like required and optional addons that this addon depends on. | ||
*/ | ||
AddonInfo info(AddonId addonId); | ||
|
||
/** | ||
* Create a new {@link InstallRequest} for the given {@link AddonId}. | ||
* | ||
* @param id the addon to be installed | ||
* @return the request for installation | ||
*/ | ||
InstallRequest install(AddonId id); | ||
|
||
/** | ||
* Create a new {@link InstallRequest} for the given {@link AddonId} and {@link AddonRepository}. | ||
* | ||
* @param id the addon to be installed | ||
* @param addonRepository the {@link AddonRepository} to be used | ||
* @return the request for installation | ||
*/ | ||
InstallRequest install(AddonId id, AddonRepository addonRepository); | ||
|
||
/** | ||
* Create a new {@link DeployRequest} for the given {@link AddonId}. | ||
* | ||
* @param id the addon to be installed | ||
* @return the request for installation | ||
*/ | ||
DeployRequest deploy(AddonId id); | ||
|
||
/** | ||
* Create a new {@link DeployRequest} for the given {@link AddonId} and {@link AddonRepository}. | ||
* | ||
* @param id the addon to be deployed | ||
* @param addonRepository the {@link AddonRepository} to be used | ||
* @return the request for installation | ||
*/ | ||
DeployRequest deploy(AddonId id, AddonRepository addonRepository); | ||
|
||
/** | ||
* Create a new {@link RemoveRequest} for the given {@link AddonId}. | ||
* | ||
* @param id the addon to be removed | ||
* @return the request for removal | ||
*/ | ||
RemoveRequest remove(AddonId id); | ||
|
||
/** | ||
* Create a new {@link RemoveRequest} for the given {@link AddonId} and {@link AddonRepository}. | ||
* | ||
* @param id the addon to be removed | ||
* @return the request for removal | ||
*/ | ||
RemoveRequest remove(AddonId id, AddonRepository addonRepository); | ||
|
||
/** | ||
* Create a new {@link EnableRequest} for the given {@link AddonId}. | ||
* | ||
* @param id the addon to be enabled | ||
* @return the request for activation | ||
*/ | ||
EnableRequest enable(AddonId id); | ||
|
||
/** | ||
* Create a new {@link EnableRequest} for the given {@link AddonId} and {@link AddonRepository}. | ||
* | ||
* @param id the addon to be enabled | ||
* @return the request for activation | ||
*/ | ||
EnableRequest enable(AddonId id, AddonRepository addonRepository); | ||
|
||
/** | ||
* Create a new {@link DisableRequest} for the given {@link AddonId}. | ||
* | ||
* @param id the addon to be disabled | ||
* @return the request for de-activation | ||
*/ | ||
DisableRequest disable(AddonId id); | ||
|
||
/** | ||
* Create a new {@link DisableRequest} for the given {@link AddonId} and {@link AddonRepository}. | ||
* | ||
* @param id the addon to be disabled | ||
* @return the request for de-activation | ||
*/ | ||
DisableRequest disable(AddonId id, AddonRepository addonRepository); | ||
|
||
} |
29 changes: 29 additions & 0 deletions
29
manager/api/src/main/java/org/jboss/forge/furnace/manager/request/AddonActionRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
/* | ||
* Copyright 2013 Red Hat, Inc. and/or its affiliates. | ||
* | ||
* Licensed under the Eclipse Public License version 1.0, available at | ||
* http://www.eclipse.org/legal/epl-v10.html | ||
*/ | ||
|
||
package org.jboss.forge.furnace.manager.request; | ||
|
||
import org.jboss.forge.furnace.manager.spi.AddonInfo; | ||
|
||
/** | ||
* Super interface for actions targeted at a specific addon | ||
* | ||
* @author <a href="mailto:ggastald@redhat.com">George Gastaldi</a> | ||
* | ||
*/ | ||
public interface AddonActionRequest | ||
{ | ||
/** | ||
* Target Addon | ||
*/ | ||
AddonInfo getRequestedAddonInfo(); | ||
|
||
/** | ||
* Execute the desired request | ||
*/ | ||
void perform(); | ||
} |
19 changes: 19 additions & 0 deletions
19
manager/api/src/main/java/org/jboss/forge/furnace/manager/request/DeployRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/* | ||
* Copyright 2013 Red Hat, Inc. and/or its affiliates. | ||
* | ||
* Licensed under the Eclipse Public License version 1.0, available at | ||
* http://www.eclipse.org/legal/epl-v10.html | ||
*/ | ||
|
||
package org.jboss.forge.furnace.manager.request; | ||
|
||
/** | ||
* When an addon is installed, another addons could be required. This object returns the necessary information for the | ||
* installation of an addon to succeed, like required addons and dependencies | ||
* | ||
* @author <a href="mailto:ggastald@redhat.com">George Gastaldi</a> | ||
* | ||
*/ | ||
public interface DeployRequest extends AddonActionRequest | ||
{ | ||
} |
20 changes: 20 additions & 0 deletions
20
manager/api/src/main/java/org/jboss/forge/furnace/manager/request/DisableRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
/* | ||
* Copyright 2013 Red Hat, Inc. and/or its affiliates. | ||
* | ||
* Licensed under the Eclipse Public License version 1.0, available at | ||
* http://www.eclipse.org/legal/epl-v10.html | ||
*/ | ||
|
||
package org.jboss.forge.furnace.manager.request; | ||
|
||
import org.jboss.forge.furnace.addons.AddonId; | ||
|
||
/** | ||
* This object is responsible for disabling an {@link AddonId}. | ||
* | ||
* @author <a href="mailto:lincolnbaxter@gmail.com">Lincoln Baxter, III</a> | ||
*/ | ||
public interface DisableRequest extends AddonActionRequest | ||
{ | ||
|
||
} |
20 changes: 20 additions & 0 deletions
20
manager/api/src/main/java/org/jboss/forge/furnace/manager/request/EnableRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
/* | ||
* Copyright 2013 Red Hat, Inc. and/or its affiliates. | ||
* | ||
* Licensed under the Eclipse Public License version 1.0, available at | ||
* http://www.eclipse.org/legal/epl-v10.html | ||
*/ | ||
|
||
package org.jboss.forge.furnace.manager.request; | ||
|
||
import org.jboss.forge.furnace.addons.AddonId; | ||
|
||
/** | ||
* This object is responsible for enabling an {@link AddonId}. | ||
* | ||
* @author <a href="mailto:lincolnbaxter@gmail.com">Lincoln Baxter, III</a> | ||
*/ | ||
public interface EnableRequest extends AddonActionRequest | ||
{ | ||
|
||
} |
21 changes: 21 additions & 0 deletions
21
manager/api/src/main/java/org/jboss/forge/furnace/manager/request/InstallRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
/* | ||
* Copyright 2013 Red Hat, Inc. and/or its affiliates. | ||
* | ||
* Licensed under the Eclipse Public License version 1.0, available at | ||
* http://www.eclipse.org/legal/epl-v10.html | ||
*/ | ||
|
||
package org.jboss.forge.furnace.manager.request; | ||
|
||
import java.util.List; | ||
|
||
/** | ||
* A {@link InstallRequest} delegates a group of requests so that it may be performed in a single call | ||
* | ||
* @author <a href="mailto:ggastald@redhat.com">George Gastaldi</a> | ||
* | ||
*/ | ||
public interface InstallRequest extends AddonActionRequest | ||
{ | ||
public List<AddonActionRequest> getActions(); | ||
} |
20 changes: 20 additions & 0 deletions
20
manager/api/src/main/java/org/jboss/forge/furnace/manager/request/RemoveRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
/* | ||
* Copyright 2013 Red Hat, Inc. and/or its affiliates. | ||
* | ||
* Licensed under the Eclipse Public License version 1.0, available at | ||
* http://www.eclipse.org/legal/epl-v10.html | ||
*/ | ||
|
||
package org.jboss.forge.furnace.manager.request; | ||
|
||
import org.jboss.forge.furnace.addons.Addon; | ||
|
||
/** | ||
* This object is responsible for removing an {@link Addon}. | ||
* | ||
* @author <a href="mailto:lincolnbaxter@gmail.com">Lincoln Baxter, III</a> | ||
*/ | ||
public interface RemoveRequest extends AddonActionRequest | ||
{ | ||
|
||
} |
15 changes: 15 additions & 0 deletions
15
manager/api/src/main/java/org/jboss/forge/furnace/manager/request/UpdateRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/* | ||
* Copyright 2013 Red Hat, Inc. and/or its affiliates. | ||
* | ||
* Licensed under the Eclipse Public License version 1.0, available at | ||
* http://www.eclipse.org/legal/epl-v10.html | ||
*/ | ||
|
||
package org.jboss.forge.furnace.manager.request; | ||
|
||
public interface UpdateRequest extends AddonActionRequest | ||
{ | ||
RemoveRequest getRemoveRequest(); | ||
|
||
DeployRequest getDeployRequest(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<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"> | ||
<modelVersion>4.0.0</modelVersion> | ||
<parent> | ||
<groupId>org.jboss.forge.furnace</groupId> | ||
<artifactId>furnace-manager-parent</artifactId> | ||
<version>2.0.0-SNAPSHOT</version> | ||
<relativePath>../pom.xml</relativePath> | ||
</parent> | ||
|
||
<artifactId>furnace-manager</artifactId> | ||
<name>Furnace - Manager Impl</name> | ||
|
||
<dependencies> | ||
<dependency> | ||
<groupId>org.jboss.forge.furnace</groupId> | ||
<artifactId>furnace-api</artifactId> | ||
<scope>provided</scope> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.jboss.forge.furnace</groupId> | ||
<artifactId>furnace-manager-api</artifactId> | ||
</dependency> | ||
</dependencies> | ||
</project> | ||
|
Oops, something went wrong.