Hi,

I'm currently writing a server which converts data from the datastore to a 
Google Spreadsheet. 

I'm not by trade a web developer, and my industry exposure in this field 
has been with rather esoteric developers, so I am content to accept that my 
approach is probably misguided - but it is what seemed correct from the 
reams of documentation I've read through.

For avoidance of doubt, I'm using the gdata.docs.client and and 
gdata.spreadsheet*s* APIs with OAuth, all in Python.

My approach (once all the OAuth palaver is resolved) is:
1. to create a new spreadsheet using the DocsClient.CreateResource method
2. to find the new spreadsheet key by searching through the spreadsheet 
feed (which strikes me as a bit roundabout)
3. to grab the first worksheet_id in the worksheet feed 
4. then to generate rows of data from the datastore, and either 
5a) add a task to a taskqueue to update a row in spreadsheet using a cell 
feed
5b) batch a series of updates to a row using a batch cell feed

With the 5a approach I ran into the issue that for large amounts of data, 
the cellfeeds would fail, generating 404 after a while. My assumption has 
been that this approach takes so long that the authentication times out, 
but I've not looked into that. Instead I got distracted by the promise of 
batching updates to the spreadsheet - 5b. This looks great, except that in 
spite of the documentation, there does not seem to be a Batch or 
ExecuteBatch method for the SpreadsheetsClient. So while the code is 
written, I can't test it!

I would like to move away from my approach in 5a, as it seems to take a 
good few seconds to write to each cell. An individual spreadsheet takes an 
eon to generate - though that may be due to my datamodel. 

I was wondering if anyone could criticise or validate my approach? Ideally, 
though it may be foolish, I would like to remain with the current API, 
rather than undoing the work I've already done.

Thanks,

Tom 

Reply via email to