Google Docs cannot save to alfresco

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-01-2013 07:06 PM
<ul>
<li>Linux (Ubuntu Precise, Ubuntu Quantal, Linux Mint Nadia)</li>
<li>alfresco-community-4.2.b linux installer</li>
<li>Tested with browser hitting port 8080 and with apache reverse proxy sitting in front of alfresco.</li>
<li>All alfrescos are not directly accessible from the internet, only from the LAN.</li>
</ul>
I have an alfresco 4.2.b instance which previously worked perfectly with Google Docs. Recently I tested google docs again and, while the document will open in Google Docs, when I click on "Save to Alfresco", the save fails with "Failed to save Google Doc to Alfresco."
I thought it might be a problem with just that instance (installed WAR files into distribution tomcat), so I installed 4.2.b from scratch into separate virtual machines using the bundled installer. Even with this fresh install however, saving in Google Docs fails the same way.
I've since tried on other alfresco installations (4.2.b, 4.2.c) and I get the same error in all of them.
My client machines are Linux (tested with chrome and firefox). In case it was a problem with my client, I tested on various other linux clients (some pristine virtual machines) and on a Windows 7 machine too. Same error.
In case it was possibly due to the google account I was using, I switched to another free account. That failed similarly.
Has anyone else seen this? How would I debug this? I have
tomcat/shared/classes/alfresco/extension/custom-log4j.properties
and have uncommented:
log4j.logger.org.alfresco.repo.googledocs=debug
but I still see nothing in the debug logs.
Thanks in advance for any pointers.
Gerald
- Labels:
-
Archive
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2013 01:14 PM
13:08:16,580 DEBUG [org.alfresco.integrations.google.docs.webscripts.SaveContent] Parsed JSON: {"majorVersion":"false","description":"1.3","nodeRef":"workspace://SpacesStore/b09f5c12-7b54-4082-be53-848206ffc7c7","override":"false"}
13:08:16,582 DEBUG [org.alfresco.integrations.google.docs.webscripts.SaveContent] Saving Node to Alfresco from Google: workspace://SpacesStore/b09f5c12-7b54-4082-be53-848206ffc7c7
13:08:16,589 DEBUG [org.alfresco.integrations.google.docs.webscripts.SaveContent] Check for Concurent Users.
13:08:16,589 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Check for Concurrent Editors (Edits that have occured in the last 600 seconds)
13:08:16,606 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] OAuth Access Token Exists
13:08:16,606 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Attempt to create OAuth Connection
13:08:16,833 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Connection Created
13:08:16,839 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Google Docs Client initiated
13:08:17,562 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Revisions Found
13:08:17,562 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Revisions within threshhold found
13:08:17,562 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Get Google Docs user metadata
13:08:17,573 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] OAuth Access Token Exists
13:08:17,573 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Attempt to create OAuth Connection
13:08:17,696 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Connection Created
13:08:17,702 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Google Docs Client initiated
13:08:17,820 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Get Google Docs user metadata
13:08:17,832 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] OAuth Access Token Exists
13:08:17,832 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Attempt to create OAuth Connection
13:08:18,140 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Connection Created
13:08:18,145 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Google Docs Client initiated
13:08:18,246 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Concurrent Edits: false
13:08:18,248 DEBUG [org.alfresco.integrations.google.docs.webscripts.SaveContent] NodeRef: workspace://SpacesStore/b09f5c12-7b54-4082-be53-848206ffc7c7; ContentType: document
13:08:18,249 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Node workspace://SpacesStore/b09f5c12-7b54-4082-be53-848206ffc7c7 locked by Google Docs
13:08:18,249 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Unlock Node workspace://SpacesStore/b09f5c12-7b54-4082-be53-848206ffc7c7 from Google Docs Editing
13:08:18,325 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Get Google Document for node: workspace://SpacesStore/b09f5c12-7b54-4082-be53-848206ffc7c7
13:08:18,332 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] OAuth Access Token Exists
13:08:18,332 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Attempt to create OAuth Connection
13:08:18,535 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Connection Created
13:08:18,541 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Google Docs Client initiated
13:08:18,552 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Current mimetype: application/vnd.openxmlformats-officedocument.wordprocessingml.document; Mimetype of Google Doc: application/vnd.openxmlformats-officedocument.wordprocessingml.document
13:08:18,556 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Export format: docx
13:08:18,556 DEBUG [org.alfresco.integrations.google.docs.service.GoogleDocsServiceImpl] Export URL: https://docs.google.com/feeds/download/documents/Export?docID=14fcAggm1eRkC8CG89i3j8x6KpUIo9GHt3X8s3...
</blockcode>
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2013 01:24 PM
I am sure you already know this, but the current export url format on google docs themselves is more like:
https://docs.google.com/document/d/{DocumentId}/export?format=docx
or
https://docs.google.com/document/export?format=docx&id={DocumentId}
I am not familiar enough with the code base to make the change myself in my own install, but I could probably poke around.
I know it must be frustrating at the mercy of Google who changes things without warning and on their own timelines.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2013 02:23 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2013 06:16 PM
I was unable to get this to work. I patched both amp files against alfresco.war and redeployed to my container (at /alfresco/tomcat/webapps) removing both the older .war file and the apps folder. I still could not save from google docs, nor create a new google doc from the share application.
i noticed the older google-docs-share jar was in alfresco/tomcat/webapps/WEB-INF/lib, so, on a lark i decided to run the two patches against the share.war app. again I removed all the older artifacts, rebooted my server, and then redeployed with the two freshly patched (alfresco and share) war files.
no luck, I am still unable to save from google docs.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2013 07:40 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2013 08:12 PM
/opt/alfresco/tomcat/webapps/alfresco/WEB-INF/lib$ ls alfresco-googledocs*alfresco-googledocs-repo-2.0.3-23.jar alfresco-googledocs-share-2.0.3-23.jar/opt/alfresco/tomcat/webapps/share/WEB-INF/lib$ ls alfresco-googledocs*alfresco-googledocs-repo-2.0.3-23.jar alfresco-googledocs-share-2.0.3-23.jar
You'll need to tell me which log i should be posting – nothing is going to the main catalina log (sorry I'm new with this system)
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2013 09:17 PM

We are looking for the alfresco.log file.
It does look like you cross installed them (which shouldn't be causing the issue you are seeing, but we will want to clean that up eventually). First lets look at the alfresco.log file. You should see in it a section that will state the number of modules found and which ones it is starting or installing. It should look like this:
22:39:34,488 INFO [org.alfresco.repo.module.ModuleServiceImpl] Found 1 module(s).22:39:34,583 INFO [org.alfresco.repo.module.ModuleServiceImpl] Starting module 'org.alfresco.integrations.google.docs' version 2.0.3
Just post that section and we will try to move forward from there.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2013 09:49 PM
01:38:58,204 INFO [org.alfresco.repo.module.ModuleServiceImpl] Starting module 'org.alfresco.integrations.google.docs' version 2.0.3.01:38:58,554 INFO [org.alfresco.repo.module.ModuleServiceImpl] Starting module 'org.alfresco.integrations.share.google.docs' version 2.0.3.
I saw this pop up a little later.
01:39:23,516 INFO [org.alfresco.repo.management.subsystems.ChildApplicationContextFactory] Starting 'googledocs' subsystem, ID: [googledocs, v2]01:39:23,911 INFO [org.alfresco.repo.management.subsystems.ChildApplicationContextFactory] Startup of 'googledocs' subsystem, ID: [googledocs, v2] complete
Good news is that I was able to create a document in google docs and then save it back to alfresco, but now the file isn't displaying in the alfresco file viewer. I get an error pop up that says "The preview could not be loaded from the server"
the trace im getting in the log looks like
Caused by: org.alfresco.scripts.ScriptException: 04230089 Failed to execute script 'classpath*:alfresco/templates/webscripts/org/alfresco/repository/thumbnail/thumbnail.get.js': 04230088 Failed to create directory for file storage: /opt/alfresco/tomcat/temp/Alfresco/2013/5/23/1/44
getting closer though!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2013 09:56 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2013 10:06 PM
