Package org.syncany.operations.up

Examples of org.syncany.operations.up.UpOperationOptions


    CleanupOperationOptions cleanupOptionsOnlyMergeDatabases = new CleanupOperationOptions();
    cleanupOptionsOnlyMergeDatabases.setMergeRemoteFiles(true);
    cleanupOptionsOnlyMergeDatabases.setRemoveOldVersions(false);

    UpOperationOptions upOperationOptionsNoCleanup = new UpOperationOptions();
    upOperationOptionsNoCleanup.setForceUploadEnabled(true);

    // Run preparations
    int[] clientUpSequence = new int[] {
        // Modeled after a crashing real-world scenario
        // 1 = A down+up, 2 = B down+up
View Full Code Here


    options.setMaxDatabaseFiles(7);

    StatusOperationOptions statusOptionsForceChecksum = new StatusOperationOptions();
    statusOptionsForceChecksum.setForceChecksum(true);

    UpOperationOptions upOperationOptionsWithCleanupForce = new UpOperationOptions();
    upOperationOptionsWithCleanupForce.setStatusOptions(statusOptionsForceChecksum);
    upOperationOptionsWithCleanupForce.setForceUploadEnabled(true);

    // Run preparations

    clientA.down();
    clientA.createNewFile("A-file.jpg");
View Full Code Here

    cleanupOptionsKeep1.setKeepVersionsCount(1);

    StatusOperationOptions statusOptionsForceChecksum = new StatusOperationOptions();
    statusOptionsForceChecksum.setForceChecksum(true);

    UpOperationOptions upNoCleanupForceChecksum = new UpOperationOptions();
    upNoCleanupForceChecksum.setStatusOptions(statusOptionsForceChecksum);

    UpOperationOptions upWithCleanupKeep1ForceChecksum = new UpOperationOptions();
    upWithCleanupKeep1ForceChecksum.setStatusOptions(statusOptionsForceChecksum);

    clientA.createNewFile("fileA");
    clientB.createNewFile("fileB");

    clientA.up(upNoCleanupForceChecksum);
View Full Code Here

    cleanupOptionsKeep1.setKeepVersionsCount(1);

    StatusOperationOptions statusOptionsForceChecksum = new StatusOperationOptions();
    statusOptionsForceChecksum.setForceChecksum(true);

    UpOperationOptions upNoCleanupForceChecksum = new UpOperationOptions();
    upNoCleanupForceChecksum.setStatusOptions(statusOptionsForceChecksum);

    UpOperationOptions upWithCleanupKeep1ForceChecksum = new UpOperationOptions();
    upWithCleanupKeep1ForceChecksum.setStatusOptions(statusOptionsForceChecksum);

    clientB.createNewFile("fileB");
    clientB.up(upNoCleanupForceChecksum);

    clientA.down();
View Full Code Here

    cleanupOptionsKeep1.setKeepVersionsCount(1);

    StatusOperationOptions statusOptionsForceChecksum = new StatusOperationOptions();
    statusOptionsForceChecksum.setForceChecksum(true);

    UpOperationOptions upNoCleanupForceChecksum = new UpOperationOptions();
    upNoCleanupForceChecksum.setStatusOptions(statusOptionsForceChecksum);

    UpOperationOptions upWithCleanupKeep1ForceChecksum = new UpOperationOptions();
    upWithCleanupKeep1ForceChecksum.setStatusOptions(statusOptionsForceChecksum);

    // First round

    clientB.createNewFile("fileA");
    clientB.up(upNoCleanupForceChecksum);
View Full Code Here

   
    TestClient clientA = new TestClient("A", testConnection);
    TestClient clientB = new TestClient("B", testConnection);
   
    // Run
    UpOperationOptions upOptionsForceEnabled = new UpOperationOptions();
    upOptionsForceEnabled.setForceUploadEnabled(true);
   
    clientA.createNewFile("A-file1.jpg", 50*1024);
    clientA.up(upOptionsForceEnabled);
       
    clientB.createNewFile("A-file1.jpg", 51*1024);
 
View Full Code Here

    TestClient clientD = new TestClient("D", testConnection);
 
    StatusOperationOptions statusOptions = new StatusOperationOptions();
    statusOptions.setForceChecksum(true);
   
    UpOperationOptions upOptionsForceEnabled = new UpOperationOptions();
    upOptionsForceEnabled.setStatusOptions(statusOptions);
    upOptionsForceEnabled.setForceUploadEnabled(true);
   
    CleanupOperationOptions cleanupOptions = new CleanupOperationOptions();
    cleanupOptions.setMinSecondsBetweenCleanups(0);

    // Run
View Full Code Here

    LocalTransferSettings testConnection = (LocalTransferSettings) TestConfigUtil.createTestLocalConnection();

    TestClient clientA = new TestClient("A", testConnection);
    TestClient clientB = new TestClient("B", testConnection);

    UpOperationOptions upOperationOptionsWithForce = new UpOperationOptions();
    upOperationOptionsWithForce.setForceUploadEnabled(true);

    // Client A creates some files
    clientA.getLocalFile("sphinxbase-0.8").mkdirs();
    clientA.getLocalFile("sphinxbase-0.8/win32/sphinx_jsgf2fsg").mkdirs();
    clientA.getLocalFile("sphinxbase-0.8/src/sphinx_adtools").mkdirs();
View Full Code Here

    LocalTransferSettings testConnection = (LocalTransferSettings) TestConfigUtil.createTestLocalConnection();   
   
    TestClient clientDzHome = new TestClient("Dz", testConnection);
    TestClient clientUxWork = new TestClient("Ux", testConnection);
       
    UpOperationOptions upOptionsWithForce = new UpOperationOptions();
    upOptionsWithForce.setForceUploadEnabled(true);

    // home -- generate some database versions so that the cleanup/merge will have something to merge   
    clientDzHome.createNewFile("someotherfile0.xml");
    clientDzHome.upWithForceChecksum();
View Full Code Here

    removeOldCleanupOperationOptions.setKeepVersionsCount(2);

    StatusOperationOptions forceChecksumStatusOperationOptions = new StatusOperationOptions();
    forceChecksumStatusOperationOptions.setForceChecksum(true);

    UpOperationOptions noCleanupAndForceUpOperationOptions = new UpOperationOptions();
    noCleanupAndForceUpOperationOptions.setForceUploadEnabled(true);
    noCleanupAndForceUpOperationOptions.setStatusOptions(forceChecksumStatusOperationOptions);

    // Run

    // A: Create some file versions
    clientA.createNewFile("file.jpg");
View Full Code Here

TOP

Related Classes of org.syncany.operations.up.UpOperationOptions

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.