Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Post 3.2 cleanup #1067

Merged
merged 3 commits into from
Apr 10, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 0 additions & 4 deletions extensions-core/core-cloud/deployment/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,6 @@
</dependencyManagement>

<dependencies>
<dependency>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-caffeine-deployment</artifactId>
</dependency>
<dependency>
<groupId>org.apache.camel.quarkus</groupId>
<artifactId>camel-quarkus-core-deployment</artifactId>
Expand Down
14 changes: 0 additions & 14 deletions extensions-core/core-cloud/runtime/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -60,20 +60,6 @@
<artifactId>camel-cloud</artifactId>
</dependency>

<dependency>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-caffeine</artifactId>
</dependency>
<dependency>
<groupId>org.graalvm.nativeimage</groupId>
<artifactId>svm</artifactId>
</dependency>

<dependency>
<groupId>jakarta.servlet</groupId>
<artifactId>jakarta.servlet-api</artifactId>
</dependency>

</dependencies>

<build>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,8 @@
import org.apache.camel.quarkus.core.deployment.CamelServicePatternBuildItem.CamelServiceDestination;
import org.apache.camel.quarkus.core.deployment.util.PathFilter;
import org.apache.camel.quarkus.support.common.CamelCapabilities;
import org.apache.camel.spi.FactoryFinder;
import org.apache.camel.spi.RestBindingJaxbDataFormatFactory;
import org.apache.camel.spi.TypeConverterLoader;
import org.apache.camel.spi.TypeConverterRegistry;
import org.jboss.jandex.ClassInfo;
Expand Down Expand Up @@ -164,6 +166,14 @@ void coreServicePatterns(BuildProducer<CamelServicePatternBuildItem> services) {
"META-INF/services/org/apache/camel/dataformat/*",
"META-INF/services/org/apache/camel/cron/*"));

// TODO: this can be removed and the RestBindingJaxbDataFormatFactory can be discovered
// and instantiated when camel is on the classpath with a camel context customizer
// when https://github.com/apache/camel-quarkus/issues/984 will be implemented
services.produce(new CamelServicePatternBuildItem(
CamelServiceDestination.DISCOVERY,
true,
FactoryFinder.DEFAULT_PATH + RestBindingJaxbDataFormatFactory.FACTORY));

services.produce(new CamelServicePatternBuildItem(
CamelServiceDestination.DISCOVERY,
false,
Expand Down

This file was deleted.

1 change: 0 additions & 1 deletion extensions/consul/deployment/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@
<groupId>io.quarkus</groupId>
<artifactId>quarkus-jackson-deployment</artifactId>
</dependency>
<!-- TODO revert back to camel-quarkus-core-deployment when upgrading to camel 3.2 -->
<dependency>
<groupId>org.apache.camel.quarkus</groupId>
<artifactId>camel-quarkus-core-cloud-deployment</artifactId>
Expand Down
1 change: 0 additions & 1 deletion extensions/consul/runtime/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@
<groupId>io.quarkus</groupId>
<artifactId>quarkus-jackson</artifactId>
</dependency>
<!-- TODO revert back to camel-quarkus-core when upgrading to camel 3.2 -->
<dependency>
<groupId>org.apache.camel.quarkus</groupId>
<artifactId>camel-quarkus-core-cloud</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,12 @@
package org.apache.camel.quarkus.component.platform.http.runtime;

import java.util.List;
import java.util.Map;

import io.quarkus.runtime.RuntimeValue;
import io.quarkus.runtime.annotations.Recorder;
import io.vertx.core.Handler;
import io.vertx.ext.web.Router;
import io.vertx.ext.web.RoutingContext;
import org.apache.camel.Endpoint;
import org.apache.camel.component.platform.http.PlatformHttpComponent;
import org.apache.camel.component.platform.http.spi.PlatformHttpEngine;
import org.apache.camel.quarkus.core.UploadAttacher;
Expand All @@ -39,20 +37,7 @@ public RuntimeValue<PlatformHttpEngine> createEngine(
}

public RuntimeValue<PlatformHttpComponent> createComponent(RuntimeValue<PlatformHttpEngine> engine) {
PlatformHttpComponent component = new PlatformHttpComponent() {
@Override
protected Endpoint createEndpoint(String uri, String remaining, Map<String, Object> parameters) throws Exception {
// remove matchOnUriPrefix as it will be fixed by camel 3.2 but will cause the context
// to fail as the property cannot be bound to the enpoint.
//
// TODO: remove once migrating to camel 3.2
parameters.remove("matchOnUriPrefix");

// let the original component to create the endpoint
return super.createEndpoint(uri, remaining, parameters);
}
};

PlatformHttpComponent component = new PlatformHttpComponent();
component.setEngine(engine.getValue());

return new RuntimeValue<>(component);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@

import static org.hamcrest.CoreMatchers.equalTo;
import static org.hamcrest.CoreMatchers.is;
import static org.hamcrest.CoreMatchers.not;

@QuarkusTest
class PlatformHttpEngineTest {
Expand All @@ -38,7 +37,7 @@ public void registrySetUp() {
.statusCode(200)
.body(
PlatformHttpConstants.PLATFORM_HTTP_ENGINE_NAME, is(QuarkusPlatformHttpEngine.class.getName()),
PlatformHttpConstants.PLATFORM_HTTP_COMPONENT_NAME, is(not(PlatformHttpComponent.class.getName())),
PlatformHttpConstants.PLATFORM_HTTP_COMPONENT_NAME, is(PlatformHttpComponent.class.getName()),
"handlers-size", is(1));
}

Expand Down