Schema Registry cleanup
* AutoConfiguration.imports in-lieu of spring.factories and related changes. * Build script cleanup.
This commit is contained in:
@@ -4,10 +4,10 @@ if [ "$#" -eq 1 ]; then
|
||||
ARGVALUE=$1
|
||||
if [[ $ARGVALUE == *"skipTest"* ]]; then
|
||||
echo "Skippping Tests"
|
||||
./mvnw clean install -f core/pom.xml -DskipTests
|
||||
./mvnw clean install -f schema-registry/pom.xml -DskipTests
|
||||
elif [[ $ARGVALUE == *"disable.checks"* ]]; then
|
||||
echo "Skippping checkstyle checks"
|
||||
./mvnw clean install -f core/pom.xml -Ddisable.checks=true
|
||||
./mvnw clean install -f schema-registry/pom.xml -Ddisable.checks=true
|
||||
fi
|
||||
else
|
||||
./mvnw clean install -f schema-registry/pom.xml
|
||||
|
||||
@@ -41,8 +41,8 @@ import org.springframework.util.ReflectionUtils;
|
||||
*/
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@ConditionalOnClass(name = "org.apache.avro.Schema")
|
||||
@ConditionalOnProperty(value = "spring.cloud.schemaRegistryClient.enabled", matchIfMissing = true)
|
||||
@ConditionalOnBean(type = "org.springframework.cloud.stream.schema.registry.client.SchemaRegistryClient")
|
||||
@ConditionalOnProperty(value = "spring.cloud.stream.schemaRegistryClient.enabled", matchIfMissing = true)
|
||||
@ConditionalOnBean(SchemaRegistryClient.class)
|
||||
@EnableConfigurationProperties({ AvroMessageConverterProperties.class })
|
||||
@Import(AvroSchemaServiceManagerImpl.class)
|
||||
public class AvroMessageConverterAutoConfiguration {
|
||||
|
||||
@@ -1,3 +1 @@
|
||||
org.springframework.boot.autoconfigure.EnableAutoConfiguration=\
|
||||
org.springframework.cloud.stream.schema.registry.avro.AvroMessageConverterAutoConfiguration
|
||||
|
||||
@@ -198,7 +198,7 @@ public class AvroSchemaRegistryClientMessageConverterTests {
|
||||
|
||||
@Bean
|
||||
ServletWebServerFactory servletWebServerFactory() {
|
||||
return new TomcatServletWebServerFactory();
|
||||
return new TomcatServletWebServerFactory(0);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -71,9 +71,7 @@ import static org.springframework.test.annotation.DirtiesContext.ClassMode.AFTER
|
||||
* @author Christian Tzolov
|
||||
*/
|
||||
@ExtendWith(SpringExtension.class)
|
||||
// @checkstyle:off
|
||||
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.DEFINED_PORT, properties = "spring.main.allow-bean-definition-overriding=true")
|
||||
// @checkstyle:on
|
||||
@DirtiesContext(classMode = AFTER_EACH_TEST_METHOD)
|
||||
public class SchemaRegistryServerAvroTests {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user