Skip to content

Add support for using Oxia as the metadata store for Pulsar and BookKeeper - #544

Merged
lhotari merged 68 commits into
apache:masterfrom
yuweisung:add-oxia-subchart
Nov 22, 2024
Merged

lhotari merged 68 commits into
apache:masterfrom
yuweisung:add-oxia-subchart

Conversation

@yuweisung

Copy link
Copy Markdown
Contributor

Feature: add oxia template

Motivation

Adding oxia templates in helmchart.

Modifications

Just add the template with the correct variables.
The oxia component is disabled in default values.yaml.

Verifying this change

  • Make sure that the change passes the CI checks.

@yuweisung

Copy link
Copy Markdown
Contributor Author

next step: disable zk and modify the init script to integrate pulsar with oxia.

@yuweisung

yuweisung commented Nov 6, 2024 •

Copy link
Copy Markdown
Contributor Author

what's done:

  1. add oxia templates from streamnative.
  2. add oxia components in Values.yaml
  3. modify the oxia templates to fit Values.yaml
  4. verify the template by "helm template test1 ." locally.

@yuweisung yuweisung changed the title Add-oxia-template feature: add-oxia-template Nov 6, 2024
@yuweisung yuweisung changed the title feature: add-oxia-template feat: add-oxia-template Nov 6, 2024
@yuweisung yuweisung changed the title feat: add-oxia-template feat: add oxia template Nov 6, 2024
@lhotari

lhotari commented Nov 21, 2024

Copy link
Copy Markdown
Member

Last logs on coordinator:

│ {"level":"info","time":"2024-11-21T12:38:36.001675891Z","component":"shard-controller","namespace":"bookkeeper","shard":1,"term":13,"time":"2024-11-21T12:38:36.001711227Z","message":"Starting leader election"}                                                                                                                                                              │
│ {"level":"info","time":"2024-11-21T12:38:36.033715641Z","component":"shard-controller","entry-id":{"term":"-1", "offset":"-1"},"namespace":"bookkeeper","server-address":{"public":"pulsar-ci-oxia-svc.pulsar.svc.cluster.local:6648","internal":"pulsar-ci-oxia-svc.pulsar.svc:6649"},"shard":1,"time":"2024-11-21T12:38:36.033813915Z","message":"Processed newTerm response │
│ {"level":"info","time":"2024-11-21T12:38:36.033840474Z","component":"shard-controller","followers":[],"namespace":"bookkeeper","new-leader":{"public":"pulsar-ci-oxia-svc.pulsar.svc.cluster.local:6648","internal":"pulsar-ci-oxia-svc.pulsar.svc:6649"},"shard":1,"term":13,"time":"2024-11-21T12:38:36.033903832Z","message":"Successfully moved ensemble to a new term"}   │
│ {"level":"info","time":"2024-11-21T12:38:36.04050441Z","component":"shard-controller","leader":{"public":"pulsar-ci-oxia-svc.pulsar.svc.cluster.local:6648","internal":"pulsar-ci-oxia-svc.pulsar.svc:6649"},"namespace":"bookkeeper","shard":1,"term":13,"time":"2024-11-21T12:38:36.040516162Z","message":"Elected new leader"}                                              │
│ {"level":"info","time":"2024-11-21T12:38:36.040532943Z","component":"shard-controller","leader":{"public":"pulsar-ci-oxia-svc.pulsar.svc.cluster.local:6648","internal":"pulsar-ci-oxia-svc.pulsar.svc:6649"},"namespace":"bookkeeper","shard":1,"time":"2024-11-21T12:38:36.040539566Z","message":"Shard is ready"}                                                           │
│ {"level":"info","time":"2024-11-21T12:38:37.967300662Z","component":"shard-controller","namespace":"broker","shard":0,"term":13,"time":"2024-11-21T12:38:37.967319758Z","message":"Starting leader election"}                                                                                                                                                                  │
│ {"level":"info","time":"2024-11-21T12:38:37.99129862Z","component":"shard-controller","entry-id":{"term":"-1", "offset":"-1"},"namespace":"broker","server-address":{"public":"pulsar-ci-oxia-svc.pulsar.svc.cluster.local:6648","internal":"pulsar-ci-oxia-svc.pulsar.svc:6649"},"shard":0,"time":"2024-11-21T12:38:37.991327354Z","message":"Processed newTerm response"}    │
│ {"level":"info","time":"2024-11-21T12:38:37.991407553Z","component":"shard-controller","followers":[],"namespace":"broker","new-leader":{"public":"pulsar-ci-oxia-svc.pulsar.svc.cluster.local:6648","internal":"pulsar-ci-oxia-svc.pulsar.svc:6649"},"shard":0,"term":13,"time":"2024-11-21T12:38:37.991421479Z","message":"Successfully moved ensemble to a new term"}       │
│ {"level":"info","time":"2024-11-21T12:38:38.002184498Z","component":"shard-controller","leader":{"public":"pulsar-ci-oxia-svc.pulsar.svc.cluster.local:6648","internal":"pulsar-ci-oxia-svc.pulsar.svc:6649"},"namespace":"broker","shard":0,"term":13,"time":"2024-11-21T12:38:38.002203163Z","message":"Elected new leader"}                                                 │
│ {"level":"info","time":"2024-11-21T12:38:38.002277151Z","component":"shard-controller","leader":{"public":"pulsar-ci-oxia-svc.pulsar.svc.cluster.local:6648","internal":"pulsar-ci-oxia-svc.pulsar.svc:6649"},"namespace":"broker","shard":0,"time":"2024-11-21T12:38:38.002287801Z","message":"Shard is ready"}

@lhotari

lhotari commented Nov 21, 2024

Copy link
Copy Markdown
Member

@yuweisung If you'd like to debug issues in GitHub Actions, you can ssh into the running build job VM when you open a PR to your own fork. ssh authentication will happen with your public keys at https://github.com/yuweisung.keys .
This is how I've been working on this: lhotari#12 .
Each job will have ssh connection details.
image
You can run "k9s" after the k8s cluster is running.

Attempt to fix
io.grpc.StatusRuntimeException: UNIMPLEMENTED: unknown service io.streamnative.oxia.proto.OxiaClient

Since found this error in the logs:
  rpc error: code = Code(110) desc = oxia: namespace not found
  Failed to add client for shards assignments notifications
- org.apache.bookkeeper.stream.storage.impl.cluster.ZkClusterInitializer is the only implementation
@lhotari

lhotari commented Nov 22, 2024

Copy link
Copy Markdown
Member

One gap in Pulsar is the lack of a org.apache.pulsar.packages.management.core.PackagesStorage implementation that works with Oxia. The org.apache.pulsar.packages.management.storage.bookkeeper.BookKeeperPackagesStorage implementation uses the DistributedLog library which requires Zookeeper.

error message:

pulsar-ci-toolset-0:/pulsar$ bin/pulsar-admin functions create --tenant pulsar-ci --namespace test --name test-function --inputs "pulsar-ci/test/test_input" --output "pulsar-ci/test/test_output" --parallelism 1 --classname org.apache.pulsar.functions.api.examples.ExclamationFunction --jar /pulsar/examples/api-examples.jar
Cannot invoke "org.apache.distributedlog.api.namespace.Namespace.logExists(String)" because "dlogNamespace" is null

Reason: Cannot invoke "org.apache.distributedlog.api.namespace.Namespace.logExists(String)" because "dlogNamespace" is null

I have disabled function tests for Oxia in CI to make the tests pass. We can merge this PR without functions support for Oxia.

@lhotari
lhotari merged commit c6ce11a into apache:master Nov 22, 2024
lhotari added a commit to lhotari/pulsar-helm-chart that referenced this pull request Feb 19, 2025
lhotari added a commit that referenced this pull request Feb 19, 2025
…572)

* Fix pulsar-cluster-initialize / pulsar-init rendering with kustomize

- reapply #166 changes that were reverted by #544 changes

* Add validation for kustomize output in CI
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.

3 participants