Zimbra offers Open Source email server software and shared calendar for Linux and the Mac
Go Back   Zimbra :: Forums > Zimbra Collaboration Suite > Developers

Welcome to the Zimbra :: Forums!
Welcome, if you would like to post a comment please register. We also encourage you to explore all things Zimbra with our team and members of the community.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 09-26-2007, 10:33 AM
raj raj is offline
Moderator
 
Posts: 768
Default SOAP API - “Total Quota Allotted” and ”Total Quota Used” for a doamin?

Hi..How can I find?
“Total Quota Allotted” to all users under a domain
”Total Quota Used” by all users under a domain
without looping the XML output from “GetQuotaUsageRequest” SOAP API request.

The problem I am facing is if I have large number of users (i.e: > 3000 or 7000 ) then looping each user and getting “limit” and “used” values takes too much time (taking more than 2-3 minutes or more per)

Any simpler way to get the values mention on the top for a domain would be really cool.

We have integrated full domain admin for zimbra in our hosting control panels but one of our customer has 8000+ small account on 1 server and getting “Total Quota Allotted” and ”Total Quota Used” is killing the thing due to too much looping.

Thanks
Raj
i2k2 Systems

************************************************** ***********
Possible Enhancement to SOAP API:
************************************************** ***********
it would be great of the following SOAP api return the result with the TOTALS so that we developeres dont have to LOOP 8139 times for the TOTALS info as in this example..

Current Implementation:
<GetQuotaUsageRequest xmlns="urn:zimbraAdmin" domain="domain.com" sortBy="totalUsed" offset="0"/>

<GetQuotaUsageResponse more="0" searchTotal="8139" xmlns="urn:zimbraAdmin">
<account limit="1048576" id="76186162-e992-476e-9671-2e7bb83ca03c" name="user1@domain.com" used="12340"/>
<account limit="1048576" id="7ed18521-7da5-4384-9551-fb872f1cec3e" name="user2@domain.com" used="20000"/>
<account limit="1048576" id="af1e354b-a37d-496e-b6e0-906f549ef720" name="user3@domain.com" used="0"/>
<account limit="1048576" id="1a9ef533-8f9b-4132-ac2d-0b24aa02e77b" name="user3@domain.com" used="50000"/>
.....
.....
</GetQuotaUsageResponse>
</soap:Body>
</soap:Envelope>

Enhanced Implementation:
<GetQuotaUsageResponse more="0" searchTotal="8139" TotalQuotaAlloted="xxx" TotalQuotaUsed="xxx" xmlns="urn:zimbraAdmin">
<account limit="1048576" id="76186162-e992-476e-9671-2e7bb83ca03c" name="user1@domain.com" used="12340"/>
<account limit="1048576" id="7ed18521-7da5-4384-9551-fb872f1cec3e" name="user2@domain.com" used="20000"/>
<account limit="1048576" id="af1e354b-a37d-496e-b6e0-906f549ef720" name="user3@domain.com" used="0"/>
<account limit="1048576" id="1a9ef533-8f9b-4132-ac2d-0b24aa02e77b" name="user3@domain.com" used="50000"/>
.....
.....
</GetQuotaUsageResponse>
</soap:Body>
</soap:Envelope>

TotalQuotaAlloted="xxx" = SUM of all the "limit" values
TotalQuotaUsed="xxx" = SUM of all the "used" values

Last edited by raj; 09-26-2007 at 10:59 AM..
Reply With Quote
  #2 (permalink)  
Old 10-05-2007, 07:13 AM
raj raj is offline
Moderator
 
Posts: 768
Default

i am sad..i guess got to write my own patch for this ;(
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Why Join?

Registering let's you ask questions, makes it easier to search, displays any files attached to posts, and notifies you about replies.

blog.zimbra.com




 

SEO by vBSEO ©2011, Crawlability, Inc.