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

Improve funqy doc #21969

Merged
merged 1 commit into from
Dec 7, 2021
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/src/main/asciidoc/funqy-knative-events.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ There are two things to notice about this function. One, it has no output. You
required to return output. Second, there is an additional `event` parameter to the function.

If you want to know additional information about the incoming Cloud Event, you can inject the
`CloudEvent` interface using the Funqy `@Context` annotation. The `CloudEvent` interface exposes information
`io.quarkus.funqy.knative.events.CloudEvent` interface using the Funqy `@Context` annotation. The `CloudEvent` interface exposes information
about the triggering event.

[source, java]
Expand Down
7 changes: 4 additions & 3 deletions docs/src/main/asciidoc/funqy.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ include::./attributes.adoc[]
:extension-status: preview

Quarkus Funqy is part of Quarkus's serverless strategy and aims to provide a portable Java API to write functions
deployable to various FaaS environments like AWS Lambda, Azure Functions, Knative, and Knative Events (Cloud Events). It is also
usable as a standalone service.
deployable to various FaaS environments like AWS Lambda, Azure Functions, Google Cloud Functions, Knative, and Knative Events (Cloud Events).
It is also usable as a standalone service.

Because Funqy is an abstraction that spans multiple different cloud/function providers
and protocols it has to be a very simple API and thus, might not have all the features you are used
Expand Down Expand Up @@ -145,13 +145,14 @@ contextual information that is specific to the environment you are deploying in.
NOTE: We do not recommend injecting contextual information specific to a runtime. Keep your functions portable.

Contextual information is injected via the `@Context` annotation which can be used on a function parameter
or a class field. A good example is the `CloudEvent` interface that comes with our Funqy
or a class field. A good example is the `io.quarkus.funqy.knative.events.CloudEvent` interface that comes with our Funqy
Knative Cloud Events integration:

[source, java]
----
import io.quarkus.funqy.Funq;
import io.quarkus.funqy.Context;
import io.quarkus.funqy.knative.events.CloudEvent;

public class GreetingFunction {

Expand Down