import java.util.concurrent.atomic.AtomicBoolean;
import java.util.stream.Stream;
import java.util.stream.StreamSupport;
import java.util.concurrent.atomic.AtomicBoolean;
import java.util.stream.Stream;
import java.util.stream.StreamSupport;
import org.apache.tinkerpop.gremlin.structure.Property;
import org.apache.tinkerpop.gremlin.structure.Vertex;
import org.apache.tinkerpop.gremlin.structure.VertexProperty;
import org.apache.tinkerpop.gremlin.structure.Property;
import org.apache.tinkerpop.gremlin.structure.Vertex;
import org.apache.tinkerpop.gremlin.structure.VertexProperty;
import org.onap.aai.champcore.exceptions.ChampMarshallingException;
import org.onap.aai.champcore.exceptions.ChampObjectNotExistsException;
import org.onap.aai.champcore.exceptions.ChampRelationshipNotExistsException;
import org.onap.aai.champcore.exceptions.ChampMarshallingException;
import org.onap.aai.champcore.exceptions.ChampObjectNotExistsException;
import org.onap.aai.champcore.exceptions.ChampRelationshipNotExistsException;
import org.onap.aai.champcore.model.ChampSchema;
import org.onap.aai.champcore.model.fluent.partition.CreateChampPartitionable;
import org.onap.aai.champcore.transform.TinkerpopChampformer;
import org.onap.aai.champcore.model.ChampSchema;
import org.onap.aai.champcore.model.fluent.partition.CreateChampPartitionable;
import org.onap.aai.champcore.transform.TinkerpopChampformer;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;
public abstract class AbstractTinkerpopChampGraph extends AbstractValidatingChampGraph {
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;
public abstract class AbstractTinkerpopChampGraph extends AbstractValidatingChampGraph {
private static final TinkerpopChampformer TINKERPOP_CHAMPFORMER = new TinkerpopChampformer();
private static final ObjectMapper OBJECT_MAPPER = new ObjectMapper();
private static final TinkerpopChampformer TINKERPOP_CHAMPFORMER = new TinkerpopChampformer();
private static final ObjectMapper OBJECT_MAPPER = new ObjectMapper();
- LOGGER.warn("Failed to unmarshall tinkerpop vertex during query, returning partial results", e);
+ LOGGER.warn(ChampCoreMsgs.CHAMPCORE_ABSTRACT_TINKERPOP_CHAMP_GRAPH_WARN,
+ "Failed to unmarshall tinkerpop vertex during query, returning partial results" + e.getMessage());
tx.commit(); //Danger ahead if this iterator is not completely consumed
//then the transaction cache will hold stale values
} catch (ChampTransactionException e) {
tx.commit(); //Danger ahead if this iterator is not completely consumed
//then the transaction cache will hold stale values
} catch (ChampTransactionException e) {
next = getChampformer().unmarshallRelationship(edges.next());
return true;
} catch (ChampUnmarshallingException e) {
next = getChampformer().unmarshallRelationship(edges.next());
return true;
} catch (ChampUnmarshallingException e) {
- LOGGER.warn("Failed to unmarshall tinkerpop edge during query, returning partial results", e);
+ LOGGER.warn(ChampCoreMsgs.CHAMPCORE_ABSTRACT_TINKERPOP_CHAMP_GRAPH_WARN,
+ "Failed to unmarshall tinkerpop edge during query, returning partial results" + e.getMessage());
//consumed, then the transaction cache will be stale
} catch (ChampTransactionException e) {
//consumed, then the transaction cache will be stale
} catch (ChampTransactionException e) {
next = getChampformer().unmarshallRelationship(query.next());
return true;
} catch (ChampUnmarshallingException e) {
next = getChampformer().unmarshallRelationship(query.next());
return true;
} catch (ChampUnmarshallingException e) {
- LOGGER.warn("Failed to unmarshall tinkerpop vertex during query, returning partial results", e);
+ LOGGER.warn(ChampCoreMsgs.CHAMPCORE_ABSTRACT_TINKERPOP_CHAMP_GRAPH_WARN,
+ "Failed to unmarshall tinkerpop vertex during query, returning partial results" + e.getMessage());
//consumed, then the transaction cache will be stale
} catch (ChampTransactionException e) {
//consumed, then the transaction cache will be stale
} catch (ChampTransactionException e) {