node.js - How to restrict the session to be stored only for specific api's using connect-couchdb in cloudant? -
i using connect-couchdb npm module save sessions in cloudant. have defined in app.js. have declared apis in app.js.
what happening is, when ever api called, entry made in cloudant. how avoid , make happen specific apis?
var cloudantstore = require('connect-couchdb')(session);  var cloudantoptions = { name: db_sessions,                          port: db_port,                         username: db_username,                         password: db_password,                         host: db_host,                         ssl: true };  app.use(cookieparser());   app.use(session({resave: 'false', saveuninitialized: 'false', secret: 'secret', store: new cloudantstore(cloudantoptions)}));  
 
Comments
Post a Comment