== RxJava 3 API

The client provides an Rxified version of the original API.
The following examples use RxJava 3.

=== Simple query

[source,java]
----
{@link examples.RxPgClientExamples#simpleQuery01Example}
----

=== Connection

The simplified connection API allows to easily use a connection, the `withConnection` method borrows
a connection from the pool and return it for you:

[source,java]
----
{@link examples.RxPgClientExamples#connection01Example}
----

=== Transaction

The simplified transaction API allows to easily write transactional asynchronous flows, The `withTransaction`
method start and commit a transaction for you:

[source,java]
----
{@link examples.RxPgClientExamples#transaction01Example}
----

=== Streaming

RxJava supports `Observable` and `Flowable` types, these are exposed using
the {@link io.vertx.rxjava3.sqlclient.RowStream} that you can get
from a {@link io.vertx.rxjava3.sqlclient.PreparedQuery}:

[source,java]
----
{@link examples.RxPgClientExamples#streamingQuery01Example}
----

The same example using `Flowable`:

[source,java]
----
{@link examples.RxPgClientExamples#streamingQuery02Example}
----
