61
Jenkinsfile
vendored
61
Jenkinsfile
vendored
@@ -18,28 +18,6 @@ pipeline {
|
||||
}
|
||||
|
||||
stages {
|
||||
stage("Docker images") {
|
||||
parallel {
|
||||
stage('Publish JDK 17 + Cassandra 5') {
|
||||
when {
|
||||
anyOf {
|
||||
changeset "ci/openjdk17-cassandra-5/**"
|
||||
changeset "ci/pipeline.properties"
|
||||
}
|
||||
}
|
||||
agent { label 'data' }
|
||||
options { timeout(time: 30, unit: 'MINUTES') }
|
||||
steps {
|
||||
script {
|
||||
def image = docker.build("springci/spring-data-with-cassandra-5:${p['java.main.tag']}", "--build-arg BASE=${p['docker.java.main.image']} --build-arg CASSANDRA=${p['docker.cassandra.3.version']} ci/openjdk17-cassandra-5/")
|
||||
docker.withRegistry(p['docker.registry'], p['docker.credentials']) {
|
||||
image.push()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage("test: baseline (main)") {
|
||||
when {
|
||||
@@ -60,11 +38,9 @@ pipeline {
|
||||
steps {
|
||||
script {
|
||||
docker.withRegistry(p['docker.proxy.registry'], p['docker.proxy.credentials']) {
|
||||
docker.image("springci/spring-data-with-cassandra-5:${p['java.main.tag']}").inside(p['docker.java.inside.docker']) {
|
||||
sh 'mkdir -p /tmp/jenkins-home'
|
||||
sh 'JAVA_HOME=/opt/java/openjdk17 /opt/cassandra/bin/cassandra -R &'
|
||||
docker.image(p['docker.java.main.image']).inside(p['docker.java.inside.docker']) {
|
||||
sh 'MAVEN_OPTS="-Duser.name=' + "${p['jenkins.user.name']}" + ' -Duser.home=/tmp/jenkins-home" ' +
|
||||
"./mvnw -s settings.xml -Pci,external-cassandra -Ddevelocity.storage.directory=/tmp/jenkins-home/.develocity-root -Dmaven.repo.local=/tmp/jenkins-home/.m2/spring-data-cassandra " +
|
||||
"./mvnw -s settings.xml -Pci,testcontainers-cassandra -Ddevelocity.storage.directory=/tmp/jenkins-home/.develocity-root -Dmaven.repo.local=/tmp/jenkins-home/.m2/spring-data-cassandra " +
|
||||
"clean dependency:list verify -Dsort -U -B"
|
||||
}
|
||||
}
|
||||
@@ -72,6 +48,39 @@ pipeline {
|
||||
}
|
||||
}
|
||||
|
||||
stage("Test other configurations") {
|
||||
when {
|
||||
beforeAgent(true)
|
||||
allOf {
|
||||
branch(pattern: "main|(\\d\\.\\d\\.x)", comparator: "REGEXP")
|
||||
not { triggeredBy 'UpstreamCause' }
|
||||
}
|
||||
}
|
||||
parallel {
|
||||
stage("test: baseline (next)") {
|
||||
agent {
|
||||
label 'data'
|
||||
}
|
||||
options { timeout(time: 30, unit: 'MINUTES') }
|
||||
environment {
|
||||
ARTIFACTORY = credentials("${p['artifactory.credentials']}")
|
||||
DEVELOCITY_ACCESS_KEY = credentials("${p['develocity.access-key']}")
|
||||
}
|
||||
steps {
|
||||
script {
|
||||
docker.withRegistry(p['docker.proxy.registry'], p['docker.proxy.credentials']) {
|
||||
docker.image(p['docker.java.next.image']).inside(p['docker.java.inside.docker']) {
|
||||
sh 'MAVEN_OPTS="-Duser.name=' + "${p['jenkins.user.name']}" + ' -Duser.home=/tmp/jenkins-home" ' +
|
||||
"./mvnw -s settings.xml -Pci,testcontainers-cassandra -Ddevelocity.storage.directory=/tmp/jenkins-home/.develocity-root -Dmaven.repo.local=/tmp/jenkins-home/.m2/spring-data-cassandra " +
|
||||
"clean dependency:list verify -Dsort -U -B"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage('Release to artifactory') {
|
||||
when {
|
||||
beforeAgent(true)
|
||||
|
||||
@@ -1,26 +0,0 @@
|
||||
ARG BASE
|
||||
FROM ${BASE}
|
||||
# Any ARG statements before FROM are cleared.
|
||||
ARG CASSANDRA
|
||||
|
||||
RUN set -eux; \
|
||||
CASSANDRA_URL="https://archive.apache.org/dist/cassandra/${CASSANDRA}/apache-cassandra-${CASSANDRA}-bin.tar.gz"; \
|
||||
sed -i -e 's/http/https/g' /etc/apt/sources.list ; \
|
||||
curl -LfsSo /tmp/cassandra.tar.gz ${CASSANDRA_URL}; \
|
||||
mkdir -p /opt/cassandra /opt/cassandra/data /opt/cassandra/logs; \
|
||||
cd /opt/cassandra; \
|
||||
tar -xf /tmp/cassandra.tar.gz --strip-components=1; \
|
||||
rm -rf /tmp/cassandra.tar.gz; \
|
||||
chmod -R a+rwx /opt/cassandra; \
|
||||
useradd -d /home/jenkins-docker -m -u 1001 -U jenkins-docker;
|
||||
|
||||
RUN set -eux; \
|
||||
BINARY_URL='https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.14%2B7/OpenJDK17U-jdk_x64_linux_hotspot_17.0.14_7.tar.gz'; \
|
||||
curl -LfsSo /tmp/openjdk.tar.gz ${BINARY_URL}; \
|
||||
mkdir -p /opt/java/openjdk17; \
|
||||
cd /opt/java/openjdk17; \
|
||||
tar -xf /tmp/openjdk.tar.gz --strip-components=1; \
|
||||
rm -rf /tmp/openjdk.tar.gz;
|
||||
|
||||
ENV MAX_HEAP_SIZE=1500M
|
||||
ENV HEAP_NEWSIZE=300M
|
||||
@@ -17,9 +17,6 @@ docker.mongodb.8.0.version=8.0.0
|
||||
docker.redis.6.version=6.2.13
|
||||
docker.redis.7.version=7.2.4
|
||||
|
||||
# Supported versions of Cassandra
|
||||
docker.cassandra.5.version=5.0.3
|
||||
|
||||
# Docker environment settings
|
||||
docker.java.inside.basic=-v $HOME:/tmp/jenkins-home
|
||||
docker.java.inside.docker=-u root -v /var/run/docker.sock:/var/run/docker.sock -v /usr/bin/docker:/usr/bin/docker -v $HOME:/tmp/jenkins-home
|
||||
|
||||
@@ -19,9 +19,9 @@ import static org.assertj.core.api.Assertions.*;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.junit.jupiter.api.extension.ExtendWith;
|
||||
|
||||
import org.springframework.core.io.ClassPathResource;
|
||||
import org.springframework.core.io.Resource;
|
||||
import org.springframework.data.cassandra.support.CassandraConnectionProperties;
|
||||
import org.springframework.data.cassandra.test.util.CassandraExtension;
|
||||
import org.springframework.lang.Nullable;
|
||||
|
||||
@@ -69,7 +69,12 @@ class AbstractSessionConfigurationIntegrationTests {
|
||||
|
||||
@Override
|
||||
protected int getPort() {
|
||||
return new CassandraConnectionProperties().getCassandraPort();
|
||||
return CassandraExtension.getResources().getPort();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String getContactPoints() {
|
||||
return CassandraExtension.getResources().getHost();
|
||||
}
|
||||
|
||||
@Nullable
|
||||
|
||||
@@ -17,9 +17,10 @@ package org.springframework.data.cassandra.config;
|
||||
|
||||
import static org.assertj.core.api.Assertions.*;
|
||||
|
||||
import org.junit.After;
|
||||
import org.junit.jupiter.api.AfterEach;
|
||||
import org.junit.jupiter.api.BeforeEach;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import org.springframework.context.ConfigurableApplicationContext;
|
||||
import org.springframework.context.annotation.AnnotationConfigApplicationContext;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
@@ -51,6 +52,10 @@ class CqlTemplateConfigIntegrationTests extends IntegrationTestsSupport {
|
||||
return CassandraExtension.getResources().getPort();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String getContactPoints() {
|
||||
return CassandraExtension.getResources().getHost();
|
||||
}
|
||||
}
|
||||
|
||||
private CqlSession session;
|
||||
@@ -63,7 +68,7 @@ class CqlTemplateConfigIntegrationTests extends IntegrationTestsSupport {
|
||||
this.session = context.getBean(CqlSession.class);
|
||||
}
|
||||
|
||||
@After
|
||||
@AfterEach
|
||||
void tearDown() {
|
||||
context.close();
|
||||
}
|
||||
|
||||
@@ -17,9 +17,10 @@ package org.springframework.data.cassandra.config;
|
||||
|
||||
import static org.assertj.core.api.Assertions.*;
|
||||
|
||||
import org.junit.After;
|
||||
import org.junit.jupiter.api.AfterEach;
|
||||
import org.junit.jupiter.api.BeforeEach;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import org.springframework.context.ConfigurableApplicationContext;
|
||||
import org.springframework.context.support.ClassPathXmlApplicationContext;
|
||||
import org.springframework.data.cassandra.core.CassandraOperations;
|
||||
@@ -49,7 +50,7 @@ class MinimalXmlConfigIntegrationTests extends IntegrationTestsSupport {
|
||||
this.session = context.getBean(CqlSession.class);
|
||||
}
|
||||
|
||||
@After
|
||||
@AfterEach
|
||||
void tearDown() {
|
||||
context.close();
|
||||
}
|
||||
|
||||
@@ -18,12 +18,12 @@ package org.springframework.data.cassandra.observability;
|
||||
import static org.assertj.core.api.Assertions.*;
|
||||
|
||||
import io.micrometer.core.instrument.MeterRegistry;
|
||||
import io.micrometer.core.instrument.simple.SimpleMeterRegistry;
|
||||
import io.micrometer.observation.ObservationRegistry;
|
||||
import io.micrometer.tracing.exporter.FinishedSpan;
|
||||
import io.micrometer.tracing.test.SampleTestRunner;
|
||||
|
||||
import org.junit.jupiter.api.extension.ExtendWith;
|
||||
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.data.cassandra.core.cql.CqlTemplate;
|
||||
import org.springframework.data.cassandra.test.util.CassandraExtension;
|
||||
@@ -38,7 +38,7 @@ import com.datastax.oss.driver.api.core.CqlSession;
|
||||
* @author Greg Turnquist
|
||||
* @author Mark Paluch
|
||||
*/
|
||||
@ExtendWith({ SpringExtension.class, CassandraExtension.class })
|
||||
@ExtendWith({ CassandraExtension.class, SpringExtension.class })
|
||||
@ContextConfiguration(classes = TestConfig.class)
|
||||
public class ImperativeIntegrationTests extends SampleTestRunner {
|
||||
|
||||
@@ -76,8 +76,6 @@ public class ImperativeIntegrationTests extends SampleTestRunner {
|
||||
|
||||
template.execute("INSERT INTO person (id,firstName,lastName) VALUES(?,?,?)", 1, "Walter", "White");
|
||||
|
||||
System.out.println(((SimpleMeterRegistry) meterRegistry).getMetersAsString());
|
||||
|
||||
assertThat(tracer.getFinishedSpans()).hasSizeGreaterThanOrEqualTo(5);
|
||||
|
||||
for (FinishedSpan finishedSpan : tracer.getFinishedSpans()) {
|
||||
@@ -88,4 +86,5 @@ public class ImperativeIntegrationTests extends SampleTestRunner {
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -18,7 +18,6 @@ package org.springframework.data.cassandra.observability;
|
||||
import static org.assertj.core.api.Assertions.*;
|
||||
|
||||
import io.micrometer.core.instrument.MeterRegistry;
|
||||
import io.micrometer.core.instrument.simple.SimpleMeterRegistry;
|
||||
import io.micrometer.observation.Observation;
|
||||
import io.micrometer.observation.ObservationRegistry;
|
||||
import io.micrometer.observation.contextpropagation.ObservationThreadLocalAccessor;
|
||||
@@ -42,7 +41,7 @@ import org.springframework.test.context.junit.jupiter.SpringExtension;
|
||||
*
|
||||
* @author Mark Paluch
|
||||
*/
|
||||
@ExtendWith({ SpringExtension.class, CassandraExtension.class })
|
||||
@ExtendWith({ CassandraExtension.class, SpringExtension.class })
|
||||
@ContextConfiguration(classes = TestConfig.class)
|
||||
public class ReactiveIntegrationTests extends SampleTestRunner {
|
||||
|
||||
@@ -88,9 +87,8 @@ public class ReactiveIntegrationTests extends SampleTestRunner {
|
||||
.verifyComplete();
|
||||
});
|
||||
|
||||
System.out.println(((SimpleMeterRegistry) meterRegistry).getMetersAsString());
|
||||
|
||||
assertThat(tracer.getFinishedSpans()).hasSizeGreaterThanOrEqualTo(5);
|
||||
};
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -35,8 +35,8 @@ import org.springframework.data.cassandra.core.mapping.CassandraMappingContext;
|
||||
import org.springframework.data.cassandra.core.mapping.CassandraPersistentEntity;
|
||||
import org.springframework.data.cassandra.core.mapping.SimpleUserTypeResolver;
|
||||
import org.springframework.data.cassandra.domain.User;
|
||||
import org.springframework.data.cassandra.support.CassandraConnectionProperties;
|
||||
import org.springframework.data.cassandra.support.RandomKeyspaceName;
|
||||
import org.springframework.data.cassandra.test.util.CassandraExtension;
|
||||
|
||||
import com.datastax.oss.driver.api.core.CqlIdentifier;
|
||||
import com.datastax.oss.driver.api.core.CqlSession;
|
||||
@@ -51,10 +51,11 @@ class CassandraOperationsProducer {
|
||||
@Produces
|
||||
@Singleton
|
||||
public CqlSession createSession() throws Exception {
|
||||
CassandraConnectionProperties properties = new CassandraConnectionProperties();
|
||||
|
||||
CassandraExtension.Resources resources = CassandraExtension.getResources();
|
||||
|
||||
return CqlSession.builder().addContactPoint(
|
||||
InetSocketAddress.createUnresolved(properties.getCassandraHost(), properties.getCassandraPort())).build();
|
||||
InetSocketAddress.createUnresolved(resources.getHost(), resources.getPort())).build();
|
||||
}
|
||||
|
||||
@Produces
|
||||
|
||||
@@ -22,10 +22,11 @@ import jakarta.enterprise.inject.se.SeContainerInitializer;
|
||||
|
||||
import java.util.Optional;
|
||||
|
||||
import org.junit.AfterClass;
|
||||
import org.junit.jupiter.api.AfterAll;
|
||||
import org.junit.jupiter.api.BeforeAll;
|
||||
import org.junit.jupiter.api.BeforeEach;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import org.springframework.data.cassandra.domain.User;
|
||||
import org.springframework.data.cassandra.test.util.IntegrationTestsSupport;
|
||||
|
||||
@@ -54,7 +55,7 @@ class CdiRepositoryTests extends IntegrationTestsSupport {
|
||||
.initialize();
|
||||
}
|
||||
|
||||
@AfterClass
|
||||
@AfterAll
|
||||
static void shutdown() throws Exception {
|
||||
cdiContainer.close();
|
||||
}
|
||||
|
||||
@@ -28,8 +28,8 @@ import org.springframework.data.cassandra.config.CqlSessionFactoryBean;
|
||||
import org.springframework.data.cassandra.config.SchemaAction;
|
||||
import org.springframework.data.cassandra.core.cql.keyspace.CreateKeyspaceSpecification;
|
||||
import org.springframework.data.cassandra.core.cql.keyspace.DropKeyspaceSpecification;
|
||||
import org.springframework.data.cassandra.support.CassandraConnectionProperties;
|
||||
import org.springframework.data.cassandra.support.RandomKeyspaceName;
|
||||
import org.springframework.data.cassandra.test.util.CassandraExtension;
|
||||
|
||||
/**
|
||||
* Setup any spring configuration for unit tests
|
||||
@@ -41,14 +41,16 @@ import org.springframework.data.cassandra.support.RandomKeyspaceName;
|
||||
@Configuration
|
||||
public class IntegrationTestConfig extends AbstractReactiveCassandraConfiguration {
|
||||
|
||||
private static final CassandraConnectionProperties PROPS = new CassandraConnectionProperties();
|
||||
private static final int PORT = PROPS.getCassandraPort();
|
||||
|
||||
private String keyspaceName = RandomKeyspaceName.create();
|
||||
|
||||
@Override
|
||||
protected int getPort() {
|
||||
return PORT;
|
||||
return CassandraExtension.getResources().getPort();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String getContactPoints() {
|
||||
return CassandraExtension.getResources().getHost();
|
||||
}
|
||||
|
||||
@Bean
|
||||
|
||||
@@ -17,6 +17,7 @@ package org.springframework.data.cassandra.support;
|
||||
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.data.cassandra.config.AbstractSessionConfiguration;
|
||||
import org.springframework.data.cassandra.test.util.CassandraExtension;
|
||||
|
||||
/**
|
||||
* Java-based configuration for integration tests using defaults for a smooth test run.
|
||||
@@ -27,11 +28,13 @@ import org.springframework.data.cassandra.config.AbstractSessionConfiguration;
|
||||
@Configuration
|
||||
public abstract class AbstractTestJavaConfig extends AbstractSessionConfiguration {
|
||||
|
||||
private static final CassandraConnectionProperties PROPERTIES = new CassandraConnectionProperties();
|
||||
|
||||
@Override
|
||||
protected int getPort() {
|
||||
return PROPERTIES.getCassandraPort();
|
||||
return CassandraExtension.getResources().getPort();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String getContactPoints() {
|
||||
return CassandraExtension.getResources().getHost();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -107,10 +107,10 @@ public class CassandraConnectionProperties extends Properties {
|
||||
@Override
|
||||
public String getProperty(String key) {
|
||||
|
||||
String value = super.getProperty(key);
|
||||
String value = System.getProperty(key);
|
||||
|
||||
if (value == null) {
|
||||
value = System.getProperty(key);
|
||||
value = super.getProperty(key);
|
||||
}
|
||||
|
||||
return value;
|
||||
|
||||
@@ -30,6 +30,7 @@ import org.springframework.data.cassandra.support.CassandraConnectionProperties;
|
||||
import org.springframework.data.cassandra.support.CqlDataSet;
|
||||
import org.springframework.data.util.Optionals;
|
||||
import org.springframework.lang.NonNull;
|
||||
import org.springframework.lang.Nullable;
|
||||
import org.springframework.util.Assert;
|
||||
import org.springframework.util.StringUtils;
|
||||
|
||||
@@ -76,7 +77,8 @@ class CassandraDelegate {
|
||||
|
||||
private CqlSessionBuilder sessionBuilder;
|
||||
|
||||
private Integer cassandraPort;
|
||||
private @Nullable String cassandraHost;
|
||||
private @Nullable Integer cassandraPort;
|
||||
|
||||
private final List<SessionCallback<Void>> after = new ArrayList<>();
|
||||
private final List<SessionCallback<Void>> before = new ArrayList<>();
|
||||
@@ -112,6 +114,18 @@ class CassandraDelegate {
|
||||
this.startupTimeout = startupTimeout;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the Cassandra host.
|
||||
*
|
||||
* @return the Cassandra host
|
||||
*/
|
||||
public String getHost() {
|
||||
|
||||
Assert.state(this.cassandraHost != null, "Cassandra host was not initialized");
|
||||
|
||||
return this.cassandraHost;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the Cassandra port.
|
||||
*
|
||||
@@ -279,6 +293,9 @@ class CassandraDelegate {
|
||||
container = getCassandraDockerImageName().map(CassandraContainer::new)
|
||||
.orElseGet(() -> new CassandraContainer("cassandra:5.0.3"));
|
||||
|
||||
container.withEnv("MAX_HEAP_SIZE", "1500M");
|
||||
container.withEnv("HEAP_NEWSIZE", "300M");
|
||||
|
||||
DockerImageName imageName = DockerImageName.parse(container.getDockerImageName());
|
||||
String versionPart = imageName.getVersionPart();
|
||||
Version version = Version.parse(versionPart);
|
||||
@@ -289,10 +306,11 @@ class CassandraDelegate {
|
||||
}
|
||||
container.start();
|
||||
|
||||
log.info("Running with Cassandra Docker Testcontainer Image Name [{}]", container.getDockerImageName());
|
||||
log.info("Running with Cassandra Docker Testcontainer Image Name [{}] at [{}]", container.getDockerImageName(),
|
||||
container.getMappedPort(9042));
|
||||
|
||||
this.properties.setCassandraHost(container.getContainerIpAddress());
|
||||
this.properties.setCassandraPort(container.getFirstMappedPort());
|
||||
this.properties.setCassandraHost(container.getContactPoint().getHostString());
|
||||
this.properties.setCassandraPort(container.getMappedPort(9042));
|
||||
this.properties.update();
|
||||
}
|
||||
}
|
||||
@@ -310,6 +328,7 @@ class CassandraDelegate {
|
||||
|
||||
private synchronized void initializeConnection() {
|
||||
|
||||
this.cassandraHost = resolveHost();
|
||||
this.cassandraPort = resolvePort();
|
||||
|
||||
if (resourceHolder == null) {
|
||||
@@ -369,7 +388,7 @@ class CassandraDelegate {
|
||||
private int resolvePort() {
|
||||
|
||||
if (isTestcontainers()) {
|
||||
return container.getFirstMappedPort();
|
||||
return container.getMappedPort(9042);
|
||||
}
|
||||
|
||||
return isEmbedded() ? EmbeddedCassandraServerHelper.getNativeTransportPort() : this.properties.getCassandraPort();
|
||||
|
||||
@@ -107,7 +107,7 @@ public class CassandraExtension implements BeforeAllCallback, AfterAllCallback,
|
||||
|
||||
CqlSession session = delegate.createSession();
|
||||
|
||||
TEST_RESOURCES.set(new Resources(delegate.getSystemSession(), session, delegate.getPort()));
|
||||
TEST_RESOURCES.set(new Resources(delegate.getSystemSession(), session, delegate.getHost(), delegate.getPort()));
|
||||
|
||||
if (keyspaceName.isPresent()) {
|
||||
|
||||
@@ -191,16 +191,24 @@ public class CassandraExtension implements BeforeAllCallback, AfterAllCallback,
|
||||
|
||||
private final CqlSession systemSession;
|
||||
private final CqlSession cqlSession;
|
||||
private final String host;
|
||||
private final int port;
|
||||
|
||||
private Resources(CqlSession systemSession, CqlSession cqlSession, int port) {
|
||||
private Resources(CqlSession systemSession, CqlSession cqlSession, String host, int port) {
|
||||
this.systemSession = systemSession;
|
||||
this.cqlSession = cqlSession;
|
||||
this.host = host;
|
||||
this.port = port;
|
||||
}
|
||||
|
||||
public String getHost() {
|
||||
return host;
|
||||
}
|
||||
|
||||
public int getPort() {
|
||||
return port;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -11,8 +11,8 @@
|
||||
<logger name="org.springframework.data.cassandra" level="ERROR" />
|
||||
|
||||
<logger name="org.springframework.data.cassandra.test.util" level="INFO"/>
|
||||
|
||||
<logger name="com.datastax" level="ERROR" />
|
||||
<logger name="container" level="INFO"/>
|
||||
|
||||
<!-- See https://issues.apache.org/jira/browse/CASSANDRA-8220 -->
|
||||
<logger name="org.apache.cassandra.service.CassandraDaemon" level="OFF" />
|
||||
@@ -22,9 +22,6 @@
|
||||
<logger name="com.datastax.driver.core.ControlConnection" level="OFF" />
|
||||
<logger name="com.datastax.driver.core.Session" level="OFF" />
|
||||
|
||||
<!-- This one is noisy and subject to be refactored -->
|
||||
<logger name="org.springframework.data.cassandra.core.mapping.BasicCassandraPersistentEntityMetadataVerifier" level="OFF" />
|
||||
|
||||
<root level="ERROR">
|
||||
<appender-ref ref="console" />
|
||||
</root>
|
||||
|
||||
@@ -1,19 +1,16 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<beans xmlns="http://www.springframework.org/schema/beans"
|
||||
xmlns:cassandra="http://www.springframework.org/schema/data/cassandra"
|
||||
xmlns:context="http://www.springframework.org/schema/context"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="
|
||||
http://www.springframework.org/schema/beans https://www.springframework.org/schema/beans/spring-beans.xsd
|
||||
http://www.springframework.org/schema/data/cassandra https://www.springframework.org/schema/data/cassandra/spring-cassandra.xsd
|
||||
http://www.springframework.org/schema/context https://www.springframework.org/schema/context/spring-context.xsd
|
||||
">
|
||||
xmlns:cassandra="http://www.springframework.org/schema/data/cassandra"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns:context="http://www.springframework.org/schema/context"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans https://www.springframework.org/schema/beans/spring-beans.xsd
|
||||
http://www.springframework.org/schema/data/cassandra https://www.springframework.org/schema/data/cassandra/spring-cassandra.xsd http://www.springframework.org/schema/context https://www.springframework.org/schema/context/spring-context.xsd">
|
||||
|
||||
<context:property-placeholder
|
||||
location="classpath:/config/cassandra-connection.properties,classpath:/org/springframework/data/cassandra/config/cassandra.properties"/>
|
||||
|
||||
<cassandra:session contact-points="${build.cassandra.host}"
|
||||
port="${build.cassandra.native_transport_port}"
|
||||
<cassandra:session port="#{systemProperties['build.cassandra.native_transport_port']}"
|
||||
contact-points="#{systemProperties['build.cassandra.host']}"
|
||||
keyspace-name="${cassandra.keyspace}">
|
||||
<cassandra:keyspace name="${cassandra.keyspace}" action="CREATE_DROP"
|
||||
durable-writes="true"/>
|
||||
|
||||
@@ -10,9 +10,10 @@
|
||||
">
|
||||
|
||||
<context:property-placeholder
|
||||
location="classpath:/config/cassandra-connection.properties,classpath:/org/springframework/data/cassandra/config/FullySpecifiedKeyspaceCreatingXmlConfigIntegrationTests.properties"/>
|
||||
location="classpath:/org/springframework/data/cassandra/config/FullySpecifiedKeyspaceCreatingXmlConfigIntegrationTests.properties"/>
|
||||
|
||||
<cassandra:session port="${build.cassandra.native_transport_port}"
|
||||
<cassandra:session port="#{systemProperties['build.cassandra.native_transport_port']}"
|
||||
contact-points="#{systemProperties['build.cassandra.host']}"
|
||||
keyspace-name="full1">
|
||||
<cassandra:keyspace action="CREATE_DROP" durable-writes="true" name="full1">
|
||||
<cassandra:replication class="SIMPLE_STRATEGY">
|
||||
|
||||
@@ -1,18 +1,13 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<beans xmlns="http://www.springframework.org/schema/beans"
|
||||
xmlns:cassandra="http://www.springframework.org/schema/data/cassandra"
|
||||
xmlns:context="http://www.springframework.org/schema/context"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="
|
||||
http://www.springframework.org/schema/beans https://www.springframework.org/schema/beans/spring-beans.xsd
|
||||
http://www.springframework.org/schema/context https://www.springframework.org/schema/context/spring-context.xsd
|
||||
http://www.springframework.org/schema/data/cassandra https://www.springframework.org/schema/data/cassandra/spring-cassandra.xsd
|
||||
">
|
||||
xmlns:cassandra="http://www.springframework.org/schema/data/cassandra"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans https://www.springframework.org/schema/beans/spring-beans.xsd
|
||||
|
||||
<context:property-placeholder
|
||||
location="classpath:/config/cassandra-connection.properties"/>
|
||||
http://www.springframework.org/schema/data/cassandra https://www.springframework.org/schema/data/cassandra/spring-cassandra.xsd">
|
||||
|
||||
<cassandra:session port="${build.cassandra.native_transport_port}"
|
||||
<cassandra:session port="#{systemProperties['build.cassandra.native_transport_port']}"
|
||||
contact-points="#{systemProperties['build.cassandra.host']}"
|
||||
keyspace-name="minimal">
|
||||
<cassandra:keyspace action="CREATE_DROP" name="minimal"/>
|
||||
</cassandra:session>
|
||||
|
||||
@@ -1,20 +1,15 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<beans xmlns="http://www.springframework.org/schema/beans"
|
||||
xmlns:cassandra="http://www.springframework.org/schema/data/cassandra"
|
||||
xmlns:context="http://www.springframework.org/schema/context"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="
|
||||
http://www.springframework.org/schema/beans https://www.springframework.org/schema/beans/spring-beans.xsd
|
||||
http://www.springframework.org/schema/context https://www.springframework.org/schema/context/spring-context.xsd
|
||||
http://www.springframework.org/schema/data/cassandra https://www.springframework.org/schema/data/cassandra/spring-cassandra.xsd
|
||||
">
|
||||
xmlns:cassandra="http://www.springframework.org/schema/data/cassandra"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans https://www.springframework.org/schema/beans/spring-beans.xsd
|
||||
|
||||
<context:property-placeholder
|
||||
location="classpath:/config/cassandra-connection.properties"/>
|
||||
http://www.springframework.org/schema/data/cassandra https://www.springframework.org/schema/data/cassandra/spring-cassandra.xsd">
|
||||
|
||||
<cassandra:session port="${build.cassandra.native_transport_port}"
|
||||
keyspace-name="minimalxmlconfigtest"
|
||||
local-datacenter="datacenter1"/>
|
||||
<cassandra:session port="#{systemProperties['build.cassandra.native_transport_port']}"
|
||||
contact-points="#{systemProperties['build.cassandra.host']}"
|
||||
keyspace-name="minimalxmlconfigtest"
|
||||
local-datacenter="datacenter1"/>
|
||||
|
||||
<cassandra:template/>
|
||||
</beans>
|
||||
|
||||
@@ -1,18 +1,13 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<beans xmlns="http://www.springframework.org/schema/beans"
|
||||
xmlns:cassandra="http://www.springframework.org/schema/data/cassandra"
|
||||
xmlns:context="http://www.springframework.org/schema/context"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="
|
||||
http://www.springframework.org/schema/beans https://www.springframework.org/schema/beans/spring-beans.xsd
|
||||
http://www.springframework.org/schema/context https://www.springframework.org/schema/context/spring-context.xsd
|
||||
http://www.springframework.org/schema/data/cassandra https://www.springframework.org/schema/data/cassandra/spring-cassandra.xsd
|
||||
">
|
||||
xmlns:cassandra="http://www.springframework.org/schema/data/cassandra"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans https://www.springframework.org/schema/beans/spring-beans.xsd
|
||||
|
||||
<context:property-placeholder
|
||||
location="classpath:/config/cassandra-connection.properties"/>
|
||||
http://www.springframework.org/schema/data/cassandra https://www.springframework.org/schema/data/cassandra/spring-cassandra.xsd">
|
||||
|
||||
<cassandra:session port="${build.cassandra.native_transport_port}"
|
||||
<cassandra:session port="#{systemProperties['build.cassandra.native_transport_port']}"
|
||||
contact-points="#{systemProperties['build.cassandra.host']}"
|
||||
keyspace-name="system"/>
|
||||
|
||||
<cassandra:auditing/>
|
||||
|
||||
@@ -1,20 +1,18 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<beans xmlns="http://www.springframework.org/schema/beans"
|
||||
xmlns:context="http://www.springframework.org/schema/context"
|
||||
xmlns:cassandra="http://www.springframework.org/schema/data/cassandra"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="
|
||||
http://www.springframework.org/schema/beans https://www.springframework.org/schema/beans/spring-beans.xsd
|
||||
http://www.springframework.org/schema/context https://www.springframework.org/schema/context/spring-context.xsd
|
||||
http://www.springframework.org/schema/data/cassandra https://www.springframework.org/schema/data/cassandra/spring-cassandra.xsd
|
||||
">
|
||||
xmlns:cassandra="http://www.springframework.org/schema/data/cassandra"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans https://www.springframework.org/schema/beans/spring-beans.xsd
|
||||
|
||||
<context:property-placeholder
|
||||
location="classpath:/config/cassandra-connection.properties"/>
|
||||
http://www.springframework.org/schema/data/cassandra https://www.springframework.org/schema/data/cassandra/spring-cassandra.xsd">
|
||||
|
||||
<cassandra:session id="session-1" port="${build.cassandra.native_transport_port}"
|
||||
<cassandra:session id="session-1"
|
||||
port="#{systemProperties['build.cassandra.native_transport_port']}"
|
||||
contact-points="#{systemProperties['build.cassandra.host']}"
|
||||
keyspace-name="system"/>
|
||||
<cassandra:session id="session-2" port="${build.cassandra.native_transport_port}"
|
||||
<cassandra:session id="session-2"
|
||||
port="#{systemProperties['build.cassandra.native_transport_port']}"
|
||||
contact-points="#{systemProperties['build.cassandra.host']}"
|
||||
keyspace-name="system"/>
|
||||
|
||||
</beans>
|
||||
|
||||
@@ -30,7 +30,8 @@
|
||||
</cassandra:entity>
|
||||
</cassandra:mapping>
|
||||
|
||||
<cassandra:session port="${build.cassandra.native_transport_port}"
|
||||
<cassandra:session port="#{systemProperties['build.cassandra.native_transport_port']}"
|
||||
contact-points="#{systemProperties['build.cassandra.host']}"
|
||||
keyspace-name="#{randomKeyspaceName}"
|
||||
schema-action="RECREATE_DROP_UNUSED"
|
||||
cassandra-converter-ref="cassandraConverter">
|
||||
|
||||
@@ -37,7 +37,8 @@
|
||||
</cassandra:entity>
|
||||
</cassandra:mapping>
|
||||
|
||||
<cassandra:session port="${build.cassandra.native_transport_port}"
|
||||
<cassandra:session port="#{systemProperties['build.cassandra.native_transport_port']}"
|
||||
contact-points="#{systemProperties['build.cassandra.host']}"
|
||||
keyspace-name="ForceQuoteRepositoryXmlConfigIntegrationTests"
|
||||
schema-action="RECREATE_DROP_UNUSED"
|
||||
cassandra-converter-ref="cassandraConverter">
|
||||
|
||||
Reference in New Issue
Block a user