Skip to content

OBSDATA-1354: Druid 25 with confluent patches#136

Merged
Mohammad Ghazanfar (m-ghazanfar) merged 80 commits into25.0.0-confluent-rc1from
OBSDATA-1354-druid-25-with-cflt-patches
Jun 6, 2023
Merged

OBSDATA-1354: Druid 25 with confluent patches#136
Mohammad Ghazanfar (m-ghazanfar) merged 80 commits into25.0.0-confluent-rc1from
OBSDATA-1354-druid-25-with-cflt-patches

Conversation

@m-ghazanfar
Copy link
Copy Markdown

@m-ghazanfar Mohammad Ghazanfar (m-ghazanfar) commented May 29, 2023

Apply Confluent patches on top of Druid 25.

Druid 25 release notes can be found here

Why suffix the branch wit -rc1?
In case I messup, I don't have to work with IT to delete the 25.0.0-confluent branch.
If 25.0.0-confluent-rc1 works out, I will just create a 25.0.0-confluent branch from that one. If not, I'll give it another trying using -rc2


This section quotes Xavier Léauté (@xvrl) from slack,

Some features of interest to us

  1. Additional partition lag metrics for Kafka ingestion
  2. Async task client for streaming ingestion (which I had already mentioned in November)
  3. A fix for overlord leader-election locking up https://github.com/apache/druid/releases/tag/druid-25.0.0#25-ingestion-fixed-overlord-leader-election
  4. A fix for tasks "getting stuck" and when overlord leader switches, which we have seen a few times https://github.com/apache/druid/releases/tag/druid-25.0.0#25-ingestion-streaming-tasks-resume-on-overlord-switch
  5. Compaction now reduces the amount of disk usage https://github.com/apache/druid/releases/tag/druid-25.0.0#25-operations-compaction
  6. An option to batch segment allocation, which can reduce ingestion lag when waiting for segment allocation https://github.com/apache/druid/releases/tag/druid-25.0.0#25-operations-batch-allocation
  7. Improvements to reduce over-replication of segments during rebalancing https://github.com/apache/druid/releases/tag/druid-25.0.0#25-operations-segment-replication
  8. Support for running tasks natively one k8s, which means we don't need to run middle-managers for compaction tasks anymore, and can bin-pack those workloads anywhere https://github.com/apache/druid/releases/tag/druid-25.0.0#25-highlights-kubernetes-native-tasks

Caution

Task management and segment discovery will default to http by default https://github.com/apache/druid/releases/tag/druid-25.0.0#25-upgrade-segment-discovery


Additional commits

  1. a9acfc3 - Fix lint issue in CI/CD
    The lint would fail. A similar fix has been made on druid 26. See here. I didn't cherry-pick the corresponding commit from apache/druid because it was very large and changes a lot of files.
  2. 68fbe4f - Fix jest and prettify checks
    These changes were created by running the following commands,
npx prettier --write .
npm run jest -- -u

Testing

mvn clean package -DskipTests -T1C -X
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for Druid 25.0.0:
[INFO]
[INFO] Druid .............................................. SUCCESS [  9.509 s]
[INFO] druid-core ......................................... SUCCESS [ 35.928 s]
[INFO] druid-hll .......................................... SUCCESS [ 18.039 s]
[INFO] extendedset ........................................ SUCCESS [ 18.270 s]
[INFO] druid-processing ................................... SUCCESS [01:03 min]
[INFO] druid-aws-common ................................... SUCCESS [ 18.944 s]
[INFO] druid-gcp-common ................................... SUCCESS [ 18.145 s]
[INFO] druid-server ....................................... SUCCESS [ 45.045 s]
[INFO] druid-indexing-hadoop .............................. SUCCESS [02:06 min]
[INFO] druid-indexing-service ............................. SUCCESS [01:50 min]
[INFO] druid-sql .......................................... SUCCESS [01:15 min]
[INFO] druid-services ..................................... SUCCESS [ 29.801 s]
[INFO] druid-orc-extensions ............................... SUCCESS [01:36 min]
[INFO] druid-avro-extensions .............................. SUCCESS [01:48 min]
[INFO] druid-parquet-extensions ........................... SUCCESS [01:37 min]
[INFO] druid-protobuf-extensions .......................... SUCCESS [ 15.048 s]
[INFO] druid-s3-extensions ................................ SUCCESS [ 37.391 s]
[INFO] druid-kinesis-indexing-service ..................... SUCCESS [ 14.989 s]
[INFO] druid-azure-extensions ............................. SUCCESS [ 35.892 s]
[INFO] druid-google-extensions ............................ SUCCESS [ 35.632 s]
[INFO] druid-hdfs-storage ................................. SUCCESS [01:36 min]
[INFO] druid-datasketches ................................. SUCCESS [ 31.345 s]
[INFO] druid-histogram .................................... SUCCESS [ 27.697 s]
[INFO] mysql-metadata-storage ............................. SUCCESS [ 36.272 s]
[INFO] druid-kafka-indexing-service ....................... SUCCESS [ 15.099 s]
[INFO] druid-basic-security ............................... SUCCESS [ 38.704 s]
[INFO] druid-lookups-cached-global ........................ SUCCESS [ 38.533 s]
[INFO] druid-testing-tools ................................ SUCCESS [ 23.734 s]
[INFO] simple-client-sslcontext ........................... SUCCESS [ 35.615 s]
[INFO] druid-multi-stage-query ............................ SUCCESS [ 33.586 s]
[INFO] druid-integration-tests ............................ SUCCESS [ 15.870 s]
[INFO] druid-stats ........................................ SUCCESS [ 26.579 s]
[INFO] druid-benchmarks ................................... SUCCESS [16:36 min]
[INFO] web-console ........................................ SUCCESS [03:13 min]
[INFO] druid-kubernetes-extensions ........................ SUCCESS [ 40.437 s]
[INFO] druid-bloom-filter ................................. SUCCESS [ 26.514 s]
[INFO] druid-kerberos ..................................... SUCCESS [ 37.684 s]
[INFO] druid-pac4j ........................................ SUCCESS [01:32 min]
[INFO] druid-kafka-extraction-namespace ................... SUCCESS [ 27.751 s]
[INFO] postgresql-metadata-storage ........................ SUCCESS [ 36.529 s]
[INFO] druid-lookups-cached-single ........................ SUCCESS [ 37.795 s]
[INFO] druid-ec2-extensions ............................... SUCCESS [ 12.903 s]
[INFO] druid-aws-rds-extensions ........................... SUCCESS [ 18.024 s]
[INFO] druid-ranger-security .............................. SUCCESS [ 27.928 s]
[INFO] druid-catalog ...................................... SUCCESS [ 27.944 s]
[INFO] druid-compressed-bigdecimal ........................ SUCCESS [ 26.610 s]
[INFO] druid-influx-extensions ............................ SUCCESS [ 18.217 s]
[INFO] druid-cassandra-storage ............................ SUCCESS [ 18.025 s]
[INFO] dropwizard-emitter ................................. SUCCESS [ 23.805 s]
[INFO] druid-cloudfiles-extensions ........................ SUCCESS [ 17.012 s]
[INFO] graphite-emitter ................................... SUCCESS [ 19.587 s]
[INFO] druid-distinctcount ................................ SUCCESS [ 10.604 s]
[INFO] statsd-emitter ..................................... SUCCESS [ 17.709 s]
[INFO] druid-time-min-max ................................. SUCCESS [ 18.464 s]
[INFO] druid-virtual-columns .............................. SUCCESS [ 10.741 s]
[INFO] druid-thrift-extensions ............................ SUCCESS [01:37 min]
[INFO] ambari-metrics-emitter ............................. SUCCESS [ 18.516 s]
[INFO] sqlserver-metadata-storage ......................... SUCCESS [ 19.559 s]
[INFO] kafka-emitter ...................................... SUCCESS [ 24.949 s]
[INFO] druid-redis-cache .................................. SUCCESS [ 26.273 s]
[INFO] druid-opentsdb-emitter ............................. SUCCESS [ 18.605 s]
[INFO] materialized-view-maintenance ...................... SUCCESS [ 12.990 s]
[INFO] materialized-view-selection ........................ SUCCESS [ 10.710 s]
[INFO] druid-momentsketch ................................. SUCCESS [ 16.658 s]
[INFO] druid-moving-average-query ......................... SUCCESS [ 24.724 s]
[INFO] tdigestsketch ...................................... SUCCESS [ 24.468 s]
[INFO] druid-influxdb-emitter ............................. SUCCESS [ 10.831 s]
[INFO] gce-extensions ..................................... SUCCESS [ 12.939 s]
[INFO] aliyun-oss-extensions .............................. SUCCESS [06:06 min]
[INFO] prometheus-emitter ................................. SUCCESS [ 24.670 s]
[INFO] opentelemetry-emitter .............................. SUCCESS [ 27.024 s]
[INFO] druid-kubernetes-overlord-extensions ............... SUCCESS [ 15.149 s]
[INFO] druid-opentelemetry-extensions ..................... SUCCESS [ 24.180 s]
[INFO] druid-opencensus-extensions ........................ SUCCESS [ 46.575 s]
[INFO] confluent-extensions ............................... SUCCESS [ 10.419 s]
[INFO] distribution ....................................... SUCCESS [ 28.154 s]
[INFO] druid-it-tools ..................................... SUCCESS [ 27.928 s]
[INFO] druid-it-image ..................................... SUCCESS [ 11.596 s]
[INFO] druid-it-cases ..................................... SUCCESS [ 12.904 s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  21:15 min (Wall Clock)
[INFO] Finished at: 2023-05-30T11:38:07+05:30
[INFO] ------------------------------------------------------------------------

Travis Thompson and others added 30 commits May 29, 2023 23:25
The extension packaging included both shaded and unshaded dependencies
in the classpath. Shading should not be necessary in this case.

Also excludes guava dependencies, which are already provided by Druid
and don't need to be added to the extensions jars.
* METRICS-1302: Added prefix support for resource labels.

* Addressed review comments.

* Added and moved configs to ingestion spec, optimized code.

* Addressed review comments

* Updated metric dimesnion and other review comments

* Flipped ternary operator

* Moved from NullHandling to StringUtils.

* Removed unnecessary HashMap.

* Removed verbosity for instance variables.
* Added getters for configs, labels for distribution metric.

* Addressed review comments

* Removed extra brackets in JsonProperty.
Align protobuf dependencies to use the main pom one
- fix millisecond resolution being dropped when converting timestamps
- remove unnecessary conversion of ByteBuffer to ByteString
- make test code a little more concise
- remove the need to parse timestamps into their own column
- reduce the number of times we copy maps of labels
- pre-size hashmaps and arrays when possible
- use loops instead of streams in critical sections

Combined these changes improve parsing performance by about 15%
- added benchmark for reference
…tFormat (#26)

InputRowParsers have been deprecated in favor or InputFormat.
This implements the InputFormat version of the OpenCensus Protobuf
parser, and deprecates the existing InputRowParser implementation.

- the existing InputRowParser behavior is unchanged.
- the InputFormat behaves like the InputRowParser, except for the
  default resource prefix which now defaults to "resource." instead of
  empty.
- both implementations internally delegate to OpenCensusProtobufReader,
  which is covered by the existing InputRowParser tests.
…roduction of SettableByteEntity (#113)

* OBSDATA-483: Adapt opencensus extension to the introduction of SettableByteEntity

* OBSDATA-483: Adapt opentelemetry extension to the introduction of SettableByteEntity

* OBSDATA-483: Decide which reader to instantiate on read between opencensus and opentelemetry

* OBSDATA-483: Add logger config in opencensus tests

* OBSDATA-483: Fix issue with opening the byte entity

* OBSDATA-483: Instantiate the right iterator in every read request

* OBSDATA-483: Add comments

* OBSDATA-483: Address Xavier's comments

* OBSDATA-483: Remove unused member fields

* OBSDATA-483: Rename enum

* OBSDATA-483: Fix trace log to actually print the argument

* OBSDATA-483: Keep passing the underlying byte buffer and move its position explicitly

* OBSDATA-483: Fix checkstyle issues

* OBSDATA-483: Add back handling of InvalidProtocolBufferException

* OBSDATA-483: Extend the semaphore workflow execution time to 2 hours

* Revert "OBSDATA-483: Extend the semaphore workflow execution time to 2 hours"

* OBSDATA-483: Don't close iterator in sample
Co-authored-by: Confluent Jenkins Bot <jenkins@confluent.io>
…125)

* Upgrade proto version
* Fix names and tests - Upgrade version
* Fix open census tests
* Fix test name
* bumping version of java to 17 for semaphore test run

* bumping java version to 17 as per https://github.com/confluentinc/druid/pull/127/files

* After speaking with Xavier, made these changes
) (#131)

Co-authored-by: Tejaswini Bandlamudi <96047043+tejaswini-imply@users.noreply.github.com>
Comment thread distribution/docker/Dockerfile
Comment thread web-console/README.md
Comment thread web-console/src/ace-modes/hjson.js
Comment thread .semaphore/semaphore.yml
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a few comments. Please check

&& tar -zxf ./distribution/target/apache-druid-${VERSION}-bin.tar.gz -C /opt \
&& mv /opt/apache-druid-${VERSION} /opt/druid
RUN tar -zxf /src/apache-druid-${VERSION}-bin.tar.gz -C /opt \
&& ln -s /opt/apache-druid-${VERSION} /opt/druid
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there were quite a few changes upstream to the docker build (e.g. apache#11299) If you've tested the build and it work then we can do it as a follow-up but, since it looks like this was done prior to 24.x and we missed it, but this might be a good time to do it and avoid further drift since it might bite us later.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey Xavier Léauté (@xvrl) !
I have tested the build - I will submit a follow up PR for this.

@m-ghazanfar Mohammad Ghazanfar (m-ghazanfar) merged commit dc00aaf into 25.0.0-confluent-rc1 Jun 6, 2023
@m-ghazanfar Mohammad Ghazanfar (m-ghazanfar) deleted the OBSDATA-1354-druid-25-with-cflt-patches branch June 6, 2023 04:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.