Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OSDOCS-4073: Dynamic plug-in doc updates #53103

Merged
merged 1 commit into from
Jan 11, 2023
Merged

Conversation

opayne1
Copy link
Contributor

@opayne1 opayne1 commented Nov 22, 2022

This is a work in progress PR to reorg the dynamic plug-in documentation

Version(s):
4.12 (with plans to backport to 4.11)

Issue:
https://issues.redhat.com/browse/OSDOCS-4073

Link to docs preview:
https://53103--docspreview.netlify.app/openshift-enterprise/latest/web_console/dynamic-plug-in/dynamic-plug-in.html

QE review:

  • QE has approved this change.

@openshift-ci openshift-ci bot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Nov 22, 2022
@opayne1 opayne1 force-pushed the OSDOCS-4073 branch 5 times, most recently from 2ed9b6e to 62486fc Compare November 29, 2022 16:53
@ocpdocs-previewbot
Copy link

ocpdocs-previewbot commented Nov 29, 2022

🤖 Updated build preview is available at:
https://53103--docspreview.netlify.app

Build log: https://circleci.com/gh/ocpdocs-previewbot/openshift-docs/6763

@opayne1 opayne1 force-pushed the OSDOCS-4073 branch 3 times, most recently from b13c123 to f1fa01f Compare November 30, 2022 14:28
Copy link
Member

@spadgett spadgett left a comment

Choose a reason for hiding this comment

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

Thanks, @opayne1

modules/adding-tab-pods-page.adoc Outdated Show resolved Hide resolved
modules/deployment-plug-in-cluster.adoc Outdated Show resolved Hide resolved
modules/dynamic-plug-in-development.adoc Outdated Show resolved Hide resolved
modules/dynamic-plug-in-development.adoc Outdated Show resolved Hide resolved
modules/dynamic-plug-in-development.adoc Outdated Show resolved Hide resolved
modules/dynamic-plug-in-development.adoc Outdated Show resolved Hide resolved
modules/dynamic-plug-in-development.adoc Outdated Show resolved Hide resolved
modules/dynamic-plug-in-sdk-extensions.adoc Outdated Show resolved Hide resolved
modules/troubleshooting-dynamic-plug-in.adoc Outdated Show resolved Hide resolved
modules/troubleshooting-dynamic-plug-in.adoc Outdated Show resolved Hide resolved
<1> Update the name of your plug-in.
<2> Update the version.
<3> Update the display name for your plug-in.
<4> Update the description with a synopsis about your plug-in.
Copy link
Member

Choose a reason for hiding this comment

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

It's a little odd we don't have them run the plugin first before making any edits. It would be good to show the hello world stuff working before anything else. I think this underscores how easy it is to get running.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I added a additional resource link to it before the procedure to edit

Copy link
Member

Choose a reason for hiding this comment

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

I think that can work, but it still seems more natural to me to

  1. Clone the project
  2. Update the plugin metadata
  3. Run everything to see it working

This seems particularly true if you use yarn run start since it will automatically update the UI when you make the changes below without having to restart your server. The browser will just refresh with your changes.

@opayne1 opayne1 added this to the Planned for 4.12 GA milestone Jan 6, 2023
@opayne1 opayne1 force-pushed the OSDOCS-4073 branch 2 times, most recently from d619b7c to a5b5f2f Compare January 6, 2023 19:18
Copy link
Member

@spadgett spadgett left a comment

Choose a reason for hiding this comment

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

Thanks @opayne1 !

<1> Update the name of your plug-in.
<2> Update the version.
<3> Update the display name for your plug-in.
<4> Update the description with a synopsis about your plug-in.
Copy link
Member

Choose a reason for hiding this comment

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

I think that can work, but it still seems more natural to me to

  1. Clone the project
  2. Update the plugin metadata
  3. Run everything to see it working

This seems particularly true if you use yarn run start since it will automatically update the UI when you make the changes below without having to restart your server. The browser will just refresh with your changes.

modules/troubleshooting-dynamic-plug-in.adoc Outdated Show resolved Hide resolved
modules/troubleshooting-dynamic-plug-in.adoc Outdated Show resolved Hide resolved
modules/troubleshooting-dynamic-plug-in.adoc Outdated Show resolved Hide resolved
modules/troubleshooting-dynamic-plug-in.adoc Outdated Show resolved Hide resolved
web_console/dynamic-plug-in/dynamic-plug-in.adoc Outdated Show resolved Hide resolved
modules/dynamic-plug-in-development.adoc Outdated Show resolved Hide resolved
@opayne1 opayne1 changed the title [WIP] OSDOCS-4073: Dynamic plug-in doc updates OSDOCS-4073: Dynamic plug-in doc updates Jan 6, 2023
@openshift-ci openshift-ci bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jan 6, 2023
@opayne1
Copy link
Contributor Author

opayne1 commented Jan 6, 2023

@yapei could you please provide a QE review of this PR? Just some background, we were unable to link to the template repo the way we had before due to support reasons, so we have included it in an example as a workaround. Thank you!

+
[source,terminal]
----
yarn install
Copy link

Choose a reason for hiding this comment

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

Shall we clarify user should be in the local forked console-plugin-template folder to run all following commands?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I am not sure we are able to do this here. When Sam and I talked to support, the only way we are able to link to the template repo is with an example. I have added this page as an additional resource at the beginning of the "Adding a tab to the pods page" example. cc @spadgett

[discrete]
== `Timestamp`

A component to render timestamp. The timestamps are synchronized between invidual instances of the Timestamp component. The provided timestamp is formatted according to user locale.
Copy link
Contributor

Choose a reason for hiding this comment

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

s/invidual/individual

namespace option is selected. It accepts the new namespace in the form
of a string as its only argument. The active namespace is updated
automatically when an option is selected, but additional logic can be
applied via this function. When the namespace is changed, the namespace
Copy link
Contributor

Choose a reason for hiding this comment

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

s/via/through

[discrete]
== `ErrorBoundaryFallbackPage`

Creates full page ErrorBoundaryFallbackPage component to display the "Oh no! Something went wrong." message along with the stack trace and other helpful debugging information. This is to be used inconjunction with an component.
Copy link
Contributor

Choose a reason for hiding this comment

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

s/Create/Creates a
s/inconjunction/in conjunction

[discrete]
== `useAccessReviewAllowed`

@deprecated - Use useAccessReview from @console/dynamic-plugin-sdk instead.Hook that provides allowed status about user access to a given
Copy link
Contributor

Choose a reason for hiding this comment

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

S/instead.Hook/instead. Hook

[discrete]
== `useSafetyFirst`

@deprecated - This hook is not related to console functionality.Hook that ensures a safe asynchronnous setting of React state in case a given
Copy link
Contributor

Choose a reason for hiding this comment

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

S/functionality.Hook/functionality. Hook
S/React state/the React state ??
(facebook/react#14113)

== `ResourceYAMLEditor`

A lazy loaded YAML editor for Kubernetes resources with hover help and completion. The component use the YAMLEditor and add on top of it more functionality likeresource update handling, alerts, save, cancel and reload buttons, accessibility and more. Unless `onSave` callback is provided, the resource update is automatically handled.It should be
wrapped in a React.Suspense component.
Copy link
Contributor

Choose a reason for hiding this comment

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

s/React.Suspense/React.Suspense or some markup

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Going to leave all of these comments unresolved. Will be a good reference point for updating the API doc source in the openshift/console repo.

@mburke5678
Copy link
Contributor

mburke5678 commented Jan 10, 2023

@opayne1 A whole bunch of nit-level suggestions for the most part. As we discussed, the edits to the reference modules will be addressed later. This table in the reference module should be fixed, if possible. It seems unusable.
Tons of work! Looks great overall. LMK if you want me to look again later.

@mburke5678 mburke5678 added peer-review-done Signifies that the peer review team has reviewed this PR and removed peer-review-in-progress Signifies that the peer review team is reviewing this PR peer-review-needed Signifies that the peer review team needs to review this PR labels Jan 10, 2023
@spadgett
Copy link
Member

I opened https://issues.redhat.com/browse/OCPBUGS-5571 to track updating the API doc source in the openshift/console repo.


.Procedure

. Visit the link:https://github.com/openshift/console-plugin-template[`console-plugin-template`] repository containing a template for creating plug-ins in a new tab.
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@sferich888 FYI on the GH link based on a discussion we had a while ago to add it to an example.

Copy link
Contributor

Choose a reason for hiding this comment

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

@alimobrem I assume support for plugin development falls in line with: https://access.redhat.com/solutions/5893251

If so if we can put a call out on the example page to this; we can approve the link to github.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Note added. Thank you, Eric!

@opayne1 opayne1 force-pushed the OSDOCS-4073 branch 4 times, most recently from 51540a3 to 16f01bd Compare January 11, 2023 21:42
@opayne1 opayne1 merged commit 4fb3830 into openshift:main Jan 11, 2023
@opayne1
Copy link
Contributor Author

opayne1 commented Jan 11, 2023

/cherrypick enterprise-4.12

@openshift-cherrypick-robot

@opayne1: new pull request created: #54554

In response to this:

/cherrypick enterprise-4.12

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
branch/enterprise-4.12 peer-review-done Signifies that the peer review team has reviewed this PR size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants