Skip to content

Commit

Permalink
Update documentation references for javax packages to jakarta
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesnetherton committed May 3, 2023
1 parent 9f7ea21 commit 38f4e54
Show file tree
Hide file tree
Showing 14 changed files with 32 additions and 32 deletions.
2 changes: 1 addition & 1 deletion docs/modules/ROOT/pages/reference/extensions/aws2-ddb.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ You can reach that e.g. by adding a dummy bean injecting `DynamoDbClient`:
+
[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import jakarta.enterprise.context.ApplicationScoped;
import io.quarkus.arc.Unremovable;
import software.amazon.awssdk.services.dynamodb.DynamoDbClient;
Expand Down
2 changes: 1 addition & 1 deletion docs/modules/ROOT/pages/reference/extensions/aws2-s3.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ You can reach that e.g. by adding a dummy bean injecting `S3Client`:
+
[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import jakarta.enterprise.context.ApplicationScoped;
import io.quarkus.arc.Unremovable;
import software.amazon.awssdk.services.s3.S3Client;
Expand Down
2 changes: 1 addition & 1 deletion docs/modules/ROOT/pages/reference/extensions/aws2-ses.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ You can reach that e.g. by adding a dummy bean injecting `SesClient`:
+
[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import jakarta.enterprise.context.ApplicationScoped;
import io.quarkus.arc.Unremovable;
import software.amazon.awssdk.services.ses.SesClient;
Expand Down
2 changes: 1 addition & 1 deletion docs/modules/ROOT/pages/reference/extensions/aws2-sns.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ You can reach that e.g. by adding a dummy bean injecting `SnsClient`:
+
[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import jakarta.enterprise.context.ApplicationScoped;
import io.quarkus.arc.Unremovable;
import software.amazon.awssdk.services.sns.SnsClient;
Expand Down
2 changes: 1 addition & 1 deletion docs/modules/ROOT/pages/reference/extensions/aws2-sqs.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ You can reach that e.g. by adding a dummy bean injecting `SqsClient`:
+
[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import jakarta.enterprise.context.ApplicationScoped;
import io.quarkus.arc.Unremovable;
import software.amazon.awssdk.services.sqs.SqsClient;
Expand Down
6 changes: 3 additions & 3 deletions docs/modules/ROOT/pages/reference/extensions/freemarker.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,9 @@ you can let CDI to do the required wiring:

[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import javax.enterprise.inject.Produces;
import javax.inject.Named;
import jakarta.enterprise.context.ApplicationScoped;
import jakarta.enterprise.inject.Produces;
import jakarta.inject.Named;
import freemarker.template.Configuration;
import io.quarkus.arc.Unremovable;
import org.apache.camel.builder.RouteBuilder;
Expand Down
4 changes: 2 additions & 2 deletions docs/modules/ROOT/pages/reference/extensions/mock.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ You can inject camelContext into test using `@Inject` annotation. Camel context
See the following example:

----
import javax.inject.Inject;
import jakarta.inject.Inject;
import org.apache.camel.CamelContext;
import org.apache.camel.ProducerTemplate;
Expand Down Expand Up @@ -86,7 +86,7 @@ public class MockJvmTest {
----
Route used for the example test:
----
import javax.enterprise.context.ApplicationScoped;
import jakarta.enterprise.context.ApplicationScoped;
import org.apache.camel.builder.RouteBuilder;
Expand Down
20 changes: 10 additions & 10 deletions docs/modules/ROOT/pages/user-guide/cdi.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ your Camel `RouteBuilder`. Here is the `RouteBuilder` from our `timer-log-cdi` x

[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import javax.inject.Inject;
import jakarta.enterprise.context.ApplicationScoped;
import jakarta.inject.Inject;
import org.apache.camel.builder.RouteBuilder;
import org.eclipse.microprofile.config.inject.ConfigProperty;
Expand Down Expand Up @@ -47,8 +47,8 @@ To access `CamelContext` just inject it into your bean:

[source,java]
----
import javax.inject.Inject;
import javax.enterprise.context.ApplicationScoped;
import jakarta.inject.Inject;
import jakarta.enterprise.context.ApplicationScoped;
import java.util.stream.Collectors;
import java.util.List;
import org.apache.camel.CamelContext;
Expand All @@ -75,7 +75,7 @@ The following use cases are supported by `org.apache.camel.quarkus:camel-quarkus

[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import jakarta.enterprise.context.ApplicationScoped;
import org.apache.camel.EndpointInject;
import org.apache.camel.FluentProducerTemplate;
import org.apache.camel.Produce;
Expand Down Expand Up @@ -114,7 +114,7 @@ The following use case is supported by `org.apache.camel.quarkus:camel-quarkus-b

[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import jakarta.enterprise.context.ApplicationScoped;
import org.apache.camel.Produce;
@ApplicationScoped
Expand Down Expand Up @@ -147,8 +147,8 @@ is important for the native mode.

[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import javax.inject.Named;
import jakarta.enterprise.context.ApplicationScoped;
import jakarta.inject.Named;
import io.quarkus.runtime.annotations.RegisterForReflection;
@ApplicationScoped
Expand Down Expand Up @@ -182,7 +182,7 @@ As an alternative to `@Named`, you may also use `io.smallrye.common.annotation.I

[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import jakarta.enterprise.context.ApplicationScoped;
import io.quarkus.runtime.annotations.RegisterForReflection;
import io.smallrye.common.annotation.Identifier;
Expand Down Expand Up @@ -241,6 +241,6 @@ from("activemq:cheese").bean("foo1234", "onCheese")
----

for you.
Note that Camel Quarkus will implicitly add `@javax.inject.Singleton` and `javax.inject.Named("foo1234")` to the bean class, where `1234` is a hash code obtained from the fully qualified class name.
Note that Camel Quarkus will implicitly add `@jakarta.inject.Singleton` and `jakarta.inject.Named("foo1234")` to the bean class, where `1234` is a hash code obtained from the fully qualified class name.
If your bean has some CDI scope (such as `@ApplicationScoped`) or `@Named("someName")` set already,
those will be honored in the auto-created route.
2 changes: 1 addition & 1 deletion docs/modules/ROOT/pages/user-guide/command-mode.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ We can use https://quarkus.io/guides/config[Quarkus MicroProfile Config] for tha

[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import jakarta.enterprise.context.ApplicationScoped;
import org.apache.camel.builder.RouteBuilder;
import org.eclipse.microprofile.config.inject.ConfigProperty;
Expand Down
8 changes: 4 additions & 4 deletions docs/modules/ROOT/pages/user-guide/configuration.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ The recommended method is to observe the `ComponentAddEvent` and configure the c

[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import javax.enterprise.event.Observes;
import jakarta.enterprise.context.ApplicationScoped;
import jakarta.enterprise.event.Observes;
import org.apache.camel.quarkus.core.events.ComponentAddEvent;
import org.apache.camel.component.log.LogComponent;
import org.apache.camel.support.processor.DefaultExchangeFormatter;
Expand Down Expand Up @@ -86,8 +86,8 @@ These actions are not performed when you produce your own component instance, th

[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import javax.inject.Named;
import jakarta.enterprise.context.ApplicationScoped;
import jakarta.inject.Named;
import org.apache.camel.component.log.LogComponent;
import org.apache.camel.support.processor.DefaultExchangeFormatter;
Expand Down
2 changes: 1 addition & 1 deletion docs/modules/ROOT/pages/user-guide/testing.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ An implementation of a native test may help to capture more details https://gith

JVM mode tests annotated with `@QuarkusTest` are executed in the same JVM as the application under test.
Thanks to that, `@Inject`-ing beans from the application into the test code is possible.
You can also define new beans or even override the beans from the application using `@javax.enterprise.inject.Alternative` and `@javax.annotation.Priority`.
You can also define new beans or even override the beans from the application using `@jakarta.enterprise.inject.Alternative` and `@jakarta.annotation.Priority`.

However all these tricks won't work in native mode tests annotated with `@QuarkusIntegrationTest`
because those are executed in a JVM hosted in a process separate from the running native application.
Expand Down
6 changes: 3 additions & 3 deletions extensions/freemarker/runtime/src/main/doc/configuration.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ you can let CDI to do the required wiring:

[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import javax.enterprise.inject.Produces;
import javax.inject.Named;
import jakarta.enterprise.context.ApplicationScoped;
import jakarta.enterprise.inject.Produces;
import jakarta.inject.Named;
import freemarker.template.Configuration;
import io.quarkus.arc.Unremovable;
import org.apache.camel.builder.RouteBuilder;
Expand Down
4 changes: 2 additions & 2 deletions extensions/mock/runtime/src/main/doc/usage.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ You can inject camelContext into test using `@Inject` annotation. Camel context
See the following example:

----
import javax.inject.Inject;
import jakarta.inject.Inject;
import org.apache.camel.CamelContext;
import org.apache.camel.ProducerTemplate;
Expand Down Expand Up @@ -37,7 +37,7 @@ public class MockJvmTest {
----
Route used for the example test:
----
import javax.enterprise.context.ApplicationScoped;
import jakarta.enterprise.context.ApplicationScoped;

import org.apache.camel.builder.RouteBuilder;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ You can reach that e.g. by adding a dummy bean injecting `[=quarkusAwsClient.cli
+
[source,java]
----
import javax.enterprise.context.ApplicationScoped;
import jakarta.enterprise.context.ApplicationScoped;
import io.quarkus.arc.Unremovable;
import [=quarkusAwsClient.clientClassFqName];
Expand Down

0 comments on commit 38f4e54

Please sign in to comment.