[GitHub] cloudstack issue #1908: CLOUDSTACK-9317: Fixed disable static nat on leaving...

2017-04-11 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1908
  
Looks good now. Not sure what's up with Jenkins though.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1908: CLOUDSTACK-9317: Fixed disable static nat on ...

2017-04-11 Thread ProjectMoon
Github user ProjectMoon commented on a diff in the pull request:

https://github.com/apache/cloudstack/pull/1908#discussion_r110848750
  
--- Diff: setup/db/db/schema-4920to41000.sql ---
@@ -230,5 +230,11 @@ JOIN `cloud`.`vm_snapshots` s ON 
(s.service_offering_id = o.id AND s.vm_id = v.i
 WHERE (o.cpu is null AND o.speed IS NULL AND o.ram_size IS NULL) AND
 (d.name = 'cpuNumber' OR d.name = 'cpuSpeed' OR d.name = 'memory');
 
+<<<<<<< 1c48deefe9b534198cad19b5528ce0dcfa8d04a5
 -- CLOUDSTACK-9827: Storage tags stored in multiple places
 DROP VIEW IF EXISTS `cloud`.`storage_tag_view`;
+
+ALTER TABLE `user_ip_address` ADD COLUMN `rule_state` VARCHAR(32) COMMENT 
'static  rule state while removing';
+===
--- End diff --

Conflict line.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1908: CLOUDSTACK-9317: Fixed disable static nat on ...

2017-04-11 Thread ProjectMoon
Github user ProjectMoon commented on a diff in the pull request:

https://github.com/apache/cloudstack/pull/1908#discussion_r110849362
  
--- Diff: server/src/com/cloud/network/router/CommandSetupHelper.java ---
@@ -848,13 +849,38 @@ public int compare(final PublicIpAddress o1, final 
PublicIpAddress o2) {
 associatedWithNetworkId = ipAddrList.get(0).getNetworkId();
 }
 
+// for network if the ips does not have any rules, then only 
last ip
+List userIps = 
_ipAddressDao.listByAssociatedNetwork(associatedWithNetworkId, null);
+
+int ipsWithrules = 0;
+int ipsStaticNat = 0;
+for (IPAddressVO ip : userIps) {
+if ( _rulesDao.countRulesByIpIdAndState(ip.getId(), 
FirewallRule.State.Active) > 0 ) {
--- End diff --

Inconsistent formatting of the parentheses in the `if`. A bit nitpicky, but 
the code has to adhere to format.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1908: CLOUDSTACK-9317: Fixed disable static nat on ...

2017-04-11 Thread ProjectMoon
Github user ProjectMoon commented on a diff in the pull request:

https://github.com/apache/cloudstack/pull/1908#discussion_r110848709
  
--- Diff: setup/db/db/schema-4920to41000.sql ---
@@ -230,5 +230,11 @@ JOIN `cloud`.`vm_snapshots` s ON 
(s.service_offering_id = o.id AND s.vm_id = v.i
 WHERE (o.cpu is null AND o.speed IS NULL AND o.ram_size IS NULL) AND
 (d.name = 'cpuNumber' OR d.name = 'cpuSpeed' OR d.name = 'memory');
 
+<<<<<<< 1c48deefe9b534198cad19b5528ce0dcfa8d04a5
--- End diff --

It seems you got a conflict stuck in the file.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1908: CLOUDSTACK-9317: Fixed disable static nat on ...

2017-04-06 Thread ProjectMoon
Github user ProjectMoon commented on a diff in the pull request:

https://github.com/apache/cloudstack/pull/1908#discussion_r110113725
  
--- Diff: 
plugins/hypervisors/xenserver/src/com/cloud/hypervisor/xenserver/resource/CitrixResourceBase.java
 ---
@@ -625,15 +627,20 @@ protected ExecutionResult 
cleanupNetworkElementCommand(final IpAssocCommand cmd)
 
 // there is only one ip in this public vlan and removing 
it, so
 // remove the nic
-if (ipsCount == 1 && !ip.isAdd()) {
-removeVif = true;
+if (lastIp != null && lastIp.equalsIgnoreCase("true") && 
!ip.isAdd()) {
--- End diff --

True, but a lot of the other code is already using StringUtils or is moving 
to it. Reviewers in other PRs tend to recommend it.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1908: CLOUDSTACK-9317: Fixed disable static nat on ...

2017-03-20 Thread ProjectMoon
Github user ProjectMoon commented on a diff in the pull request:

https://github.com/apache/cloudstack/pull/1908#discussion_r106855504
  
--- Diff: 
plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java
 ---
@@ -1764,9 +1765,12 @@ protected ExecutionResult 
cleanupNetworkElementCommand(final IpAssocCommand cmd)
 }
 nicNum = 
broadcastUriAllocatedToVM.get(ip.getBroadcastUri());
 
-if (numOfIps == 1 && !ip.isAdd()) {
-vifHotUnPlug(conn, routerName, ip.getVifMacAddress());
-networkUsage(routerIp, "deleteVif", "eth" + nicNum);
+if (lastIp != null && lastIp.equalsIgnoreCase("true") && 
!ip.isAdd()) {
--- End diff --

`StringUtils.equalsIgnoreCase` can check both null and the value.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1908: CLOUDSTACK-9317: Fixed disable static nat on ...

2017-03-20 Thread ProjectMoon
Github user ProjectMoon commented on a diff in the pull request:

https://github.com/apache/cloudstack/pull/1908#discussion_r106856634
  
--- Diff: server/src/com/cloud/network/router/CommandSetupHelper.java ---
@@ -848,13 +849,37 @@ public int compare(final PublicIpAddress o1, final 
PublicIpAddress o2) {
 associatedWithNetworkId = ipAddrList.get(0).getNetworkId();
 }
 
+// for network if the ips does not have any rules, then only 
last ip
+List userIps = 
_ipAddressDao.listByAssociatedNetwork(associatedWithNetworkId, null);
+
+int ipsWithrules = 0;
+int ipsStaticNat = 0;
+for (IPAddressVO ip : userIps) {
+if ( _rulesDao.countRulesByIpIdAndState(ip.getId(), 
FirewallRule.State.Active) > 0 ) {
+ipsWithrules++;
+}
+
+// check onetoonenat and also check if the ip "add":false. 
If there are 2 PF remove 1 static nat add
+if (ip.isOneToOneNat() && ip.getRuleState() == null) {
+ipsStaticNat++;
+}
+}
+
 final IpAssocCommand cmd = new IpAssocCommand(ipsToSend);
 cmd.setAccessDetail(NetworkElementCommand.ROUTER_IP, 
_routerControlHelper.getRouterControlIp(router.getId()));
 cmd.setAccessDetail(NetworkElementCommand.ROUTER_GUEST_IP, 
_routerControlHelper.getRouterIpInNetwork(associatedWithNetworkId, 
router.getId()));
 cmd.setAccessDetail(NetworkElementCommand.ROUTER_NAME, 
router.getInstanceName());
 final DataCenterVO dcVo = 
_dcDao.findById(router.getDataCenterId());
 cmd.setAccessDetail(NetworkElementCommand.ZONE_NETWORK_TYPE, 
dcVo.getNetworkType().toString());
 
+// if there 1 static nat then it will be checked for remove at 
the resource
+if (ipsWithrules == 0 && ipsStaticNat == 0 ) {
--- End diff --

There's an extraneous space between the `0` and the `)` here. Also, this is 
probably just me misunderstanding the code, but wouldn't you want to check if 
`ipsStaticNat` equals `1` in this case? Or maybe you're checking for both to be 
`0` because if both are 0 we're generating a removal command?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1908: CLOUDSTACK-9317: Fixed disable static nat on ...

2017-03-20 Thread ProjectMoon
Github user ProjectMoon commented on a diff in the pull request:

https://github.com/apache/cloudstack/pull/1908#discussion_r106855300
  
--- Diff: 
plugins/hypervisors/xenserver/src/com/cloud/hypervisor/xenserver/resource/CitrixResourceBase.java
 ---
@@ -625,15 +627,20 @@ protected ExecutionResult 
cleanupNetworkElementCommand(final IpAssocCommand cmd)
 
 // there is only one ip in this public vlan and removing 
it, so
 // remove the nic
-if (ipsCount == 1 && !ip.isAdd()) {
-removeVif = true;
+if (lastIp != null && lastIp.equalsIgnoreCase("true") && 
!ip.isAdd()) {
--- End diff --

`StringUtils.equalsIgnoreCase` can replace checking both null and the 
value: 
https://commons.apache.org/proper/commons-lang/javadocs/api-2.6/org/apache/commons/lang/StringUtils.html#equalsIgnoreCase(java.lang.String,
 java.lang.String)


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1908: CLOUDSTACK-9317: Fixed disable static nat on ...

2017-03-20 Thread ProjectMoon
Github user ProjectMoon commented on a diff in the pull request:

https://github.com/apache/cloudstack/pull/1908#discussion_r106857110
  
--- Diff: server/src/com/cloud/network/router/CommandSetupHelper.java ---
@@ -848,13 +849,37 @@ public int compare(final PublicIpAddress o1, final 
PublicIpAddress o2) {
 associatedWithNetworkId = ipAddrList.get(0).getNetworkId();
 }
 
+// for network if the ips does not have any rules, then only 
last ip
+List userIps = 
_ipAddressDao.listByAssociatedNetwork(associatedWithNetworkId, null);
+
+int ipsWithrules = 0;
+int ipsStaticNat = 0;
+for (IPAddressVO ip : userIps) {
+if ( _rulesDao.countRulesByIpIdAndState(ip.getId(), 
FirewallRule.State.Active) > 0 ) {
+ipsWithrules++;
+}
+
+// check onetoonenat and also check if the ip "add":false. 
If there are 2 PF remove 1 static nat add
+if (ip.isOneToOneNat() && ip.getRuleState() == null) {
--- End diff --

Similar to the comments about checking if `lastIp` isn't null, I find that 
checking rule state to be null is a bit ... obscure. What is null supposed to 
mean in this context? It seems the `rule_state` column is only changed to 
`Releasing` when releasing an IP and nothing else. I guess that's intentional?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1908: CLOUDSTACK-9317: Fixed disable static nat on ...

2017-03-09 Thread ProjectMoon
Github user ProjectMoon commented on a diff in the pull request:

https://github.com/apache/cloudstack/pull/1908#discussion_r105130816
  
--- Diff: 
plugins/hypervisors/xenserver/src/com/cloud/hypervisor/xenserver/resource/CitrixResourceBase.java
 ---
@@ -625,15 +627,20 @@ protected ExecutionResult 
cleanupNetworkElementCommand(final IpAssocCommand cmd)
 
 // there is only one ip in this public vlan and removing 
it, so
 // remove the nic
-if (ipsCount == 1 && !ip.isAdd()) {
-removeVif = true;
+if (lastIp != null && !ip.isAdd()) {
--- End diff --

Maybe it would make sense to check the value of `lastIp` being something 
instead of just checking if it's not null? It works the way it is, but perhaps 
checking specifically for a value like `"true"` would make sense. Would prevent 
someone from updating code later to send `"false"` for whatever reason and then 
causing something unexpected. Relying on not null as a truth value is a bit 
obtuse in my opinion.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1908: CLOUDSTACK-9317: Fixed disable static nat on leaving...

2017-03-03 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1908
  
Hi, that's great news.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1908: CLOUDSTACK-9317: Fixed disable static nat on leaving...

2017-03-01 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1908
  
@jayapalu Quite possible, yes. It could be fixed by adding another 
condition to the check that was added with #1907. It could also be "fixed" by 
checkiing if `configured()` returns `True` in the `arpPing()` method of the 
`CsIp` class. But I'm guessing that it doesn't get properly deleted from the 
DataBag when it's removed from the router. Thus it just gets written to 
`/etc/cloudstack/ips.json` again.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1908: CLOUDSTACK-9317: Fixed disable static nat on leaving...

2017-02-28 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1908
  
We have been testing this PR internally for some time now, and we have seen 
some strange `arping` issues. We have seen that `/etc/cloudstack/ips.json` on 
the router has IPs on them that aren't cleaned up. Since #1908 is now merged, 
I'm worried that the changes in this PR will not play well with #1908.

Specifically, we have seen that IPs left over in the `ips.json` file can be 
stuck on `"add": true` even if the IP is no longer on the account. 

Thus, the code that was added in PR 1907 concerns me:

```
 if not address['add'] and not ip.configured():
logging.info("Skipping %s as the add flag is set to %s " % 
(address['public_ip'], address['add']))
continue
```

The `if` condition fails in a case we've been investigating. Because our IP 
is `"add": true`, but `configured()` returns `False`, the IP gets reconfigured 
anyway. This doesn't add the IP to the router's interface, but it _does_ run an 
`arping` command (see CsAddress.py). Essentially, if this PR is merged as-is, 
we might wind up with a regression on CLOUDSTACK-9500. 

I will do a bit of manual testing combining both #1908 and #1907 to see 
what happens. It may just be that after restarting the network (and thus 
cleaning the router), these issues will vanish.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1908: CLOUDSTACK-9317: Fixed disable static nat on leaving...

2017-02-28 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1908
  
I'm looking at the `DataBag` code, and it seems that it loads information 
from the data located at `/etc/cloudstack/` and therefore 1907 should work fine 
with this, ASSUMING that is smart enough to recognize that the IP should no 
longer be there.

I think this is a scenario that should definitely be tested as it has the 
potential to break the whole PR.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1908: CLOUDSTACK-9317: Fixed disable static nat on leaving...

2017-02-28 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1908
  
Question: would #1907 be relevant to this? That change relied on sending 
all the IPs to the router, but under this change, we will be sending one at a 
time.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1948: [CLOUDSTACK-9793] Faster IP in subnet check

2017-02-17 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1948
  
Updated with the JIRA ticket.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1948: Faster IP in subnet check

2017-02-17 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1948
  
We have not entered one into JIRA, no. But we can.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1908: CLOUDSTACK-9317: Fixed disable static nat on ...

2017-02-17 Thread ProjectMoon
Github user ProjectMoon commented on a diff in the pull request:

https://github.com/apache/cloudstack/pull/1908#discussion_r101736186
  
--- Diff: server/src/com/cloud/network/router/CommandSetupHelper.java ---
@@ -175,6 +176,8 @@
 @Inject
 private IPAddressDao _ipAddressDao;
 @Inject
+private FirewallRulesDao _firewallsDao;
--- End diff --

There is already a `FirewallRulesDao` in the file. No need to inject this 
one.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1943: CLOUDSTACK-9339: Send correct network type to router...

2017-02-17 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1943
  
I didn't actually find the other PR, otherwise I probably wouldn't have 
submitted this one. But I do think this is cleaner, and more centralized. 
There's no real harm in having both, and having this one will be more likely to 
prevent future problems where someone attempts to send a network type across 
the wire.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1948: Faster IP in subnet check

2017-02-17 Thread ProjectMoon
GitHub user ProjectMoon opened a pull request:

https://github.com/apache/cloudstack/pull/1948

Faster IP in subnet check

This change removes the conversion from IPNetwork to list in one of the 
router scripts. This makes the router faster at processing static NAT rules, 
which can prevent timeouts when attaching or detaching IPs.

With the `list` conversion, it has to potentially check a list of 65536 IP 
strings multiple times. We assume that the comparison implemented in the 
IPNetwork is far more efficient. We have seen speed-up from 218 seconds to 
enable static NAT with 18 IPs on the router to 2 or 3 seconds by removing this 
cast. This also fixes a potential bug where adding IPs to a router time out 
because the scripts are taking too long. 218 seconds, for example, is beyond 
the timeout on the KVM agent for script execution, and then all enableStaticNat 
operations will fail.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack pr-faster-static-nats

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1948.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1948


commit bd288ccc233775ce4bd5b67718c4e20611234d24
Author: Stefania <stefa...@greenqloud.com>
Date:   2017-02-08T16:01:34Z

Faster ip in subnet check

This change removes an unnecessary conversion from IPNetwork
to list in one of the router scripts. This makes the router
faster at processing static NAT rules, which can prevent
timeouts when attaching or detaching IPs.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1943: CLOUDSTACK-9339: Send correct network type to...

2017-02-15 Thread ProjectMoon
GitHub user ProjectMoon opened a pull request:

https://github.com/apache/cloudstack/pull/1943

CLOUDSTACK-9339: Send correct network type to router config

This forces the network type (nw_type) of the IP address being sent into 
router configuration scripts to be lowercase. All of the Python config scripts 
on the router explicitly look for network type "public" with a lowercase P. 
Sending "Public" with an uppercase P can cause important iptables rules to not 
be created, meaning that public networking won't work.

We discovered this while applying the other fix for CLOUDSTACK-9339 to our 
own 4.7 branch, and then checked master and saw that it hadn't been changed 
yet. The fix is very simple: force the network type to lowercase when creating 
IpAssoc config items. Without this fix, iptables rules for public IPs that are 
added in `CsAddress.py` would get skipped, and traffic into instances on 
interfaces other than eth2 would not work.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack pr-lowercase-p

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1943.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1943


commit 163b9c76be06d8d3e019b9826900a0135437dfaa
Author: jeff <j...@greenqloud.com>
Date:   2017-02-13T16:17:25Z

CLOUDSTACK-9339: Send correct network type to router config

This forces the network type (nw_type) of the IP address being sent
into router configuration scripts to be lowercase. All of the Python
config scripts on the router explicitly look for network type "public"
with a lowercase P. Sending "Public" with an uppercase P can cause
important iptables rules to not be created, meaning that public
networking won't work.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1908: CLOUDSTACK-9317: Fixed disable static nat on ...

2017-02-10 Thread ProjectMoon
Github user ProjectMoon commented on a diff in the pull request:

https://github.com/apache/cloudstack/pull/1908#discussion_r100535848
  
--- Diff: setup/db/db/schema-4920to41000.sql ---
@@ -62,3 +62,4 @@ INSERT INTO `cloud`.`role_permissions` (`uuid`, 
`role_id`, `rule`, `permission`,
 INSERT INTO `cloud`.`role_permissions` (`uuid`, `role_id`, `rule`, 
`permission`, `sort_order`) values (UUID(), 3, 'createSnapshotFromVMSnapshot', 
'ALLOW', 302) ON DUPLICATE KEY UPDATE rule=rule;
 INSERT INTO `cloud`.`role_permissions` (`uuid`, `role_id`, `rule`, 
`permission`, `sort_order`) values (UUID(), 4, 'createSnapshotFromVMSnapshot', 
'ALLOW', 260) ON DUPLICATE KEY UPDATE rule=rule;
 
+ALTER TABLE `user_ip_address` ADD COLUMN `staticnat_state` VARCHAR(32) 
COMMENT 'static  rule state while removing'
--- End diff --

This column name does not match the name of the column in the VO 
(`rule_state`).


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1898: CLOUDSTACK-8862: Lock on volume before attemp...

2017-02-08 Thread ProjectMoon
Github user ProjectMoon closed the pull request at:

https://github.com/apache/cloudstack/pull/1898


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1898: CLOUDSTACK-8862: Lock on volume before attempting to...

2017-02-08 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1898
  
Closed in favor of #1900 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1900: CLOUDSTACK-8862: Introduced new state attaching for ...

2017-02-02 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1900
  
@anshul1886 I have not delved too deeply into the state machine transition 
code, though I understand the basics of how it works. I think `synchronized` + 
state transition should be enough in a single management server scenario, but 
will it work in a clustered scenario? Of course, `synchronized` cannot lock 
across processes, which is why CS has the database locks everywhere. If the 
state transitions will work in a clustered scenario, then I'm fine with just 
using that one.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1900: CLOUDSTACK-8862: Introduced new state attaching for ...

2017-02-02 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1900
  
@anshul1886 I am fine with putting both commits on either PR. If you are 
unopposed we can just stick it on mine?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1623: CLOUDSTACK-9317: Enable/disable static NAT associate...

2017-01-17 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1623
  
Closed in favor of https://github.com/apache/cloudstack/pull/1908


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1623: CLOUDSTACK-9317: Enable/disable static NAT as...

2017-01-17 Thread ProjectMoon
Github user ProjectMoon closed the pull request at:

https://github.com/apache/cloudstack/pull/1623


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1908: CLOUDSTACK-9317: Fixed disable static nat on leaving...

2017-01-17 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1908
  
Thanks for adding the missing parts. Here is the PR that was open against 
4.8 for this, which I guess can be closed now: 
https://github.com/apache/cloudstack/pull/1623

I guess the comment from @jburwell still applies to this.



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1450: CLOUDSTACK-9317: Enable/disable static NAT associate...

2017-01-12 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1450
  
@jayapalu Can you post this in the new version of the fix? (And possibly 
re-test, if you were using an older version)


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1898: CLOUDSTACK-8862: Lock on volume before attemp...

2017-01-09 Thread ProjectMoon
GitHub user ProjectMoon opened a pull request:

https://github.com/apache/cloudstack/pull/1898

CLOUDSTACK-8862: Lock on volume before attempting to attach it.

It is possible to attach a single volume to multiple instances by running 
the commands close to one another. In KVM, this can be verified by checking the 
`virsh dumpxml` for the instances once the volume attaches are complete. This 
PR adds a lock on the volume ID in the orchestration step to make sure the 
method is only executed one at a time for any given volume ID. So in the 
scenario of someone sending simultaneous volume attach requests, one should 
succeed and the others will fail after hitting the check added in 
8aa34d048ab3e459de6d254049f3a31dde42b50d.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack pr-volume-sync-fix

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1898.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1898


commit c7d174ceee5e87d5423741923e4f87086d042bd5
Author: jeff <j...@greenqloud.com>
Date:   2017-01-09T16:28:33Z

CLOUDSTACK-8862: Lock on volume before attempting to attach it.

This commit updates the volume orchestration to lock on the volume ID
before sending the attach commands. While there is already validation
for checking if a VM is already attached to an instance in both the
API command and the volume orchestration framework, they aren't of
much use if there's no synchronization.

With this commit, a single volume being attached to multiple instances
will successfully attach to one and return the error added in commit
8aa34d048ab3e459de6d254049f3a31dde42b50d for the other requests.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1617: Changed UsageEventUtils to UsageEventEmitter and mad...

2016-12-01 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1617
  
We are in the process of fixing the conflicts. The rebase worked fine, but 
we have to rewrite one of the new unit tests to not use the `UsageEventEmitter`.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1566: [CLOUDSTACK-9645] Followup fix for #1162: Add suppor...

2016-12-01 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1566
  
Updated to latest master, and a JIRA ticket now exists.

https://issues.apache.org/jira/browse/CLOUDSTACK-9645


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1622: [CLOUDSTACK-9644] Adding missing bits field to Templ...

2016-12-01 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1622
  
Updated to latest master, and a JIRA ticket has been created.

https://issues.apache.org/jira/browse/CLOUDSTACK-9644


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1618: Now returning os info with the list snapshot respons...

2016-12-01 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1618
  
Updated to latest master, and now with a JIRA ticket.

https://issues.apache.org/jira/browse/CLOUDSTACK-9643


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1559: CLOUDSTACK-9280: System VM volumes can be expunged i...

2016-11-23 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1559
  
@rhtyd, in my opinion the two commits are functionally separate enough that 
they should remain separate (and this might have been asked for in one of the 
various previous incarnations of this PR--I don't remember). I think rolling 
them into one commit puts too many things in one change. The smaller commits 
allows reverting of functionality easier, etc. If the change is 
rebased/fast-forward merged, then it shouldn't be any different than if there 
were two PRs.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1618: Now returning os info with the list snapshot respons...

2016-11-22 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1618
  
Code review issues have been addressed, with the exception of combining the 
Guest OS ID/VM Instance ID into a join method on VolumeDao. There was some 
compilation failure in the F5 plugin when I tried building locally. Will see if 
that happens here too.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1618: Now returning os info with the list snapshot ...

2016-11-22 Thread ProjectMoon
Github user ProjectMoon commented on a diff in the pull request:

https://github.com/apache/cloudstack/pull/1618#discussion_r89097671
  
--- Diff: server/src/com/cloud/api/ApiResponseHelper.java ---
@@ -157,6 +156,7 @@
 import org.apache.cloudstack.usage.Usage;
 import org.apache.cloudstack.usage.UsageService;
 import org.apache.cloudstack.usage.UsageTypes;
+import org.apache.commons.collections.CollectionUtils;
--- End diff --

It is used in ApiResponseHelper.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1559: CLOUDSTACK-9280: System VM volumes can be expunged i...

2016-11-21 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1559
  
Addressed the comments. For some reason the tests for VolumeDataFactoryImpl 
were being skipped. Will try to see why.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1559: CLOUDSTACK-9280: System VM volumes can be expunged i...

2016-11-21 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1559
  
Updated to latest 4.8. Will also address the comments too.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1618: Now returning os info with the list snapshot respons...

2016-11-21 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1618
  
Rebased to latest master. The comments will also be addressed soon, 
hopefully.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1622: Adding missing bits field to TemplateResponse

2016-11-21 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1622
  
Rebased to latest master.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1623: CLOUDSTACK-9317: Enable/disable static NAT associate...

2016-11-21 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1623
  
Updated to latest 4.8.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1566: Followup fix for #1162: Add support for not (re)star...

2016-11-21 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1566
  
Rebased to latest master. Should probably rebuild the packages.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1744: CLOUDSTACK-9183: bash: /opt/cloud/bin/getRouterAlert...

2016-11-02 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1744
  
In the JIRA ticket, it's at least reported that this is happening on 4.8 as 
well.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1607: SSVM downloader now handles redirects properl...

2016-11-01 Thread ProjectMoon
Github user ProjectMoon closed the pull request at:

https://github.com/apache/cloudstack/pull/1607


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1607: SSVM downloader now handles redirects properly.

2016-11-01 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1607
  
Closed in favor of #1746.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1746: SSVM downloader now handles redirects properl...

2016-11-01 Thread ProjectMoon
GitHub user ProjectMoon opened a pull request:

https://github.com/apache/cloudstack/pull/1746

SSVM downloader now handles redirects properly.

New version of #1607, opened against 4.9 so it can be forward merged.

**Original Description**
Previously it was using the HttpClient to make an initial request to an 
ISO. This would follow redirects. Then it would make another request using 
built-in Java URL and InputStream, which doesn't follow redirects. This results 
in the ISO getting stuck at 0% forever and also causing DOS effects.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack 
pr-iso-follow-redirects-4.9

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1746.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1746


commit 7a4220f17252d54a1b990c776d1378400652b0ab
Author: jeff <j...@greenqloud.com>
Date:   2016-07-08T09:59:08Z

SSVM downloader now handles redirects properly.

Previously it was using the HttpClient to make an initial request
to an ISO. This would follow redirects. Then it would make
another request using built-in Java URL and InputStream, which
doesn't follow redirects. This results in the ISO getting stuck
at 0% forever and also causing DOS effects.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1622: Adding missing bits field to TemplateResponse

2016-10-21 Thread ProjectMoon
GitHub user ProjectMoon reopened a pull request:

https://github.com/apache/cloudstack/pull/1622

Adding missing bits field to TemplateResponse

This pull request adds a bits field for template size, and sets it equal to 
ISO size.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack pr-template-bits

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1622.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1622


commit 5974dad0aaea41deaa5d8f6dbc61c39e5532f258
Author: Pall Helgason <pa...@greenqloud.com>
Date:   2016-03-03T13:32:24Z

Adding missing bits field to TemplateResponse




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1622: Adding missing bits field to TemplateResponse

2016-10-21 Thread ProjectMoon
Github user ProjectMoon closed the pull request at:

https://github.com/apache/cloudstack/pull/1622


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1622: Adding missing bits field to TemplateResponse

2016-10-21 Thread ProjectMoon
Github user ProjectMoon closed the pull request at:

https://github.com/apache/cloudstack/pull/1622


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1622: Adding missing bits field to TemplateResponse

2016-10-21 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1622
  
Build failed due to running out of disk space. Will re-trigger.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1622: Adding missing bits field to TemplateResponse

2016-10-21 Thread ProjectMoon
GitHub user ProjectMoon reopened a pull request:

https://github.com/apache/cloudstack/pull/1622

Adding missing bits field to TemplateResponse

This pull request adds a bits field for template size, and sets it equal to 
ISO size.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack pr-template-bits

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1622.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1622






---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1622: Adding missing bits field to TemplateResponse

2016-10-21 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1622
  
This has been rebased to the latest master, and the code review suggestions 
applied.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1623: CLOUDSTACK-9317: Enable/disable static NAT associate...

2016-10-21 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1623
  
This one hasn't been rebased in quite a while, so the packages produced 
will be rather old. Going to rebase this against latest 4.8.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1624: Fixes regarding VOLUME_DELETE events resulting from ...

2016-10-21 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1624
  
The commits have been squashed, commit message updated to make sense (I 
think; let me know if it's not right), and rebased against latest 4.8.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1607: SSVM downloader now handles redirects properly.

2016-10-21 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1607
  
This one hasn't been rebased in quite a while, so the packages produced 
will be rather old. Going to rebase this against latest master.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1624: Fixes regarding VOLUME_DELETE events resulting from ...

2016-10-13 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1624
  
No code changes, just updating the commits under it.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1624: Fixes regarding VOLUME_DELETE events resulting from ...

2016-10-13 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1624
  
This branch has been rebased to latest 4.8.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1559: CLOUDSTACK-9280: System VM volumes can be expunged i...

2016-10-12 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1559
  
Looks like Travis worked this time.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1559: CLOUDSTACK-9280: System VM volumes can be exp...

2016-10-12 Thread ProjectMoon
GitHub user ProjectMoon reopened a pull request:

https://github.com/apache/cloudstack/pull/1559

CLOUDSTACK-9280: System VM volumes can be expunged if no SSVM exists.

This commit adds a special SSVM endpoint which simply returns true for
all operations sent to it, without actually doing anything. This
allows for destroyed volumes of system VMs to be expunged when there
are no hosts (and thus no system VMs) remaining to handle the volume
destruction.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack 
pr-volume-expunge-fix-master

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1559.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1559


commit e1bc3a61933f4fd5a61b802b62ea19db5234dcbd
Author: jeff <j...@greenqloud.com>
Date:   2016-02-08T16:30:03Z

CLOUDSTACK-9280: System VM volumes can be expunged if no SSVM exists.

This commit adds a special SSVM endpoint which simply returns true for
all operations sent to it, without actually doing anything. This
allows for destroyed volumes of system VMs to be expunged when there
are no hosts (and thus no system VMs) remaining to handle the volume
destruction.

commit efe687548bdf5d8ab8dac37a36e34c4fe655dc88
Author: jeff <j...@greenqloud.com>
Date:   2016-10-07T15:39:12Z

More fixes to allow volume expunging when primary storage is missing.

The volume expunger is able to handle volumes which have no primary
storage specified, but when loading these volumes, it is possible that
a volume is missing the primary storage already which can cause an
exception to be thrown. This commit changes this behavior so that when
loading a volume to be expunged, not being able to find a primary data
store is considered a warning rather than an exception.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1559: CLOUDSTACK-9280: System VM volumes can be exp...

2016-10-12 Thread ProjectMoon
Github user ProjectMoon closed the pull request at:

https://github.com/apache/cloudstack/pull/1559


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1559: CLOUDSTACK-9280: System VM volumes can be expunged i...

2016-10-12 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1559
  
The OOBM power off test keeps failing. I've run the test locally with the 
simulator and it succeeds fine. Going to try to kick Travis again to see if it 
works (third time's the charm?).


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1559: CLOUDSTACK-9280: System VM volumes can be exp...

2016-10-11 Thread ProjectMoon
GitHub user ProjectMoon reopened a pull request:

https://github.com/apache/cloudstack/pull/1559

CLOUDSTACK-9280: System VM volumes can be expunged if no SSVM exists.

This commit adds a special SSVM endpoint which simply returns true for
all operations sent to it, without actually doing anything. This
allows for destroyed volumes of system VMs to be expunged when there
are no hosts (and thus no system VMs) remaining to handle the volume
destruction.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack 
pr-volume-expunge-fix-master

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1559.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1559


commit e1bc3a61933f4fd5a61b802b62ea19db5234dcbd
Author: jeff <j...@greenqloud.com>
Date:   2016-02-08T16:30:03Z

CLOUDSTACK-9280: System VM volumes can be expunged if no SSVM exists.

This commit adds a special SSVM endpoint which simply returns true for
all operations sent to it, without actually doing anything. This
allows for destroyed volumes of system VMs to be expunged when there
are no hosts (and thus no system VMs) remaining to handle the volume
destruction.

commit efe687548bdf5d8ab8dac37a36e34c4fe655dc88
Author: jeff <j...@greenqloud.com>
Date:   2016-10-07T15:39:12Z

More fixes to allow volume expunging when primary storage is missing.

The volume expunger is able to handle volumes which have no primary
storage specified, but when loading these volumes, it is possible that
a volume is missing the primary storage already which can cause an
exception to be thrown. This commit changes this behavior so that when
loading a volume to be expunged, not being able to find a primary data
store is considered a warning rather than an exception.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1559: CLOUDSTACK-9280: System VM volumes can be exp...

2016-10-11 Thread ProjectMoon
Github user ProjectMoon closed the pull request at:

https://github.com/apache/cloudstack/pull/1559


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1559: CLOUDSTACK-9280: System VM volumes can be expunged i...

2016-10-07 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1559
  
This pull request has been updated with another commit that fixes a bug 
where volumes cannot be expunged because the loading of the volume fails to 
find a primary data store (despite the expunger being able to handle this 
scenario). Will be working on some unit tests for this.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1624: Fixes regarding VOLUME_DELETE events resultin...

2016-09-17 Thread ProjectMoon
Github user ProjectMoon closed the pull request at:

https://github.com/apache/cloudstack/pull/1624


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1624: Fixes regarding VOLUME_DELETE events resultin...

2016-09-17 Thread ProjectMoon
GitHub user ProjectMoon reopened a pull request:

https://github.com/apache/cloudstack/pull/1624

Fixes regarding VOLUME_DELETE events resulting from account deletion

New version of #1491.

**Original Description**
New version of #1373, but updated for the 4.7 branch with another fix that 
allows it to properly find expunged root volumes. This is a bug fix, which is 
why we target the 4.7 branch.

Original pull request:
Fixes regarding usage event emission.

UsageEventUtils was previously not checking deleted accounts, which meant 
that if an account was deleted that had some resources running on it, those 
resources would get destroyed without emitting any events.

Furthermore, the VOLUME_DELETE event of ROOT volumes is the responsibility 
of the UserVmManager, which gets circumvented when expunging resources 
following the account deletion. Added a check to the AccountManager which 
catches the ROOT volumes that need to be deleted and emits events for them.

To test this: Create a new user. As that user, create and destroy an 
instance. This should cause the VM_CREATE, VM_START, VM_STOP, VM_DESTROY, 
VOLUME_CREATE, and VOLUME_DELETE events to be emitted. 
Create a new instance as the same user. Log in as admin, and delete the 
user. The same set of events should be emitted, and there should be no 
duplicate DELETE events for the ROOT volume of the previous instance.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack 
pr-volume-usage-events-fixes-4.8

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1624.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1624


commit 24a194939b46488e38af6913f417d7e08ebf5eb3
Author: nnesic <n...@greenqloud.com>
Date:   2015-10-12T13:15:30Z

Emit a VOLUME_DELETE usage event when account deletion destroys an instance.

Currently the logic about volume deletion seems to be that an event
should be emitted when the volume delete is requested, not when the
deletion completes.

The VolumeStateListener specifically ignores destroy events for ROOT
volumes, assuming that the ROOT volume only gets deleted when the
instance is destroyed and the UserVmManager should take care of it.

When deleting an account, all of its resources get destroyed, but the
instance expunging circumvents the UserVmManager, and thus we miss the
VOLUME_DESTROY usage event.  Added a check in the AccountManager to
emit the deletion event for ROOT volumes belonging to instances which
weren't destroyed prior to the account deletion.

commit 609c3bb17be96c68cd3652fb1e8439e1907a8176
Author: nnesic <n...@greenqloud.com>
Date:   2016-09-13T10:01:50Z

Instead of emitting volume delete events directly, account manager
now attempts to propperly destroy the vm before expunging it. This
way the destroy logic is respected, including the event emission.
Unit tests have been modified accordingly.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1624: Fixes regarding VOLUME_DELETE events resulting from ...

2016-09-02 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1624
  
We can have someone test it. Are you looking for results of a manual test, 
reproduction tests, or something automated? A manual test is probably the best 
from our side because we don't really have the time to write any 
unit/integration tests at the moment beyond what already exists in this PR.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1624: Fixes regarding VOLUME_DELETE events resulting from ...

2016-09-01 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1624
  
Looks like it's ready for merging now.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1624: Fixes regarding VOLUME_DELETE events resulting from ...

2016-09-01 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1624
  
The pull request has been rebased.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1624: Fixes regarding VOLUME_DELETE events resulting from ...

2016-09-01 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1624
  
Alright. I'll rebase it once #1654 has been merged.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1624: Fixes regarding VOLUME_DELETE events resulting from ...

2016-08-29 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1624
  
Have rebased to latest 4.8. Travis build failed with what looks like 
`Unable to execute 
/home/travis/build/apache/cloudstack/developer/target/db/templates.simulator.sql:
 Unknown column 'state' in 'field list'`. Don't think it's related to this. 
Will see what happens with the latest 4.8 code.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1624: Fixes regarding VOLUME_DELETE events resultin...

2016-08-29 Thread ProjectMoon
GitHub user ProjectMoon reopened a pull request:

https://github.com/apache/cloudstack/pull/1624

Fixes regarding VOLUME_DELETE events resulting from account deletion

New version of #1491.

**Original Description**
New version of #1373, but updated for the 4.7 branch with another fix that 
allows it to properly find expunged root volumes. This is a bug fix, which is 
why we target the 4.7 branch.

Original pull request:
Fixes regarding usage event emission.

UsageEventUtils was previously not checking deleted accounts, which meant 
that if an account was deleted that had some resources running on it, those 
resources would get destroyed without emitting any events.

Furthermore, the VOLUME_DELETE event of ROOT volumes is the responsibility 
of the UserVmManager, which gets circumvented when expunging resources 
following the account deletion. Added a check to the AccountManager which 
catches the ROOT volumes that need to be deleted and emits events for them.

To test this: Create a new user. As that user, create and destroy an 
instance. This should cause the VM_CREATE, VM_START, VM_STOP, VM_DESTROY, 
VOLUME_CREATE, and VOLUME_DELETE events to be emitted. 
Create a new instance as the same user. Log in as admin, and delete the 
user. The same set of events should be emitted, and there should be no 
duplicate DELETE events for the ROOT volume of the previous instance.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack 
pr-volume-usage-events-fixes-4.8

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1624.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1624


commit 8009683e67da185bc3e6d630c42b0f614f1eb825
Author: nnesic <n...@greenqloud.com>
Date:   2015-10-12T13:15:30Z

Emit a VOLUME_DELETE usage event when account deletion destroys an instance.

Currently the logic about volume deletion seems to be that an event
should be emitted when the volume delete is requested, not when the
deletion completes.

The VolumeStateListener specifically ignores destroy events for ROOT
volumes, assuming that the ROOT volume only gets deleted when the
instance is destroyed and the UserVmManager should take care of it.

When deleting an account, all of its resources get destroyed, but the
instance expunging circumvents the UserVmManager, and thus we miss the
VOLUME_DESTROY usage event.  Added a check in the AccountManager to
emit the deletion event for ROOT volumes belonging to instances which
weren't destroyed prior to the account deletion.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1624: Fixes regarding VOLUME_DELETE events resulting from ...

2016-08-29 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1624
  
Jenkins build log has vanished into 404 oblivion. Will see what happened 
with Travis (https://travis-ci.org/apache/cloudstack/builds/154436801).


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1624: Fixes regarding VOLUME_DELETE events resultin...

2016-08-29 Thread ProjectMoon
Github user ProjectMoon closed the pull request at:

https://github.com/apache/cloudstack/pull/1624


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1623: CLOUDSTACK-9317: Enable/disable static NAT associate...

2016-08-29 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1623
  
Yeah. Unfortunately I have not had any time to work on the pull requests 
lately. When I have time I will reopen it against 4.9.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1635: CLOUDSTACK-9451

2016-08-24 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1635
  
All hypervisors are affected by this, since the parameter is just not 
passed into the VM Manager. That means its effects don't work at all anywhere. 
:) I will try to review it to tomorrow.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1661: Export UUID for zone creation event completio...

2016-08-24 Thread ProjectMoon
GitHub user ProjectMoon opened a pull request:

https://github.com/apache/cloudstack/pull/1661

Export UUID for zone creation event completion.

Action events have support for exporting their "first class entities" over 
the event bus, if it's turned on. This works mostly for BaseAsyncCmds and any 
synchronous command that operates on already-existing entities. They are 
populated by the ApiServer and found by ActionEventUtils.

Where it tends to falter is when dealing with synchronous creation 
commands. This commit makes createZone export the zone UUID over the event bus 
once the zone has been created.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack 
pr-zone-ids-action-events

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1661.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1661


commit fb7f5dfa37d76de66de52b0d8a10470b436fdf1a
Author: jeff <j...@greenqloud.com>
Date:   2016-08-24T16:19:16Z

Export UUID for zone creation event completion.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1624: Fixes regarding VOLUME_DELETE events resulting from ...

2016-08-23 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1624
  
Has been rebased against latest 4.8 and the `TODO` comments removed. The 
map was left alone though.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1624: Fixes regarding VOLUME_DELETE events resultin...

2016-08-23 Thread ProjectMoon
Github user ProjectMoon commented on a diff in the pull request:

https://github.com/apache/cloudstack/pull/1624#discussion_r75853547
  
--- Diff: server/test/com/cloud/user/AccountManagerImplTest.java ---
@@ -231,6 +253,73 @@ public void cleanup() {
 CallContext.unregister();
 }
 
+public UsageEventUtils setupUsageUtils() {
+_usageEventDao = new MockUsageEventDao();
+UsageEventUtils utils = new UsageEventUtils();
+
+Map<String, String> usageUtilsFields = new HashMap<String, 
String>();
+usageUtilsFields.put("usageEventDao", "_usageEventDao");
+usageUtilsFields.put("accountDao", "_accountDao");
+usageUtilsFields.put("dcDao", "_dcDao");
+usageUtilsFields.put("configDao", "_configDao");
--- End diff --

In this case, the map is not used outside of the method.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1623: CLOUDSTACK-9317: Enable/disable static NAT associate...

2016-08-23 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1623
  
It's been amended and rebased. I still haven't had time to add a new DAO 
method to the IP address DAO. I can work on that now though. When is the RC 
being cut?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1632: Honor the forced parameter for stopVirtualMachine ap...

2016-08-11 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1632
  
I thought it was: new features -> master, bug fixes -> oldest supported 
release branch? 4.7 is no longer supported but as far as I know 4.8 is still 
supported (I could be wrong on this).


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1632: Honor the forced parameter for stopVirtualMachine ap...

2016-08-11 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1632
  
It goes all the way back to 4.7. Isn't the oldest supported release 
currently 4.8 at the moment? If so, it should be opened against 4.8, right?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1622: Adding missing bits field to TemplateResponse

2016-08-08 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1622
  
Rebased to latest master, though I still haven't checked into the Jenkins 
issue.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1618: Now returning os info with the list snapshot ...

2016-08-08 Thread ProjectMoon
GitHub user ProjectMoon reopened a pull request:

https://github.com/apache/cloudstack/pull/1618

Now returning os info with the list snapshot response

This commit adds the ID and display name of the OS on the volume. 

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack 
pr-return-os-info-snapshots

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1618.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1618


commit 04bd2fe0d1ec85db6fe9237ae5fb66d533e59f01
Author: Pall Helgason <pa...@greenqloud.com>
Date:   2016-03-02T13:11:30Z

Now returning os info with the list snapshot response




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1617: Changed UsageEventUtils to UsageEventEmitter ...

2016-08-08 Thread ProjectMoon
GitHub user ProjectMoon reopened a pull request:

https://github.com/apache/cloudstack/pull/1617

Changed UsageEventUtils to UsageEventEmitter and made it injectable

An updated version of #1191, against the master branch. This also updates 
the HypervisorTemplateAdapter test slightly, making it less unwieldy.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack 
pr-usage-event-emitter-master

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1617.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1617


commit 9dba2fc9b42bb91de1ec17dc01c2f9c64749fd3c
Author: nnesic <n...@greenqloud.com>
Date:   2015-11-26T16:02:44Z

Changed UsageEventUtils to UsageEventEmitter and made it injectable




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1618: Now returning os info with the list snapshot ...

2016-08-08 Thread ProjectMoon
Github user ProjectMoon closed the pull request at:

https://github.com/apache/cloudstack/pull/1618


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1617: Changed UsageEventUtils to UsageEventEmitter ...

2016-08-08 Thread ProjectMoon
Github user ProjectMoon closed the pull request at:

https://github.com/apache/cloudstack/pull/1617


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1622: Adding missing bits field to TemplateResponse

2016-08-05 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1622
  
Will check it out on Monday. Very weird that the end of the build is not an 
error specifically. Just "ending due to build failure" or some such.

The first exception I see is:

```
2016-08-05 17:25:38,700 ERROR [network.guru.NiciraNvpGuestNetworkGuru] 
(main:) Unable to store logical switch id in broadcast uri, uuid = 
c63b0770-2e6c-4189-8c99-9f9a764f2cf1
java.net.URISyntaxException: Expected scheme-specific part at index 8: 
lswitch:
at java.net.URI$Parser.fail(URI.java:2848)
at java.net.URI$Parser.failExpecting(URI.java:2854)
at java.net.URI$Parser.parse(URI.java:3057)
at java.net.URI.(URI.java:820)
at 
com.cloud.network.guru.NiciraNvpGuestNetworkGuru.implement(NiciraNvpGuestNetworkGuru.java:235)
at 
com.cloud.network.guru.NiciraNvpGuestNetworkGuruTest.testImplementURIException(NiciraNvpGuestNetworkGuruTest.java:410)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at 
org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
at 
org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at 
org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
at 
org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at 
org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
at 
org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
at 
org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at 
org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:283)
at 
org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:173)
at 
org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:153)
at 
org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:128)
at 
org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:203)
at 
org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:155)
at 
org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103)


Is that relevant?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1622: Adding missing bits field to TemplateResponse

2016-08-05 Thread ProjectMoon
GitHub user ProjectMoon reopened a pull request:

https://github.com/apache/cloudstack/pull/1622

Adding missing bits field to TemplateResponse

This pull request adds a bits field for template size, and sets it equal to 
ISO size.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack pr-template-bits

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1622.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1622


commit 3a9ea5021c5c316483d13e0799d56d011a90c34c
Author: Pall Helgason <pa...@greenqloud.com>
Date:   2016-03-03T13:32:24Z

Adding missing bits field to TemplateResponse




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1622: Adding missing bits field to TemplateResponse

2016-08-05 Thread ProjectMoon
Github user ProjectMoon closed the pull request at:

https://github.com/apache/cloudstack/pull/1622


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1607: SSVM downloader now handles redirects properl...

2016-08-05 Thread ProjectMoon
GitHub user ProjectMoon reopened a pull request:

https://github.com/apache/cloudstack/pull/1607

SSVM downloader now handles redirects properly.

Previously it was using the HttpClient to make an initial request to an 
ISO. This would follow redirects. Then it would make another request using 
built-in Java URL and InputStream, which doesn't follow redirects. This results 
in the ISO getting stuck at 0% forever and also causing DOS effects.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack pr-iso-follow-redirects

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1607.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1607


commit fb143a9ef3fcdefea48b32676d485e568c8ad8a6
Author: jeff <j...@greenqloud.com>
Date:   2016-07-08T09:59:08Z

SSVM downloader now handles redirects properly.

Previously it was using the HttpClient to make an initial request
to an ISO. This would follow redirects. Then it would make
another request using built-in Java URL and InputStream, which
doesn't follow redirects. This results in the ISO getting stuck
at 0% forever and also causing DOS effects.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1607: SSVM downloader now handles redirects properl...

2016-08-05 Thread ProjectMoon
Github user ProjectMoon closed the pull request at:

https://github.com/apache/cloudstack/pull/1607


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1622: Adding missing bits field to TemplateResponse

2016-08-05 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1622
  
Will check the smoke tests for Marvin.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack issue #1623: CLOUDSTACK-9317: Enable/disable static NAT associate...

2016-08-05 Thread ProjectMoon
Github user ProjectMoon commented on the issue:

https://github.com/apache/cloudstack/pull/1623
  
JIRA ticket is CLOUDSTACK-9317. Have not run the Marvin tests, but will do 
so.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1623: CLOUDSTACK-9317: Enable/disable static NAT as...

2016-08-05 Thread ProjectMoon
Github user ProjectMoon commented on a diff in the pull request:

https://github.com/apache/cloudstack/pull/1623#discussion_r73664374
  
--- Diff: server/src/com/cloud/network/IpAddressManagerImpl.java ---
@@ -1698,6 +1698,22 @@ public String acquireGuestIpAddress(Network network, 
String requestedIp) {
 
 Random _rand = new Random(System.currentTimeMillis());
 
+/**
+ * Get the list of public IPs that need to be applied for a static NAT 
enable/disable operation.
+ * Manipulating only these ips prevents concurrency issues when 
disabling static nat at the same time.
+ * @param staticNats
+ * @return The list of IPs that need to be applied for the static NAT 
to work.
+ */
+public List getStaticNatSourceIps(List staticNats) {
+List userIps = new ArrayList<>();
+
+for (StaticNat snat : staticNats) {
+
userIps.add(_ipAddressDao.findById(snat.getSourceIpAddressId()));
+}
--- End diff --

This makes sense, yes. Better to have one database query than many.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1607: SSVM downloader now handles redirects properl...

2016-08-05 Thread ProjectMoon
GitHub user ProjectMoon reopened a pull request:

https://github.com/apache/cloudstack/pull/1607

SSVM downloader now handles redirects properly.

Previously it was using the HttpClient to make an initial request to an 
ISO. This would follow redirects. Then it would make another request using 
built-in Java URL and InputStream, which doesn't follow redirects. This results 
in the ISO getting stuck at 0% forever and also causing DOS effects.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack pr-iso-follow-redirects

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1607.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1607


commit af433d57c504a5f648c27902e894341987dc346d
Author: jeff <j...@greenqloud.com>
Date:   2016-07-08T09:59:08Z

SSVM downloader now handles redirects properly.

Previously it was using the HttpClient to make an initial request
to an ISO. This would follow redirects. Then it would make
another request using built-in Java URL and InputStream, which
doesn't follow redirects. This results in the ISO getting stuck
at 0% forever and also causing DOS effects.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1607: SSVM downloader now handles redirects properl...

2016-08-05 Thread ProjectMoon
Github user ProjectMoon closed the pull request at:

https://github.com/apache/cloudstack/pull/1607


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] cloudstack pull request #1624: Fixes regarding VOLUME_DELETE events resultin...

2016-08-02 Thread ProjectMoon
GitHub user ProjectMoon opened a pull request:

https://github.com/apache/cloudstack/pull/1624

Fixes regarding VOLUME_DELETE events resulting from account deletion

New version of #1491.

**Original Description**
New version of #1373, but updated for the 4.7 branch with another fix that 
allows it to properly find expunged root volumes. This is a bug fix, which is 
why we target the 4.7 branch.

Original pull request:
Fixes regarding usage event emission.

UsageEventUtils was previously not checking deleted accounts, which meant 
that if an account was deleted that had some resources running on it, those 
resources would get destroyed without emitting any events.

Furthermore, the VOLUME_DELETE event of ROOT volumes is the responsibility 
of the UserVmManager, which gets circumvented when expunging resources 
following the account deletion. Added a check to the AccountManager which 
catches the ROOT volumes that need to be deleted and emits events for them.

To test this: Create a new user. As that user, create and destroy an 
instance. This should cause the VM_CREATE, VM_START, VM_STOP, VM_DESTROY, 
VOLUME_CREATE, and VOLUME_DELETE events to be emitted. 
Create a new instance as the same user. Log in as admin, and delete the 
user. The same set of events should be emitted, and there should be no 
duplicate DELETE events for the ROOT volume of the previous instance.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/greenqloud/cloudstack 
pr-volume-usage-events-fixes-4.8

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cloudstack/pull/1624.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1624


commit c861e1a4922ce9030d0a0d8542572d3a444c1509
Author: nnesic <n...@greenqloud.com>
Date:   2015-10-12T13:15:30Z

Emit a VOLUME_DELETE usage event when account deletion destroys an instance.

Currently the logic about volume deletion seems to be that an event
should be emitted when the volume delete is requested, not when the
deletion completes.

The VolumeStateListener specifically ignores destroy events for ROOT
volumes, assuming that the ROOT volume only gets deleted when the
instance is destroyed and the UserVmManager should take care of it.

When deleting an account, all of its resources get destroyed, but the
instance expunging circumvents the UserVmManager, and thus we miss the
VOLUME_DESTROY usage event.  Added a check in the AccountManager to
emit the deletion event for ROOT volumes belonging to instances which
weren't destroyed prior to the account deletion.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


  1   2   3   >