You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beam.apache.org by da...@apache.org on 2024/08/28 13:10:44 UTC
(beam) branch master updated: Add quality warnings to pulsar (#32346)
This is an automated email from the ASF dual-hosted git repository.
damccorm pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/beam.git
The following commit(s) were added to refs/heads/master by this push:
new 8cc80ff44c5 Add quality warnings to pulsar (#32346)
8cc80ff44c5 is described below
commit 8cc80ff44c56125d59e010b4299582ecef6b40ae
Author: Danny McCormick <da...@google.com>
AuthorDate: Wed Aug 28 14:10:37 2024 +0100
Add quality warnings to pulsar (#32346)
* Add quality warnings to pulsar
* spotless
---
.../main/java/org/apache/beam/sdk/io/pulsar/PulsarIO.java | 15 +++++++++++++++
.../org/apache/beam/sdk/io/pulsar/ReadFromPulsarDoFn.java | 5 +++++
.../org/apache/beam/sdk/io/pulsar/WriteToPulsarDoFn.java | 5 +++++
.../java/org/apache/beam/sdk/io/pulsar/package-info.java | 6 +++++-
4 files changed, 30 insertions(+), 1 deletion(-)
diff --git a/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/PulsarIO.java b/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/PulsarIO.java
index 6d0f0a08a01..aaff08a96d3 100644
--- a/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/PulsarIO.java
+++ b/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/PulsarIO.java
@@ -31,12 +31,22 @@ import org.apache.pulsar.client.api.PulsarClient;
import org.checkerframework.checker.nullness.qual.Nullable;
import org.joda.time.Instant;
+/**
+ * Class for reading and writing from Apache Pulsar. Support is currently incomplete, and there may
+ * be bugs; see https://github.com/apache/beam/issues/31078 for more info, and comment in that issue
+ * if you run into issues with this IO.
+ */
@SuppressWarnings({"rawtypes", "nullness"})
public class PulsarIO {
/** Static class, prevent instantiation. */
private PulsarIO() {}
+ /**
+ * Read from Apache Pulsar. Support is currently incomplete, and there may be bugs; see
+ * https://github.com/apache/beam/issues/31078 for more info, and comment in that issue if you run
+ * into issues with this IO.
+ */
public static Read read() {
return new AutoValue_PulsarIO_Read.Builder()
.setPulsarClient(PulsarIOUtils.PULSAR_CLIENT_SERIALIZABLE_FUNCTION)
@@ -144,6 +154,11 @@ public class PulsarIO {
}
}
+ /**
+ * Write to Apache Pulsar. Support is currently incomplete, and there may be bugs; see
+ * https://github.com/apache/beam/issues/31078 for more info, and comment in that issue if you run
+ * into issues with this IO.
+ */
public static Write write() {
return new AutoValue_PulsarIO_Write.Builder().build();
}
diff --git a/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/ReadFromPulsarDoFn.java b/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/ReadFromPulsarDoFn.java
index 97a8dcd6e2b..a4e0a78e634 100644
--- a/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/ReadFromPulsarDoFn.java
+++ b/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/ReadFromPulsarDoFn.java
@@ -43,6 +43,11 @@ import org.joda.time.Instant;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
+/**
+ * Transform for reading from Apache Pulsar. Support is currently incomplete, and there may be bugs;
+ * see https://github.com/apache/beam/issues/31078 for more info, and comment in that issue if you
+ * run into issues with this IO.
+ */
@DoFn.UnboundedPerElement
@SuppressWarnings({"rawtypes", "nullness"})
public class ReadFromPulsarDoFn extends DoFn<PulsarSourceDescriptor, PulsarMessage> {
diff --git a/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/WriteToPulsarDoFn.java b/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/WriteToPulsarDoFn.java
index 9659940e02b..375e8ce92a3 100644
--- a/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/WriteToPulsarDoFn.java
+++ b/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/WriteToPulsarDoFn.java
@@ -23,6 +23,11 @@ import org.apache.pulsar.client.api.Producer;
import org.apache.pulsar.client.api.PulsarClient;
import org.apache.pulsar.client.api.PulsarClientException;
+/**
+ * Transform for writing to Apache Pulsar. Support is currently incomplete, and there may be bugs;
+ * see https://github.com/apache/beam/issues/31078 for more info, and comment in that issue if you
+ * run into issues with this IO.
+ */
@DoFn.UnboundedPerElement
@SuppressWarnings({"rawtypes", "nullness"})
public class WriteToPulsarDoFn extends DoFn<byte[], Void> {
diff --git a/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/package-info.java b/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/package-info.java
index 8b7ab101a72..ffa15257fe5 100644
--- a/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/package-info.java
+++ b/sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/package-info.java
@@ -15,5 +15,9 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-/** Transforms for reading and writing from Apache Pulsar. */
+/**
+ * Transforms for reading and writing from Apache Pulsar. Support is currently incomplete, and there
+ * may be bugs; see https://github.com/apache/beam/issues/31078 for more info, and comment in that
+ * issue if you run into issues with this IO.
+ */
package org.apache.beam.sdk.io.pulsar;