Skip to content

Commit

Permalink
Merge pull request #409 from datavisyn/mp/408_prov_graph_options
Browse files Browse the repository at this point in the history
Added options forwarding to provenance graph storage manager
  • Loading branch information
Christian Lehner authored Aug 11, 2020
2 parents 8f40716 + 900132e commit 35caff3
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 5 deletions.
6 changes: 5 additions & 1 deletion dist/ATDPApplication.d.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* Created by sam on 03.03.2017.
*/
import { ProvenanceGraph } from 'phovea_core';
import { ProvenanceGraph, IMixedStorageProvenanceGraphManagerOptions } from 'phovea_core';
import { AppHeader } from 'phovea_ui';
import 'phovea_ui/dist/webpack/_bootstrap';
import { CLUEGraphManager, LoginMenu, ACLUEWrapper } from 'phovea_clue';
Expand Down Expand Up @@ -45,6 +45,10 @@ export interface ITDPOptions {
* default: true
*/
enableProvenanceUrlTracking?: boolean;
/**
* options passed to the IProvenanceGraphManager
*/
provenanceManagerOptions?: IMixedStorageProvenanceGraphManagerOptions;
}
/**
* base class for TDP based applications
Expand Down
3 changes: 2 additions & 1 deletion dist/ATDPApplication.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/ATDPApplication.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 7 additions & 2 deletions src/ATDPApplication.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Created by sam on 03.03.2017.
*/

import {ProvenanceGraph, MixedStorageProvenanceGraphManager, UserSession, BaseUtils, I18nextManager, PluginRegistry} from 'phovea_core';
import {ProvenanceGraph, MixedStorageProvenanceGraphManager, UserSession, BaseUtils, I18nextManager, PluginRegistry, IMixedStorageProvenanceGraphManagerOptions} from 'phovea_core';
import {AppHeaderLink, AppHeader} from 'phovea_ui';
import 'phovea_ui/dist/webpack/_bootstrap';
import {CLUEGraphManager, LoginMenu, ButtonModeSelector, ACLUEWrapper, VisLoader} from 'phovea_clue';
Expand Down Expand Up @@ -59,6 +59,10 @@ export interface ITDPOptions {
* default: true
*/
enableProvenanceUrlTracking?: boolean;
/**
* options passed to the IProvenanceGraphManager
*/
provenanceManagerOptions?: IMixedStorageProvenanceGraphManagerOptions;
}

/**
Expand Down Expand Up @@ -149,7 +153,8 @@ export abstract class ATDPApplication<T> extends ACLUEWrapper {
const manager = new MixedStorageProvenanceGraphManager({
prefix: this.options.prefix,
storage: localStorage,
application: this.options.prefix
application: this.options.prefix,
...(this.options.provenanceManagerOptions || {})
});

this.cleanUpOld(manager);
Expand Down

0 comments on commit 35caff3

Please sign in to comment.