Hi Miq,
I will post the resolution here from the support thread for the
benefit of other admins.
The partial report generation with .NET reporting client is caused due
to the usage of peek() API against the Http response stream. Peek()
returns negative on not finding data in the response stream and
assumes it's the end of stream. This may not be true due to the async
nature of response stream. By replacing peek() with ReadLine(), we can
perform blocking reads until a new line or end-of-stream is reached.
An immediate fix until a patched download is available would be to
replace line#301 to line#337 in method getReport() in
ReportingAPIClient.cs with these lines:
String firstLine = null;
String str = String.Empty;
if (reader.Peek() >= 0)
{
firstLine = reader.ReadLine();
checkError(firstLine, reader);
}
if (fileName != null)
{
StreamWriter streamWriter = null;
streamWriter = new StreamWriter(fileName);
streamWriter.WriteLine(firstLine);
while ( (str = reader.ReadLine()) != null )
{
streamWriter.WriteLine(str);
}
streamWriter.Close();
}
else
{
if (firstLine != null)
{
Console.WriteLine(firstLine);
}
while ( (str = reader.ReadLine()) != null )
{
Console.WriteLine(reader.ReadLine());
}
}
reader.Close();
-Anirudh
On Sep 30, 9:45 pm, Miq <[EMAIL PROTECTED]> wrote:
> Submitted, thanks.
>
> On Sep 24, 7:21 pm, "Tony (Google)" <[EMAIL PROTECTED]> wrote:
>
> > Hi Miq,
>
> > Can you please submit a support request so we can promptly address
> > yourreportingissue?
>
> > To learn more how to submit a support request, please visit:
>
> >http://code.google.com/apis/apps/faq.html#contactsupport
>
> > Thanks,
>
> > --Tony
>
> > On Sep 22, 1:22 pm, Miq <[EMAIL PROTECTED]> wrote:
>
> > > I am very new to programming/coding and just started using google
> > > apps. I finally found a walkthrough on how to use thereportingAPIs
> > > and got them working to a point. I downloaded the .net api, compiled
> > > it to reportingapiclient.exe and can run reports against my domain.
> > > The issue is when I try to run the accounts report, I am only getting
> > > ~300 out of my 2200 users. I saw something about using compression to
> > > get larger reports by changing some xml elements. I don't have an xml
> > > file anywhere so I don't know what to do. Below is the command line I
> > > am using to get my partial report.
>
> > > reportingapiclient.exe --email [EMAIL PROTECTED] --password
> > > blahblahpassword --domain blah.blah.edu --report accounts --out
> > > overall.csv
>
> > > How can I get my entire domain? Anything is greatly appreciated.
> > > Wonder if any of these reports could ever be integrated into the admin
> > > panel so new folks like me could just click the report we wanted.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Apps APIs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/google-apps-apis?hl=en
-~----------~----~----~----~------~----~------~--~---