You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cloudstack.apache.org by nitin-maharana <gi...@git.apache.org> on 2015/09/28 20:36:47 UTC

[GitHub] cloudstack pull request: CLOUDSTACK-8919: Slow UI response while l...

GitHub user nitin-maharana opened a pull request:

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

    CLOUDSTACK-8919: Slow UI response while loading the list of networks in network tab.

    Instead of searching for each network, now it is searching for each zone.
    For basic zone, it will show the security group directly because by default securitygroupsenabled is true.
    For advanced zone, check the securitygroupsenabled option in each zone. If any one has value true, then show.

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

    $ git pull https://github.com/nitin-maharana/cloudstack CloudStack-Nitin10

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

    https://github.com/apache/cloudstack/pull/897.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 #897
    
----
commit bee8e87ead67d3d0fd7953f5e97b9327c88db2ba
Author: Nitin Kumar Maharana <ni...@citrix.com>
Date:   2015-09-28T18:39:15Z

    CLOUDSTACK-8919: Slow UI response while loading the list of networks in network tab.
    
    Instead of searching for each network, now it is searching for each zone.
    For basic zone, it will show the security group directly because by default securitygroupsenabled is true.
    For advanced zone, check the securitygroupsenabled option in each zone. If any one has value true, then show.

----


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: CLOUDSTACK-8919: Slow UI response while l...

Posted by borisroman <gi...@git.apache.org>.
Github user borisroman commented on the pull request:

    https://github.com/apache/cloudstack/pull/897#issuecomment-152995832
  
    @remibergsma 2 LGTM's so it can be merged at your discretion. 


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: CLOUDSTACK-8919: Slow UI response while l...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

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


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: CLOUDSTACK-8919: Slow UI response while l...

Posted by nitin-maharana <gi...@git.apache.org>.
Github user nitin-maharana commented on the pull request:

    https://github.com/apache/cloudstack/pull/897#issuecomment-152412317
  
    Thanks @sudhansu7. I had also the similar idea. @remibergsma @runseb please look at the comments of sudhansu. Thanks.


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: CLOUDSTACK-8919: Slow UI response while l...

Posted by nitin-maharana <gi...@git.apache.org>.
Github user nitin-maharana commented on the pull request:

    https://github.com/apache/cloudstack/pull/897#issuecomment-153093925
  
    Hi @remibergsma, I tried rebasing with current master. There is no conflict as such.
    
    I think you were trying to merge the PR #987, But this PR is #897.
    And from the log I can see the conflicts are related to PR #987.


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: CLOUDSTACK-8919: Slow UI response while l...

Posted by sudhansu7 <gi...@git.apache.org>.
Github user sudhansu7 commented on the pull request:

    https://github.com/apache/cloudstack/pull/897#issuecomment-152273822
  
    @remibergsma  @runseb 
    I have below performance analysis, which I did some time back. I trying to find out the dbdump to do a real test. But below analysis will may help to understand the issue and the solution.
    
    Clicking 'Network' tab invokes 3 api as mentioned below.
     
    http://localhost:8080/client/api?command=listZones&response=json&sessionkey=1ddeSxQjc604bdnHJegYqkM6EgA%3D&networktype=Advanced&_=1436356355027 -- 371ms
    this is to enable vpc, vpnCustomerGateway menu option.
     
    http://localhost:8080/client/api?command=listNetworks&response=json&sessionkey=1ddeSxQjc604bdnHJegYqkM6EgA%3D&supportedServices=SecurityGroup&listAll=true&details=min&_=1436356355424 -- 18.97s
    this is to enable securityGroups menu option. 
    
    
    http://localhost:8080/client/api?command=listNetworks&response=json&sessionkey=1ddeSxQjc604bdnHJegYqkM6EgA%3D&listAll=true&page=1&pagesize=20&_=1436356374437 -- 1.54s
    to list networks
     
    Second API call is taking 90% of the total response time.This api fetches all networks and interates over each network and for each network it makes an db call to fetch the services associated with the network. This is an expensive operation. 
     
    Solution: 
    ![image006](https://cloud.githubusercontent.com/assets/1062642/10827976/dbc6e066-7e97-11e5-8aec-09e0a84c1dc2.png)
    We can fetch listZones of type basic, if present then we can enable securityGroups menu option. For advanced zone with securitygroup service we can reuse first api call and can check "securitygroupsenabled" attribute in response. If present we will enable securityGroups menu option.
     
    http://localhost:8080/client/api?command=listZones&response=json&sessionkey=JwxpVL74Wk6ZS7MvzSw0u6%2FA9eU%3D&networktype=Advanced&_=1436357831259 --256ms
     
    http://localhost:8080/client/api?command=listZones&response=json&sessionkey=JwxpVL74Wk6ZS7MvzSw0u6%2FA9eU%3D&networktype=Basic&_=1436357831901 --11ms
     
    http://localhost:8080/client/api?command=listNetworks&response=json&sessionkey=JwxpVL74Wk6ZS7MvzSw0u6%2FA9eU%3D&listAll=true&page=1&pagesize=20&_=1436357831968 --868s
     
    total : 1.19s
    
    



---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: CLOUDSTACK-8919: Slow UI response while l...

Posted by karuturi <gi...@git.apache.org>.
Github user karuturi commented on the pull request:

    https://github.com/apache/cloudstack/pull/897#issuecomment-152993596
  
    manually verified the fix.
    Before the fix:
    on list networks page, I see three api calls
    1. list zones
    2. list networks with SG groups
    3. list networks
    
    After the fix:
    I see the below api call
    1. list zone basic
    2. list zone advanced
    3. a single list networks call 
    
    though I didnt see any performance improvement in my simple setup with 2 networks, the change is working fine and didnt see any issues because of it.
    
    :+1: LGTM


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: CLOUDSTACK-8919: Slow UI response while l...

Posted by remibergsma <gi...@git.apache.org>.
Github user remibergsma commented on the pull request:

    https://github.com/apache/cloudstack/pull/897#issuecomment-153008102
  
    This PR has a conflict now, can someone resolve it?
    
    ```
    From https://github.com/apache/cloudstack
     * [new ref]         refs/pull/987/head -> pr/987
    Auto-merging server/src/com/cloud/network/router/CommandSetupHelper.java
    Auto-merging plugins/hypervisors/kvm/test/com/cloud/hypervisor/kvm/resource/LibvirtComputingResourceTest.java
    Auto-merging engine/schema/src/com/cloud/network/dao/NetworkVO.java
    Auto-merging api/src/com/cloud/agent/api/to/LoadBalancerTO.java
    CONFLICT (content): Merge conflict in api/src/com/cloud/agent/api/to/LoadBalancerTO.java
    Automatic merge failed; fix conflicts and then commit the result.
    ERROR: Merge failed, aborting.
    ```


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: CLOUDSTACK-8919: Slow UI response while l...

Posted by remibergsma <gi...@git.apache.org>.
Github user remibergsma commented on the pull request:

    https://github.com/apache/cloudstack/pull/897#issuecomment-152214761
  
    @nitin-maharana I looked at this, seems good. What is the best way to test this or see the difference?


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: CLOUDSTACK-8919: Slow UI response while l...

Posted by bhaisaab <gi...@git.apache.org>.
Github user bhaisaab commented on the pull request:

    https://github.com/apache/cloudstack/pull/897#issuecomment-147089728
  
    LGTM (reviewed the changes, did not test it 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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: CLOUDSTACK-8919: Slow UI response while l...

Posted by runseb <gi...@git.apache.org>.
Github user runseb commented on the pull request:

    https://github.com/apache/cloudstack/pull/897#issuecomment-145662988
  
    thanks @nitin-maharana maybe we should have a small performance study to show that it actually speeds things up


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack pull request: CLOUDSTACK-8919: Slow UI response while l...

Posted by remibergsma <gi...@git.apache.org>.
Github user remibergsma commented on the pull request:

    https://github.com/apache/cloudstack/pull/897#issuecomment-153125931
  
    Hi @nitin-maharana hmm all those numbers ;-) sorry dude!


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---