stackvana / hook.io

Open-Source Microservice Hosting Platform
https://hook.io
Other
1.27k stars 119 forks source link

Refactor asset caching code / Remove all `fs` calls inside worker #136

Closed Marak closed 9 years ago

Marak commented 9 years ago

We are close to moving to a completely immutable server setup.

As of today, the worker no longer has write access to the file-system.

The worker still has asset caching code ( hook / view / presenter ) which writes to the fs system. This legacy caching code was primarily used for early debugging and we can remove it.

Moving forward, these assets will be cached in the couchdb document ( for now ). Since we are already fetching the document during the execution chain, this should actually now speed things up.

When the number of HTML fragments for views increases, we might want to consider moving to something like memcached to relieve possible strain on the couch.

Related #134

Marak commented 9 years ago

This is completed and working locally.

A bit more testing is required.

Deployment will be waterfalled with #117

Marak commented 9 years ago

Completed and deployed.