Search in sources :

Example 1 with CausePersistenceManager

use of de.dagere.peass.measurement.rca.CausePersistenceManager in project peass by DaGeRe.

the class RCALevelContinueStarter method call.

@Override
public Void call() throws Exception {
    final CauseSearchFolders folders = new CauseSearchFolders(projectFolder);
    final File resultFile = getResultFile(folders);
    final File resultFileFull = getFullResultFile(folders);
    if (resultFile != null && resultFileFull != null) {
        final CauseSearchData data = Constants.OBJECTMAPPER.readValue(resultFile, CauseSearchData.class);
        final CauseSearchData dataFull = Constants.OBJECTMAPPER.readValue(resultFileFull, CauseSearchData.class);
        final CauseSearchFolders alternateFolders = createAlternateFolders(folders);
        final BothTreeReader reader = new BothTreeReader(data.getCauseConfig(), data.getMeasurementConfig(), folders, new EnvironmentVariables());
        reader.readCachedTrees();
        CausePersistenceManager persistenceManager = new CausePersistenceManager(data, dataFull, alternateFolders);
        EnvironmentVariables emptyEnv = new EnvironmentVariables();
        final CauseTester measurer = new CauseTester(alternateFolders, data.getMeasurementConfig(), data.getCauseConfig(), emptyEnv);
        final LevelCauseSearcher tester = new LevelCauseSearcher(measurer, persistenceManager, emptyEnv);
        final List<CallTreeNode> currentVersionNodeList = new LinkedList<>();
        final List<CallTreeNode> currentPredecessorNodeList = new LinkedList<>();
        new LevelManager(currentVersionNodeList, currentPredecessorNodeList, reader).goToLastMeasuredLevel(data.getNodes());
        tester.isLevelDifferent(currentPredecessorNodeList, currentVersionNodeList);
    }
    return null;
}
Also used : CauseSearchFolders(de.dagere.peass.folders.CauseSearchFolders) CausePersistenceManager(de.dagere.peass.measurement.rca.CausePersistenceManager) EnvironmentVariables(de.dagere.peass.execution.utils.EnvironmentVariables) CauseTester(de.dagere.peass.measurement.rca.CauseTester) CallTreeNode(de.dagere.peass.measurement.rca.data.CallTreeNode) CauseSearchData(de.dagere.peass.measurement.rca.data.CauseSearchData) LevelCauseSearcher(de.dagere.peass.measurement.rca.searcher.LevelCauseSearcher) LevelManager(de.dagere.peass.measurement.rca.LevelManager) BothTreeReader(de.dagere.peass.measurement.rca.kieker.BothTreeReader) File(java.io.File) LinkedList(java.util.LinkedList)

Aggregations

EnvironmentVariables (de.dagere.peass.execution.utils.EnvironmentVariables)1 CauseSearchFolders (de.dagere.peass.folders.CauseSearchFolders)1 CausePersistenceManager (de.dagere.peass.measurement.rca.CausePersistenceManager)1 CauseTester (de.dagere.peass.measurement.rca.CauseTester)1 LevelManager (de.dagere.peass.measurement.rca.LevelManager)1 CallTreeNode (de.dagere.peass.measurement.rca.data.CallTreeNode)1 CauseSearchData (de.dagere.peass.measurement.rca.data.CauseSearchData)1 BothTreeReader (de.dagere.peass.measurement.rca.kieker.BothTreeReader)1 LevelCauseSearcher (de.dagere.peass.measurement.rca.searcher.LevelCauseSearcher)1 File (java.io.File)1 LinkedList (java.util.LinkedList)1