Skip to content

Commit

Permalink
Revert "Encrypted backups (3.3)"
Browse files Browse the repository at this point in the history
This reverts commit a4adb83
This reverts commit 851a766
This reverts commit 2f6aaa3
This reverts commit 9e41a86
This reverts commit 2baac7b.
  • Loading branch information
martinfurmanski committed Oct 4, 2017
1 parent 773e215 commit 6f92f89
Show file tree
Hide file tree
Showing 144 changed files with 1,289 additions and 4,583 deletions.
Expand Up @@ -33,7 +33,7 @@
import org.neo4j.commandline.arguments.Arguments;
import org.neo4j.commandline.arguments.OptionalBooleanArg;
import org.neo4j.commandline.arguments.common.OptionalCanonicalPath;
import org.neo4j.consistency.checking.full.ConsistencyFlags;
import org.neo4j.consistency.checking.full.CheckConsistencyConfig;
import org.neo4j.consistency.checking.full.ConsistencyCheckIncompleteException;
import org.neo4j.dbms.DatabaseManagementSystemSettings;
import org.neo4j.helpers.Strings;
Expand Down Expand Up @@ -184,7 +184,7 @@ public void execute( String[] args ) throws IncorrectUsage, CommandFailed
.runFullConsistencyCheck( storeDir, config, ProgressMonitorFactory.textual( System.err ),
FormattedLogProvider.toOutputStream( System.out ), fileSystem, verbose,
reportDir.toFile(),
new ConsistencyFlags(
new CheckConsistencyConfig(
checkGraph, checkIndexes, checkLabelScanStore, checkPropertyOwners ) );

if ( !consistencyCheckResult.isSuccessful() )
Expand Down
Expand Up @@ -25,7 +25,7 @@
import java.text.SimpleDateFormat;
import java.util.Date;

import org.neo4j.consistency.checking.full.ConsistencyFlags;
import org.neo4j.consistency.checking.full.CheckConsistencyConfig;
import org.neo4j.consistency.checking.full.ConsistencyCheckIncompleteException;
import org.neo4j.consistency.checking.full.FullCheck;
import org.neo4j.consistency.report.ConsistencySummaryStatistics;
Expand Down Expand Up @@ -90,18 +90,18 @@ public Result runFullConsistencyCheck( File storeDir, Config tuningConfiguration
throws ConsistencyCheckIncompleteException, IOException
{
return runFullConsistencyCheck( storeDir, tuningConfiguration, progressFactory, logProvider, verbose,
new ConsistencyFlags( tuningConfiguration ) );
new CheckConsistencyConfig( tuningConfiguration ) );
}

public Result runFullConsistencyCheck( File storeDir, Config config, ProgressMonitorFactory progressFactory,
LogProvider logProvider, boolean verbose, ConsistencyFlags consistencyFlags )
LogProvider logProvider, boolean verbose, CheckConsistencyConfig checkConsistencyConfig )
throws ConsistencyCheckIncompleteException, IOException
{
FileSystemAbstraction fileSystem = new DefaultFileSystemAbstraction();
try
{
return runFullConsistencyCheck( storeDir, config, progressFactory, logProvider,
fileSystem, verbose, consistencyFlags );
fileSystem, verbose, checkConsistencyConfig );
}
finally
{
Expand All @@ -123,15 +123,15 @@ public Result runFullConsistencyCheck( File storeDir, Config tuningConfiguration
boolean verbose ) throws ConsistencyCheckIncompleteException, IOException
{
return runFullConsistencyCheck( storeDir, tuningConfiguration, progressFactory, logProvider, fileSystem,
verbose, new ConsistencyFlags( tuningConfiguration ) );
verbose, new CheckConsistencyConfig( tuningConfiguration ) );
}

public Result runFullConsistencyCheck( File storeDir, Config config, ProgressMonitorFactory progressFactory,
LogProvider logProvider, FileSystemAbstraction fileSystem, boolean verbose,
ConsistencyFlags consistencyFlags ) throws ConsistencyCheckIncompleteException, IOException
CheckConsistencyConfig checkConsistencyConfig ) throws ConsistencyCheckIncompleteException, IOException
{
return runFullConsistencyCheck( storeDir, config, progressFactory, logProvider, fileSystem,
verbose, defaultReportDir( config, storeDir ), consistencyFlags );
verbose, defaultReportDir( config, storeDir ), checkConsistencyConfig );
}

@Deprecated
Expand All @@ -140,12 +140,12 @@ public Result runFullConsistencyCheck( File storeDir, Config tuningConfiguration
boolean verbose, File reportDir ) throws ConsistencyCheckIncompleteException, IOException
{
return runFullConsistencyCheck( storeDir, tuningConfiguration, progressFactory, logProvider, fileSystem,
verbose, reportDir, new ConsistencyFlags( tuningConfiguration ) );
verbose, reportDir, new CheckConsistencyConfig( tuningConfiguration ) );
}

public Result runFullConsistencyCheck( File storeDir, Config config, ProgressMonitorFactory progressFactory,
LogProvider logProvider, FileSystemAbstraction fileSystem, boolean verbose, File reportDir,
ConsistencyFlags consistencyFlags ) throws ConsistencyCheckIncompleteException, IOException
CheckConsistencyConfig checkConsistencyConfig ) throws ConsistencyCheckIncompleteException, IOException
{
Log log = logProvider.getLog( getClass() );
ConfiguringPageCacheFactory pageCacheFactory = new ConfiguringPageCacheFactory(
Expand All @@ -156,7 +156,7 @@ public Result runFullConsistencyCheck( File storeDir, Config config, ProgressMon
try
{
return runFullConsistencyCheck( storeDir, config, progressFactory, logProvider, fileSystem,
pageCache, verbose, reportDir, consistencyFlags );
pageCache, verbose, reportDir, checkConsistencyConfig );
}
finally
{
Expand All @@ -178,16 +178,16 @@ public Result runFullConsistencyCheck( final File storeDir, Config tuningConfigu
throws ConsistencyCheckIncompleteException
{
return runFullConsistencyCheck( storeDir, tuningConfiguration, progressFactory, logProvider, fileSystem,
pageCache, verbose, new ConsistencyFlags( tuningConfiguration ) );
pageCache, verbose, new CheckConsistencyConfig( tuningConfiguration ) );
}

public Result runFullConsistencyCheck( final File storeDir, Config config, ProgressMonitorFactory progressFactory,
final LogProvider logProvider, final FileSystemAbstraction fileSystem, final PageCache pageCache,
final boolean verbose, ConsistencyFlags consistencyFlags )
final boolean verbose, CheckConsistencyConfig checkConsistencyConfig )
throws ConsistencyCheckIncompleteException
{
return runFullConsistencyCheck( storeDir, config, progressFactory, logProvider, fileSystem, pageCache,
verbose, defaultReportDir( config, storeDir ), consistencyFlags );
verbose, defaultReportDir( config, storeDir ), checkConsistencyConfig );
}

@Deprecated
Expand All @@ -197,12 +197,12 @@ public Result runFullConsistencyCheck( final File storeDir, Config tuningConfigu
throws ConsistencyCheckIncompleteException
{
return runFullConsistencyCheck( storeDir, tuningConfiguration, progressFactory, logProvider, fileSystem,
pageCache, verbose, reportDir, new ConsistencyFlags( tuningConfiguration ) );
pageCache, verbose, reportDir, new CheckConsistencyConfig( tuningConfiguration ) );
}

public Result runFullConsistencyCheck( final File storeDir, Config config, ProgressMonitorFactory progressFactory,
final LogProvider logProvider, final FileSystemAbstraction fileSystem, final PageCache pageCache,
final boolean verbose, File reportDir, ConsistencyFlags consistencyFlags )
final boolean verbose, File reportDir, CheckConsistencyConfig checkConsistencyConfig )
throws ConsistencyCheckIncompleteException
{
Log log = logProvider.getLog( getClass() );
Expand Down Expand Up @@ -262,7 +262,7 @@ fileSystem, config, new SimpleLogService( logProvider, logProvider ), pageCache,
}
storeAccess.initialize();
DirectStoreAccess stores = new DirectStoreAccess( storeAccess, labelScanStore, indexes );
FullCheck check = new FullCheck( progressFactory, statistics, numberOfThreads, consistencyFlags );
FullCheck check = new FullCheck( progressFactory, statistics, numberOfThreads, checkConsistencyConfig );
summary = check.execute( stores, new DuplicatingLog( log, reportLog ) );
}
finally
Expand Down
Expand Up @@ -25,7 +25,7 @@
import java.util.List;
import java.util.Map;

import org.neo4j.consistency.checking.full.ConsistencyFlags;
import org.neo4j.consistency.checking.full.CheckConsistencyConfig;
import org.neo4j.consistency.checking.full.ConsistencyCheckIncompleteException;
import org.neo4j.helpers.Args;
import org.neo4j.helpers.Strings;
Expand Down Expand Up @@ -116,7 +116,7 @@ ConsistencyCheckService.Result run( String... args ) throws ToolFailureException
{
return consistencyCheckService.runFullConsistencyCheck( storeDir, tuningConfiguration,
ProgressMonitorFactory.textual( systemError ), logProvider, fs, verbose,
new ConsistencyFlags( tuningConfiguration ) );
new CheckConsistencyConfig( tuningConfiguration ) );
}
catch ( ConsistencyCheckIncompleteException e )
{
Expand Down
Expand Up @@ -25,22 +25,22 @@
import org.neo4j.consistency.ConsistencyCheckSettings;
import org.neo4j.kernel.configuration.Config;

public class ConsistencyFlags
public class CheckConsistencyConfig
{
private final boolean checkGraph;
private final boolean checkIndexes;
private final boolean checkLabelScanStore;
private final boolean checkPropertyOwners;

public ConsistencyFlags( Config tuningConfiguration )
public CheckConsistencyConfig( Config tuningConfiguration )
{
this( tuningConfiguration.get( ConsistencyCheckSettings.consistency_check_graph ),
tuningConfiguration.get( ConsistencyCheckSettings.consistency_check_indexes ),
tuningConfiguration.get( ConsistencyCheckSettings.consistency_check_label_scan_store ),
tuningConfiguration.get( ConsistencyCheckSettings.consistency_check_property_owners ) );
}

public ConsistencyFlags( boolean checkGraph,
public CheckConsistencyConfig( boolean checkGraph,
boolean checkIndexes,
boolean checkLabelScanStore,
boolean checkPropertyOwners )
Expand Down
Expand Up @@ -66,20 +66,20 @@ public class FullCheck
public FullCheck( Config tuningConfiguration, ProgressMonitorFactory progressFactory,
Statistics statistics, int threads )
{
this( progressFactory, statistics, threads, new ConsistencyFlags( tuningConfiguration ) );
this( progressFactory, statistics, threads, new CheckConsistencyConfig( tuningConfiguration ) );
}

public FullCheck( ProgressMonitorFactory progressFactory, Statistics statistics, int threads,
ConsistencyFlags consistencyFlags )
CheckConsistencyConfig checkConsistencyConfig )
{
this.statistics = statistics;
this.threads = threads;
this.progressFactory = progressFactory;
this.samplingConfig = new IndexSamplingConfig( Config.defaults() );
this.checkGraph = consistencyFlags.isCheckGraph();
this.checkIndexes = consistencyFlags.isCheckIndexes();
this.checkLabelScanStore = consistencyFlags.isCheckLabelScanStore();
this.checkPropertyOwners = consistencyFlags.isCheckPropertyOwners();
this.checkGraph = checkConsistencyConfig.isCheckGraph();
this.checkIndexes = checkConsistencyConfig.isCheckIndexes();
this.checkLabelScanStore = checkConsistencyConfig.isCheckLabelScanStore();
this.checkPropertyOwners = checkConsistencyConfig.isCheckPropertyOwners();
}

public ConsistencySummaryStatistics execute( DirectStoreAccess stores, Log log )
Expand Down

0 comments on commit 6f92f89

Please sign in to comment.