Metadata
- Source
- DECA-225
- Type
- Task
- Priority
- Blocker
- Status
- Closed
- Resolution
- Fixed
- Assignee
- N/A
- Reporter
- Justin Obara
- Created
2012-01-19T14:59:02.277-0500 - Updated
2012-05-18T14:19:36.223-0400 - Versions
- N/A
- Fixed Versions
-
- 0.5
- Component
-
- Server
Description
Currently there is too much coupling between mountApp and startServer. To be able to start the server you have to mount an app and to be able to mount an app you have to get the resources from the startServer function. Move the resources into mountApp and return them, so that the startServer can use it. This will allow the unit test to just mount the app and not actually start the server.
Comments
-
Justin Obara commented
2012-01-19T15:31:45.443-0500 I was able to remove the coupling by reverting to a similar style as was in effect before DECA-195, using cherrypy.engine.start instead of cherrypy.quickstart. I was able to prevent a return of DECA-195 by subscribing to signal and console control handlers, and telling cherrypy to block with cherrypy.engine.block()
The changes are currently in my bitbucket repo
https://bitbucket.org/jobara/decapod-server-restThe example that helped me
http://groups.google.com/group/cherrypy-users/browse_thread/thread/b347284512e2c6c1?fwc=1 -
Justin Obara commented
2012-01-20T08:22:28.632-0500 Made a small update to only block when running in standalone.
See example: http://tools.cherrypy.org/wiki/ScgiWsgi
-
Justin Obara commented
2012-05-18T14:19:31.388-0400 Merged into the project repo