Move memory code out, add it as layer on top of existing donut code

Just like how http.Handlers can be overlayed on top of each other
with each implementing ServeHTTP().

drivers.Driver can be overlayed on top of each other in similar manner
which would implement the drivers.Driver interface.

   API <----> cache <----> donut <----> donut(format)
This commit is contained in:
Harshavardhana
2015-06-29 20:48:23 -07:00
parent fe3c618cc7
commit 8f61d6b6be
9 changed files with 192 additions and 667 deletions

View File

@@ -135,7 +135,7 @@ func runDonut(c *cli.Context) {
Fatalln("Path must be set")
}
apiServerConfig := getAPIServerConfig(c)
donutDriver := server.DonutFactory{
donutDriver := server.Factory{
Config: apiServerConfig,
Paths: paths,
MaxMemory: maxMemory,