function deleteContext(id,flowId) {
    if (id === "global") {
        // 1. delete global from all configured stores
        var promises = [];
        for(var plugin in stores){
            if(stores.hasOwnProperty(plugin)){
                promises.push(stores[plugin].delete('global'));
            }
        }
        return Promise.all(promises).then(function() {
            // 2. delete global context
            delete contexts['global'];
            // 3. reinitialise global context
            initialiseGlobalContext();
        })
    } else if (!hasConfiguredStore) {
        // only delete context if there's no configured storage.
        var contextId = id;
        if (flowId) {
            contextId = id+":"+flowId;
        }
        delete contexts[contextId];
        return stores["_"].delete(contextId);
    } else {
        return Promise.resolve();
    }
}
Delete the context of the given node/flow/global

If the user has configured a context store, this
will no-op a request to delete node/flow context.