Package org.infinispan.schematic.document

Examples of org.infinispan.schematic.document.Document.containsField()


                return projectionsByWorkspace;
            }
            Document externalSources = federation.getDocument(FieldName.EXTERNAL_SOURCES);
            for (String sourceName : externalSources.keySet()) {
                Document externalSource = externalSources.getDocument(sourceName);
                if (!externalSource.containsField(FieldName.PROJECTIONS)) {
                    continue;
                }

                for (Object projectionExpression : externalSource.getArray(FieldName.PROJECTIONS)) {
                    ProjectionConfiguration projectionConfiguration = new ProjectionConfiguration(sourceName,
View Full Code Here


        Document info = doc.getDocument(DocumentTranslator.CHILDREN_INFO);
        assertThat(info.getLong(DocumentTranslator.COUNT), is(expectedChildCount));
        assertThat(info.getString(DocumentTranslator.NEXT_BLOCK), is(expectedNextBlock));
        assertThat(info.getString(DocumentTranslator.LAST_BLOCK), is(expectedLastBlock));
        if (firstBlock) {
            assertThat(info.containsField(DocumentTranslator.BLOCK_SIZE), is(expectedNextBlock != null));
        } else {
            assertThat(info.getLong(DocumentTranslator.BLOCK_SIZE), is(expectedBlockSize));
        }
    }
}
View Full Code Here

            if (repositoryInfoEntry != null) {
                Document repoInfoDoc = repositoryInfoEntry.getContent();
                // we should only remove the repository info if it wasn't initialized successfully previously
                // in a cluster, it may happen that another node finished initialization while this node crashed (in which case we
                // should not remove the entry)
                if (!repoInfoDoc.containsField(REPOSITORY_INITIALIZED_AT_FIELD_NAME)) {
                    this.documentStore.localStore().remove(REPOSITORY_INFO_KEY);
                }
            }
        } finally {
            // if we have a global cluster-wide lock, make sure its released
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.