You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by GitBox <gi...@apache.org> on 2020/09/30 23:03:08 UTC

[GitHub] [cloudstack] ravening opened a new pull request #4361: Add vpcid in usage network response

ravening opened a new pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361


   
   ## Description
   <!--- Describe your changes in detail -->
   Currently vpcid is not displayed in listUsageRecords response.
   Add the vpcid so that we can see to which vpc, the network belongs
   
   
    list usagerecords startdate=2020-01-01 enddate=2020-08-01
   ```
   {
         "account": "admin",
         "accountid": "40ec-c28e-11ea-9a43-06103377",
         "description": "Bytes received by network null (324e0-ca0f-4762-9850-de5f5c411) using router r-7-VM (ef9-00d7-43e8-8819-9f23226)",
         "domain": "ROOT",
         "domainid": "04c6-c28e-11ea-9a43-0613377",
         "enddate": "2020-07-27'T'23:59:59+00:00",
         "rawusage": "77776",
         "startdate": "2020-07-27'T'00:00:00+00:00",
         "tags": [],
         "type": "DomainRouter",
         "usage": "77776 bytes received",
         "usageid": "ef96c-00d7-43e8-8819-9f236226",
         "usagetype": 5,
         "vpcid": "d187a-69a3-4153-88ac-3c7c2de31", >>>>>>>>>>>>>>>>>>>>>
         "zoneid": "8ad-7db1-4a1a-9030-db0e62"
       },
   ```
   
   <!-- For new features, provide link to FS, dev ML discussion etc. -->
   <!-- In case of bug fix, the expected and actual behaviours, steps to reproduce. -->
   
   <!-- When "Fixes: #<id>" is specified, the issue/PR will automatically be closed when this PR gets merged -->
   <!-- For addressing multiple issues/PRs, use multiple "Fixes: #<id>" -->
   <!-- Fixes: # -->
   
   ## Types of changes
   <!--- What types of changes does your code introduce? Put an `x` in all the boxes that apply: -->
   - [ ] Breaking change (fix or feature that would cause existing functionality to change)
   - [ ] New feature (non-breaking change which adds functionality)
   - [ ] Bug fix (non-breaking change which fixes an issue)
   - [X] Enhancement (improves an existing feature and functionality)
   - [ ] Cleanup (Code refactoring and cleanup, that may add test cases)
   
   
   <!-- Please read the [CONTRIBUTING](https://github.com/apache/cloudstack/blob/master/CONTRIBUTING.md) document -->
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] rhtyd merged pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
rhtyd merged pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#issuecomment-718005349


   @DaanHoogland a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] ravening commented on a change in pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
ravening commented on a change in pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#discussion_r513388565



##########
File path: server/src/main/java/com/cloud/api/ApiDBUtils.java
##########
@@ -1568,7 +1568,7 @@ public static GuestOSCategoryVO findGuestOsCategoryById(long catId) {
     }
 
     public static VpcVO findVpcById(long vpcId) {
-        return s_vpcDao.findById(vpcId);
+        return s_vpcDao.findByIdIncludingRemoved(vpcId);

Review comment:
       @rhtyd fixed it. added a new function




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] ravening commented on a change in pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
ravening commented on a change in pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#discussion_r498078891



##########
File path: server/src/main/java/com/cloud/api/ApiDBUtils.java
##########
@@ -1568,7 +1568,7 @@ public static GuestOSCategoryVO findGuestOsCategoryById(long catId) {
     }
 
     public static VpcVO findVpcById(long vpcId) {
-        return s_vpcDao.findById(vpcId);
+        return s_vpcDao.findByIdIncludingRemoved(vpcId);

Review comment:
       Can you please tell me why this will have side effects?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#issuecomment-728845260


   Packaging result: ✔centos7 ✔centos8 ✔debian. JID-2390


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#issuecomment-718004740


   @blueorangutan test


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] rhtyd commented on a change in pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
rhtyd commented on a change in pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#discussion_r513339084



##########
File path: server/src/main/java/com/cloud/api/ApiDBUtils.java
##########
@@ -1568,7 +1568,7 @@ public static GuestOSCategoryVO findGuestOsCategoryById(long catId) {
     }
 
     public static VpcVO findVpcById(long vpcId) {
-        return s_vpcDao.findById(vpcId);
+        return s_vpcDao.findByIdIncludingRemoved(vpcId);

Review comment:
       ping @ravening ^^




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#issuecomment-728820750


   @DaanHoogland a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#issuecomment-728857364


   @blueorangutan test


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] weizhouapache commented on a change in pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
weizhouapache commented on a change in pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#discussion_r498110438



##########
File path: server/src/main/java/com/cloud/api/ApiDBUtils.java
##########
@@ -1568,7 +1568,7 @@ public static GuestOSCategoryVO findGuestOsCategoryById(long catId) {
     }
 
     public static VpcVO findVpcById(long vpcId) {
-        return s_vpcDao.findById(vpcId);
+        return s_vpcDao.findByIdIncludingRemoved(vpcId);

Review comment:
       @ravening it would be better to add new method in ApiDBUtils.java 




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#issuecomment-717928844


   @DaanHoogland a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] rhtyd commented on a change in pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
rhtyd commented on a change in pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#discussion_r498069859



##########
File path: server/src/main/java/com/cloud/api/ApiDBUtils.java
##########
@@ -1568,7 +1568,7 @@ public static GuestOSCategoryVO findGuestOsCategoryById(long catId) {
     }
 
     public static VpcVO findVpcById(long vpcId) {
-        return s_vpcDao.findById(vpcId);
+        return s_vpcDao.findByIdIncludingRemoved(vpcId);

Review comment:
       Could this have side effects? You may need to check, or instead add a new method that finds VPC by ID including removed?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#issuecomment-717977153


   Packaging result: ✔centos7 ✖centos8 ✖debian. JID-2299


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#issuecomment-728820426


   @blueorangutan package


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#issuecomment-717928450


   @blueorangutan package


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#issuecomment-732017758


   nah, if it doesn't yield regressions, let's leave it


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] rhtyd commented on pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
rhtyd commented on pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#issuecomment-732010664


   @DaanHoogland my bad I didn't see the milestone, since changes were simple enough I merged it. I'm okay if we need to revert this. 


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#issuecomment-728857876


   @DaanHoogland a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#issuecomment-729203616


   <b>Trillian test result (tid-3187)</b>
   Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
   Total time taken: 32406 seconds
   Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr4361-t3187-kvm-centos7.zip
   Intermittent failure detected: /marvin/tests/smoke/test_diagnostics.py
   Intermittent failure detected: /marvin/tests/smoke/test_vpc_vpn.py
   Smoke tests completed. 86 look OK, 0 have error(s)
   Only failed tests results shown below:
   
   
   Test | Result | Time (s) | Test File
   --- | --- | --- | ---
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on pull request #4361: Add vpcid in usage network response

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on pull request #4361:
URL: https://github.com/apache/cloudstack/pull/4361#issuecomment-718454888


   blue ape failed to upload results but these were good (hadn't seen this before):
   ```
   Intermittent failure detected: /marvin/tests/smoke/test_diagnostics.py
   Intermittent failure detected: /marvin/tests/smoke/test_kubernetes_clusters.py
   Smoke tests completed. 85 look OK, 1 have error(s)
   Only failed tests results shown below:
   
   
   Test | Result | Time (s) | Test File
   --- | --- | --- | ---
   test_03_deploy_and_upgrade_kubernetes_cluster | `Failure` | 257.54 | test_kubernetes_clusters.py
   ```
   cc @rhtyd 


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org