Examples of unlockIndexer()


Examples of com.ngdata.hbaseindexer.model.api.WriteableIndexerModel.unlockIndexer()

                        "<field name='field1_s' value='family1:qualifier1'/>" +
                        "<field name='field2_s' value='family1:qualifier2'/>" +
                        "</indexer>"))
                .build();
        indexerModel.updateIndexer(indexerDef, lock);
        indexerModel.unlockIndexer(lock);
        waitOnEventsProcessed(1);

        put = new Put(b("row3"));
        put.add(b("family1"), b("qualifier2"), b("value1"));
        table.put(put);
View Full Code Here

Examples of com.ngdata.hbaseindexer.model.api.WriteableIndexerModel.unlockIndexer()

        indexerDef = new IndexerDefinitionBuilder()
                .startFrom(indexerModel.getFreshIndexer("indexer1"))
                .incrementalIndexingState(IncrementalIndexingState.DO_NOT_SUBSCRIBE)
                .build();
        indexerModel.updateIndexer(indexerDef, lock);
        indexerModel.unlockIndexer(lock);
        waitOnEventsProcessed(1);

        // Verify master removed the SEP subscription and unassigned the subscription ID
        SepTestUtil.waitOnReplicationPeerStopped(peerId("indexer1"));
        assertNull(indexerModel.getFreshIndexer("indexer1").getSubscriptionId());
View Full Code Here

Examples of com.ngdata.hbaseindexer.model.api.WriteableIndexerModel.unlockIndexer()

        indexerDef = new IndexerDefinitionBuilder()
                .startFrom(indexerModel.getFreshIndexer("indexer1"))
                .incrementalIndexingState(IncrementalIndexingState.SUBSCRIBE_DO_NOT_CONSUME)
                .build();
        indexerModel.updateIndexer(indexerDef, lock);
        indexerModel.unlockIndexer(lock);
        waitOnEventsProcessed(1);

        // Verify master registered the SEP subscription and assigned the subscription ID
        SepTestUtil.waitOnReplicationPeerReady(peerId("indexer1"));
        assertNotNull(indexerModel.getFreshIndexer("indexer1").getSubscriptionId());
View Full Code Here

Examples of com.ngdata.hbaseindexer.model.api.WriteableIndexerModel.unlockIndexer()

        indexerDef = new IndexerDefinitionBuilder()
                .startFrom(indexerModel.getFreshIndexer("indexer1"))
                .incrementalIndexingState(IncrementalIndexingState.SUBSCRIBE_AND_CONSUME)
                .build();
        indexerModel.updateIndexer(indexerDef, lock);
        indexerModel.unlockIndexer(lock);
        waitOnEventsProcessed(1);

        // Verify supervisor started the indexer
        assertEquals(1, main.getIndexerSupervisor().getRunningIndexers().size());
    }
View Full Code Here

Examples of com.ngdata.hbaseindexer.model.api.WriteableIndexerModel.unlockIndexer()

        indexerDef = new IndexerDefinitionBuilder()
                .startFrom(indexerModel.getFreshIndexer("indexer1"))
                .lifecycleState(IndexerDefinition.LifecycleState.DELETE_REQUESTED)
                .build();
        indexerModel.updateIndexer(indexerDef, lock);
        indexerModel.unlockIndexer(lock);
        waitOnEventsProcessed(1);

        // Check index was removed
        try {
            indexerModel.getFreshIndexer("indexer1");
View Full Code Here

Examples of com.ngdata.hbaseindexer.model.api.WriteableIndexerModel.unlockIndexer()

            }
        } finally {
            // In case we requested deletion of an index, it might be that the lock is already removed
            // by the time we get here as part of the index deletion.
            boolean ignoreMissing = lifecycleState != null && lifecycleState == IndexerDefinition.LifecycleState.DELETE_REQUESTED;
            model.unlockIndexer(lock, ignoreMissing);
        }

        return indexerDefinition;
    }
View Full Code Here

Examples of com.ngdata.hbaseindexer.model.api.WriteableIndexerModel.unlockIndexer()

                indexerModel.updateIndexer(new IndexerDefinitionBuilder()
                        .startFrom(index)
                        .incrementalIndexingState(IndexerDefinition.IncrementalIndexingState.DO_NOT_SUBSCRIBE)
                        .build(), lock);
            } finally {
                indexerModel.unlockIndexer(lock);
            }

            lilyProxy.getHBaseProxy().waitOnReplicationPeerStopped(subscriptionId);

            // Create record
View Full Code Here

Examples of com.ngdata.hbaseindexer.model.api.WriteableIndexerModel.unlockIndexer()

                        .startFrom(index)
                        .batchIndexingState(IndexerDefinition.BatchIndexingState.BUILD_REQUESTED)
                        .batchIndexCliArguments(batchCliArgs);
                model.updateIndexer(builder.build(), lock);
            } finally {
                model.unlockIndexer(lock);
            }
        } catch (Exception e) {
            throw new Exception("Error launching batch index build.", e);
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.