diff --git a/data-plane/config/source/100-config-kafka-source-data-plane.yaml b/data-plane/config/source/100-config-kafka-source-data-plane.yaml index ecc39dbbbc..5dd43a9c3f 100644 --- a/data-plane/config/source/100-config-kafka-source-data-plane.yaml +++ b/data-plane/config/source/100-config-kafka-source-data-plane.yaml @@ -97,7 +97,8 @@ data: value.deserializer=io.cloudevents.kafka.CloudEventDeserializer fetch.min.bytes=1 heartbeat.interval.ms=3000 - max.partition.fetch.bytes=1048576 + # max.partition.fetch.bytes=1048576 + max.partition.fetch.bytes=128 session.timeout.ms=10000 # ssl.key.password= # ssl.keystore.location= @@ -130,7 +131,7 @@ data: # ssl.keystore.type= # ssl.protocol= # ssl.provider= - auto.commit.interval.ms=5000 + auto.commit.interval.ms=500 check.crcs=true # client.rack= fetch.max.wait.ms=500 diff --git a/data-plane/core/src/main/java/dev/knative/eventing/kafka/broker/core/OrderedAsyncExecutor.java b/data-plane/core/src/main/java/dev/knative/eventing/kafka/broker/core/OrderedAsyncExecutor.java index 95d7426cf2..d87a477739 100644 --- a/data-plane/core/src/main/java/dev/knative/eventing/kafka/broker/core/OrderedAsyncExecutor.java +++ b/data-plane/core/src/main/java/dev/knative/eventing/kafka/broker/core/OrderedAsyncExecutor.java @@ -138,4 +138,5 @@ private static final class Task { this.task = task; } } + } diff --git a/data-plane/core/src/test/java/dev/knative/eventing/kafka/broker/core/OrderedAsyncExecutorTest.java b/data-plane/core/src/test/java/dev/knative/eventing/kafka/broker/core/OrderedAsyncExecutorTest.java index d3829a8d13..6f99936ce8 100644 --- a/data-plane/core/src/test/java/dev/knative/eventing/kafka/broker/core/OrderedAsyncExecutorTest.java +++ b/data-plane/core/src/test/java/dev/knative/eventing/kafka/broker/core/OrderedAsyncExecutorTest.java @@ -37,10 +37,10 @@ import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; -import static org.assertj.core.api.Assertions.assertThat; - import dev.knative.eventing.kafka.broker.contract.DataPlaneContract; +import static org.assertj.core.api.Assertions.assertThat; + @ExtendWith(VertxExtension.class) public class OrderedAsyncExecutorTest { diff --git a/hack/data-plane.sh b/hack/data-plane.sh index ef6bd93f0f..a48b310318 100755 --- a/hack/data-plane.sh +++ b/hack/data-plane.sh @@ -82,8 +82,8 @@ function data_plane_build_push() { function replace_images() { local file=$1 - sed -i "s|\${KNATIVE_KAFKA_DISPATCHER_IMAGE}|${KNATIVE_KAFKA_DISPATCHER_IMAGE}|g" "${file}" && - sed -i "s|\${KNATIVE_KAFKA_RECEIVER_IMAGE}|${KNATIVE_KAFKA_RECEIVER_IMAGE}|g" "${file}" + /usr/bin/sed -i '' "s|\${KNATIVE_KAFKA_DISPATCHER_IMAGE}|${KNATIVE_KAFKA_DISPATCHER_IMAGE}|g" "${file}" && + /usr/bin/sed -i '' "s|\${KNATIVE_KAFKA_RECEIVER_IMAGE}|${KNATIVE_KAFKA_RECEIVER_IMAGE}|g" "${file}" return $? } @@ -142,7 +142,7 @@ function data_plane_source_setup() { ko resolve ${KO_FLAGS} -Rf ${SOURCE_DATA_PLANE_CONFIG_DIR} | "${LABEL_YAML_CMD[@]}" >>"${EVENTING_KAFKA_SOURCE_BUNDLE_ARTIFACT}" - sed -i "s|\${KNATIVE_KAFKA_DISPATCHER_IMAGE}|${KNATIVE_KAFKA_DISPATCHER_IMAGE}|g" "${EVENTING_KAFKA_SOURCE_BUNDLE_ARTIFACT}" + /usr/bin/sed -i '' "s|\${KNATIVE_KAFKA_DISPATCHER_IMAGE}|${KNATIVE_KAFKA_DISPATCHER_IMAGE}|g" "${EVENTING_KAFKA_SOURCE_BUNDLE_ARTIFACT}" return $? } diff --git a/hack/generate-proto.sh b/hack/generate-proto.sh index 865f190be1..d77d4a6cb4 100755 --- a/hack/generate-proto.sh +++ b/hack/generate-proto.sh @@ -5,7 +5,7 @@ set -o nounset set -o pipefail REPO_ROOT=$(dirname $0)/.. -REPO_ROOT=$(readlink -m $REPO_ROOT) +REPO_ROOT=$(greadlink -f $REPO_ROOT) DATA_PLANE_OUTPUT_DIR=${REPO_ROOT}/data-plane/contract/src/main/java CONTROL_PLANE_OUTPUT_DIR=${REPO_ROOT} diff --git a/prometheus.yml b/prometheus.yml new file mode 100644 index 0000000000..43c0dd8434 --- /dev/null +++ b/prometheus.yml @@ -0,0 +1,7 @@ +global: + scrape_interval: 1s + +scrape_configs: + - job_name: "prometheus" + static_configs: + - targets: ["localhost:8001"] \ No newline at end of file