modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/drift/DriftManagerLocal.java
| 24 +++++++-
modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/drift/DriftManagerRemote.java
| 29 +++++++++-
2 files changed, 50 insertions(+), 3 deletions(-)
New commits:
commit 572db8ca18f25bea345b03243bf9b9bb8d9bdf8a
Author: John Sanda <jsanda(a)redhat.com>
Date: Mon Dec 19 10:34:58 2011 -0500
Adding/updating javadocs
diff --git
a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/drift/DriftManagerLocal.java
b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/drift/DriftManagerLocal.java
index ac707cc..5a79413 100644
---
a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/drift/DriftManagerLocal.java
+++
b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/drift/DriftManagerLocal.java
@@ -140,8 +140,28 @@ public interface DriftManagerLocal extends DriftManagerRemote {
void updateDriftDefinition(Subject subject, DriftDefinition driftDefinition);
/**
- * Update the provided driftDef (identified by name) on the specified EntityContext.
If it exists it will be replaced. If not it will
- * be added. Agents, if available, will be notified of the change.
+ * <p>
+ * Saves or updates the provided drift definition. If the definition, identified by
name, already exists, an update
+ * is performed; otherwise, a new drift definition is saved. Agents if available will
be notified of the change.
+ * If agents are unreachable, the definition will still be saved/updated. Changes
will then propagate to agents
+ * the next time they do an inventory sync.
+ * </p>
+ * <p>
+ * Several validation checks are performed before the definition is persisted. If it
is a new definition, the
+ * following checks are performed:
+ * <ul>
+ * <li>Verify that the resource supports drift management</li>
+ * <li>Verify that the template (if specified) already exists in the
database</li>
+ * <li>Verify that the template (if specified) belongs to the correct
resource type</li>
+ * </ul>
+ * For new and existing definitions these additional checks are performed:
+ * <ul>
+ * <li>Verify that the definition name does not contain illegal
characters</li>
+ * <li>Verify that the base directory does not contain illegal
characters</li>
+ * <li>Verify that filters do not contain illegal characters</li>
+ * </ul>
+ * </p>
+ *
* @param subject
* @param entityContext
* @param driftDef
diff --git
a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/drift/DriftManagerRemote.java
b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/drift/DriftManagerRemote.java
index 1d3dc82..a39108e 100644
---
a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/drift/DriftManagerRemote.java
+++
b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/drift/DriftManagerRemote.java
@@ -119,5 +119,32 @@ public interface DriftManagerRemote {
void pinSnapshot(Subject subject, int driftDefId, int snapshotVersion);
- void updateDriftDefinition(Subject subject, EntityContext entityContext,
DriftDefinition driftConfig);
+ /**
+ * <p>
+ * Saves or updates the provided drift definition. If the definition, identified by
name, already exists, an update
+ * is performed; otherwise, a new drift definition is saved. Agents if available will
be notified of the change.
+ * If agents are unreachable, the definition will still be saved/updated. Changes
will then propagate to agents
+ * the next time they do an inventory sync.
+ * </p>
+ * <p>
+ * Several validation checks are performed before the definition is persisted. If it
is a new definition, the
+ * following checks are performed:
+ * <ul>
+ * <li>Verify that the resource supports drift management</li>
+ * <li>Verify that the template (if specified) already exists in the
database</li>
+ * <li>Verify that the template (if specified) belongs to the correct
resource type</li>
+ * </ul>
+ * For new and existing definitions these additional checks are performed:
+ * <ul>
+ * <li>Verify that the definition name does not contain illegal
characters</li>
+ * <li>Verify that the base directory does not contain illegal
characters</li>
+ * <li>Verify that filters do not contain illegal characters</li>
+ * </ul>
+ * </p>
+ *
+ * @param subject
+ * @param entityContext
+ * @param driftDef
+ */
+ void updateDriftDefinition(Subject subject, EntityContext entityContext,
DriftDefinition driftDef);
}
Show replies by date