pulsar icon indicating copy to clipboard operation
pulsar copied to clipboard

[feat][website] REST API URL does not go to the correct place

Open Anonymitaet opened this issue 2 years ago • 15 comments

All REST API URL on Pulsar documentation has this issue.

Website: https://pulsar.apache.org/docs/en/next/admin-api-tenants/

image

@urfreespace thinks the anchor does not work correctly but we have not figured out how to solve this issue

Anyone would like to fix it? Thanks

Anonymitaet avatar Mar 29 '22 10:03 Anonymitaet

The issue had no activity for 30 days, mark with Stale label.

github-actions[bot] avatar Apr 29 '22 02:04 github-actions[bot]

Feedback from @BewareMyPower:

Hi, I'm reporting a bug of the new website again:joy:The rendering of the REST API is wrong. See https://pulsar.apache.org/docs/next/schema-manage/#topic-level.

We can see GET /admin/v2/topics/:tenant/:namespace/:topic. However, the original text is {@inject: endpoint|GET|/admin/v2/topics/:tenant/:namespace/:topic|operation/schemaCompatibilityStrategy?version=[[pulsar:version_number]]}

It's frustrated that I cannot compare it with the rendering of the old website. (should we add an entry point to the old website?) But the rendering result should be like the 2nd image.

BTW, I think the description Send a PUT request to this endpoint: is redundant. See the 3rd image from https://pulsar.apache.org/docs/next/admin-api-topics.

image image image

Anonymitaet avatar May 19 '22 08:05 Anonymitaet

@Anonymitaet you can access the old website here: https://pulsar.staged.apache.org/ (it's the old website backup, it will be closed AFTER the new site is stable)

urfreespace avatar May 20 '22 04:05 urfreespace

@urfreespace OK, thanks!

Anonymitaet avatar May 20 '22 06:05 Anonymitaet

The issue had no activity for 30 days, mark with Stale label.

github-actions[bot] avatar Jun 20 '22 02:06 github-actions[bot]

The pr https://github.com/apache/pulsar-site/pull/127 submit, maybe fix this problem

horizonzy avatar Jun 29 '22 03:06 horizonzy

@momo-jun I check some occurrences on master, and they do not function well. For example: image https://pulsar.apache.org/docs/next/admin-api-functions

Can you take a look? Thank you!

Anonymitaet avatar Jul 07 '22 09:07 Anonymitaet

@momo-jun your PR was merged 3 hours ago and the website build was done 4 hours ago, maybe that is the reason why the new changes do not take effect. Let's wait for a while to see if it works. Thank you.

Anonymitaet avatar Jul 07 '22 09:07 Anonymitaet

@momo-jun do you update all occurrences only for master or master + other versions?

Anonymitaet avatar Jul 07 '22 09:07 Anonymitaet

@momo-jun do you update all occurrences only for master or master + other versions?

Master only. I want to verify whether they work well before applying the changes to more versions.

momo-jun avatar Jul 07 '22 10:07 momo-jun

@Anonymitaet the issue has been fixed and verified. I will find some time to update those links in versioned docs.

momo-jun avatar Jul 08 '22 01:07 momo-jun

@momo-jun

I check some occurrences randomly and find that:

  1. It shows loading all the time, do you have the same issue? package: https://pulsar.apache.org/docs/next/admin-api-packages image

  2. Some contain version while others not, is this intended behavior?

  • Left: https://pulsar.apache.org/docs/next/admin-api-packages
  • Right: https://pulsar.apache.org/docs/next/admin-api-tenants image

Anonymitaet avatar Jul 08 '22 01:07 Anonymitaet

Same on my side. I checked the MD file and its syntax {@inject: endpoint|POST|/admin/v3/packages/:type/:tenant/:namespace/:packageName/:version} doesn't contain any anchor nor the version number variable, that's why it cannot be loaded. Since it doesn't contain the version number variable, such cases are not covered in the previous fix. I need to use a new search term to clean up this type of occurrence. Thanks for your check.

  1. It shows loading all the time, do you have the same issue? package: https://pulsar.apache.org/docs/next/admin-api-packages
image

The version we can see here does not refer to the injected version number, but a static text. The display text is correct. The only issue is the same as above - the syntax needs to be fixed by adding a version number variable and an anchor.

  1. Some contain version while others not, is this intended behavior?
  • Left: https://pulsar.apache.org/docs/next/admin-api-packages
  • Right: https://pulsar.apache.org/docs/next/admin-api-tenants
image

momo-jun avatar Jul 08 '22 03:07 momo-jun

When searching for the remaining incorrect REST API links, I found the REST API docs missed "lookup topic" and "get bundles". @shibd helped checked the issue in code and pushed a PR-#16470 to fix it.

I've fixed other incorrect REST API links in #16433 and will update for "lookup topic" and "get bundles" as soon as #16470 is merged.

momo-jun avatar Jul 08 '22 07:07 momo-jun

The issue had no activity for 30 days, mark with Stale label.

github-actions[bot] avatar Aug 08 '22 02:08 github-actions[bot]

This issue can be closed after #16746 is merged. Any other problematic occurrence is an individual case of error.

momo-jun avatar Aug 15 '22 09:08 momo-jun