Skip to content

b37t1td/virtualfs-template

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Virtual FS template

Build Status

Virtual FS is a general inmemory chaching template

TODO

  • Inmemory json fs
  • List of files and folders
  • Read files
  • System (utimens, truncate)
  • Create directories
  • Remove directories
  • Create files
  • Remove files
  • Write into files
  • Handle rename

** Moving flat format as most useful and stable **

  • Crypto-cache caching
  • Middleware calls
  • Separete encrypted cache from package
  • Secure fs premissions

** Dummy middleware Template v0.2 **

var debouncy = require('debouncy');

var sync = debouncy(function(data) {
  return data;
}, 1000, null);

var Dummy = function() {

};

Dummy.prototype.fetch = function(json, callback) {
  setTimeout(function() {
    return callback(null, 'hello world');
  }, 2000);
};

Dummy.prototype.sync = function(json, callback) {
  sync(json);
  callback();
};

Dummy.prototype.post = function(json, buffer, callback) {
  callback();
};

Dummy.prototype.del = function(json, callback) {
  callback();
};

module.exports = Dummy;

** Mounted filesystem tests **

  • Tests for mountpoints
  • Test readdir listing
  • Test file writes
  • Test symlinks
  • Test directories mk/rm
  • Test file moving
  • Test removes
  • Test recursive removes

LiCENSE

BSD