You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by mu...@apache.org on 2013/05/27 15:15:04 UTC
[2/2] git commit: updated refs/heads/master to 883333c
generate an action event when portable IP association is transferred
from a network to different network
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/ad48c838
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/ad48c838
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/ad48c838
Branch: refs/heads/master
Commit: ad48c838088efad0ca2f30045c849b9152adca7a
Parents: 8297445
Author: Murali Reddy <mu...@gmail.com>
Authored: Sat May 25 17:46:13 2013 +0530
Committer: Murali Reddy <mu...@gmail.com>
Committed: Mon May 27 18:44:41 2013 +0530
----------------------------------------------------------------------
api/src/com/cloud/event/EventTypes.java | 1 +
.../src/com/cloud/network/NetworkManagerImpl.java | 4 ++++
2 files changed, 5 insertions(+), 0 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/ad48c838/api/src/com/cloud/event/EventTypes.java
----------------------------------------------------------------------
diff --git a/api/src/com/cloud/event/EventTypes.java b/api/src/com/cloud/event/EventTypes.java
index da96294..6dfb1ab 100755
--- a/api/src/com/cloud/event/EventTypes.java
+++ b/api/src/com/cloud/event/EventTypes.java
@@ -436,6 +436,7 @@ public class EventTypes {
public static final String EVENT_PORTABLE_IP_RANGE_CREATE = "PORTABLE.IP.RANGE.CREATE";
public static final String EVENT_PORTABLE_IP_RANGE_DELETE = "PORTABLE.IP.RANGE.DELETE";
+ public static final String EVENT_PORTABLE_IP_TRANSFER = "PORTABLE.IP.TRANSFER";
static {
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/ad48c838/server/src/com/cloud/network/NetworkManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/network/NetworkManagerImpl.java b/server/src/com/cloud/network/NetworkManagerImpl.java
index 254510b..d699b2e 100755
--- a/server/src/com/cloud/network/NetworkManagerImpl.java
+++ b/server/src/com/cloud/network/NetworkManagerImpl.java
@@ -39,6 +39,7 @@ import com.cloud.deploy.DeployDestination;
import com.cloud.deploy.DeploymentPlan;
import com.cloud.domain.Domain;
import com.cloud.domain.dao.DomainDao;
+import com.cloud.event.ActionEventUtils;
import com.cloud.event.EventTypes;
import com.cloud.event.UsageEventUtils;
import com.cloud.event.dao.UsageEventDao;
@@ -1063,6 +1064,9 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L
_ipAddressDao.update(ipAddrId, ip);
txn.commit();
+ ActionEventUtils.onActionEvent(User.UID_SYSTEM, Account.ACCOUNT_ID_SYSTEM, Domain.ROOT_DOMAIN,
+ EventTypes.EVENT_PORTABLE_IP_TRANSFER, "Portable IP associated is transferred from network "
+ + currentNetworkId + " to " + newNetworkId);
}
@Override