ytrstu / vosao

Automatically exported from code.google.com/p/vosao
GNU Lesser General Public License v2.1
0 stars 0 forks source link

Installing plugins sometimes trashes system #301

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
I don't know how to accurately describe this one (I haven't gone into any 
detail by looking at the plugin installation code) - but sometimes when I 
remove/install plugins (I do that often as I'm testing one in development) it 
seems to not full uninstall or install (some class files might not be fully 
installed or some records may not be removed)... this causes ugly error 
messages and I can't access anything. The way I resolve it is to remove the 
plugin records by going to the app engine control panel/data viewer and 
manually removing the records... however... memcache still has the site 
cached... and since I can't reset the cache it will keep the error displaying 
until I somehow clear it. Currently this is a bit of a task to overcome... I've 
used a python script to clear memcache which works almost always (except I 
ended up getting an error in that script later on). So here is what I'm asking:

1. Is it possible to catch plugin error exceptions and stop it from crashing 
the system?
2. Is there a way to remove all traces of the plugin (as we discussed earlier.. 
an install log file might help with that). I don't know if this is part of the 
install/uninstall code you've done since.
3. Is there a way we can reset memcache if this ever happens (easily).
4. Could it be transactional? It would be good if the whole process was 
transactional and you could do a rollback if it didn't install/uninstall 
properly. Maybe this point relates to point 1?

Original issue reported on code.google.com by rquast%e...@gtempaccount.com on 6 Aug 2010 at 1:02

GoogleCodeExporter commented 8 years ago
When I say plugin error exceptions.. they are usually class not found 
exceptions.

Original comment by rquast%e...@gtempaccount.com on 6 Aug 2010 at 1:05

GoogleCodeExporter commented 8 years ago
1. Could you please give some traces of plugin error exceptions.
2. When plugin is installed it saves a list of imported resources and when it's 
uninstalled it removes all resources from this list.
3. You can reset cache by hitting URL /_ah/reset_cache or from Site 
configuration page.
4. GAE supports transactions only within entity group. Vosao doesn't use entity 
groups.

Also consider 30 sec limit which can break you plugin installation. Also 
sometimes GAE can drop your request with phrase after less then 30 sec limit:

 "Request was aborted after waiting too long to attempt to service your request. This may happen sporadically when the App Engine serving cluster is under unexpectedly high or uneven load. If you see this message frequently, please contact the App Engine team.".

Why don't you use local development environment? I use it first for developing 
plugin functionality. Final step is to go to GAE and check it there.

Original comment by kinyelo@gmail.com on 6 Aug 2010 at 8:25

GoogleCodeExporter commented 8 years ago
Hah, yes I know I should be doing it locally, but I've been really slack in 
learning how to set that up. I've basically finished most of the code for the 
plugins now so I don't really need to learn how to set it up well. A more 
detailed dev guide for setting up Vosao locally would have been helpful (if 
anyone out there is interested in writing one).

I'm pretty sure I get the issue when the system is under high load like you 
say. It's only happend about 3 times out of the 60 or so I've 
installed/uninstalled the plugins.

Original comment by rquast%e...@gtempaccount.com on 6 Aug 2010 at 9:34

GoogleCodeExporter commented 8 years ago
The next time it happens I'll give you a full stack trace. The last time it 
happend it said one of the classes (that is in the plugin) wasn't found.. which 
made me think it didn't fully install.

Thanks heaps for the tip on the cache reset!

Original comment by rquast%e...@gtempaccount.com on 6 Aug 2010 at 9:37

GoogleCodeExporter commented 8 years ago
Currently plugin resources are placed into the Datastore. This can have 
performance penalties for large plugins.

Another approach that could be used for large plugins is to place all Java 
classes and plugin support libraries into Vosao distribution and leave plugin 
WAR as light as possible.

This reduces the flexibility of updating this plugin online but saves 
peformance.

Original comment by kinyelo@gmail.com on 22 Aug 2010 at 7:27