Skip to content

Commit

Permalink
[1.x][Docs] Update doc refs from beta to prod (#742)
Browse files Browse the repository at this point in the history
Updating references to the doc site from docs-beta.opensearch.org
to the production site of opensearch.org/docs.

Did not remove the TODOs because we do not have replacements for the
content yet.

Issue partially resolved:
#335

Backport PR:
#733

Signed-off-by: Kawika Avilla <kavilla414@gmail.com>
  • Loading branch information
kavilla authored Aug 30, 2021
1 parent d03a916 commit 32e06f2
Show file tree
Hide file tree
Showing 12 changed files with 18 additions and 23 deletions.
4 changes: 1 addition & 3 deletions src/core/public/doc_links/doc_links_service.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,6 @@ describe('DocLinksService#start()', () => {
const service = new DocLinksService();
const api = service.start({ injectedMetadata });
expect(api.DOC_LINK_VERSION).toEqual('test-branch');
expect(api.links.opensearchDashboards).toEqual(
'https://docs-beta.opensearch.org/docs/opensearch-dashboards/'
);
expect(api.links.opensearchDashboards).toEqual('https://opensearch.org/docs/dashboards/');
});
});
4 changes: 2 additions & 2 deletions src/core/public/doc_links/doc_links_service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ export class DocLinksService {
public start({ injectedMetadata }: StartDeps): DocLinksStart {
const DOC_LINK_VERSION = injectedMetadata.getOpenSearchDashboardsBranch();
const OPENSEARCH_WEBSITE_URL = 'https://www.opensearch.org/';
const OPENSEARCH_DOCS = `https://docs-beta.opensearch.org/docs/opensearch/`;
const OPENSEARCH_DASHBOARDS_DOCS = `https://docs-beta.opensearch.org/docs/opensearch-dashboards/`;
const OPENSEARCH_DOCS = `https://opensearch.org/docs/opensearch/`;
const OPENSEARCH_DASHBOARDS_DOCS = `https://opensearch.org/docs/dashboards/`;

return deepFreeze({
DOC_LINK_VERSION,
Expand Down
2 changes: 1 addition & 1 deletion src/core/server/ui_settings/settings/date_formats.ts
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ export const getDateFormatSettings = (): Record<string, UiSettingsParams> => {
dateNanosLink:
// TODO: [RENAMEME] Need prod urls.
// issue: https://github.com/opensearch-project/OpenSearch-Dashboards/issues/335#issuecomment-868294864
'<a href="https://docs-beta.opensearch.org/opensearch/units" target="_blank" rel="noopener noreferrer">' +
'<a href="https://opensearch.org/docs/opensearch/units" target="_blank" rel="noopener noreferrer">' +
i18n.translate('core.ui_settings.params.dateNanosLinkTitle', {
defaultMessage: 'date_nanos',
}) +
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,6 @@
"{indices}/_msearch",
"{indices}/{type}/_msearch"
],
"documentation": "https://docs-beta.opensearch.org/opensearch/query-dsl/full-text/#multi-match"
"documentation": "https://opensearch.org/docs/opensearch/query-dsl/full-text/#multi-match"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@
"{indices}/_msearch/template",
"{indices}/{type}/_msearch/template"
],
"documentation": "https://docs-beta.opensearch.org/opensearch/query-dsl/full-text/#multi-match"
"documentation": "https://opensearch.org/docs/opensearch/query-dsl/full-text/#multi-match"
}
}
12 changes: 6 additions & 6 deletions src/plugins/data/server/ui_settings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ export function getUiSettings(): Record<string, UiSettingsParams<unknown>> {
optionsLink:
// TODO: [RENAMEME] Need prod urls.
// issue: https://github.com/opensearch-project/OpenSearch-Dashboards/issues/335#issuecomment-868294864
'<a href="https://docs-beta.opensearch.org/opensearch/query-dsl/index" target="_blank" rel="noopener">' +
'<a href="https://opensearch.org/docs/opensearch/query-dsl/index" target="_blank" rel="noopener">' +
i18n.translate('data.advancedSettings.query.queryStringOptions.optionsLinkText', {
defaultMessage: 'Options',
}) +
Expand Down Expand Up @@ -167,7 +167,7 @@ export function getUiSettings(): Record<string, UiSettingsParams<unknown>> {
'data.advancedSettings.sortOptionsText',
values: {
optionsLink:
'<a href="https://docs-beta.opensearch.org/opensearch/ux/#sort-results" target="_blank" rel="noopener">' +
'<a href="https://opensearch.org/docs/opensearch/ux/#sort-results" target="_blank" rel="noopener">' +
i18n.translate('data.advancedSettings.sortOptions.optionsLinkText', {
defaultMessage: 'Options',
}) +
Expand Down Expand Up @@ -249,7 +249,7 @@ export function getUiSettings(): Record<string, UiSettingsParams<unknown>> {
setRequestReferenceSetting: `<strong>${UI_SETTINGS.COURIER_SET_REQUEST_PREFERENCE}</strong>`,
customSettingValue: '"custom"',
requestPreferenceLink:
'<a href="https://docs-beta.opensearch.org/opensearch/popular-api" target="_blank" rel="noopener">' +
'<a href="https://opensearch.org/docs/opensearch/popular-api" target="_blank" rel="noopener">' +
i18n.translate(
'data.advancedSettings.courier.customRequestPreference.requestPreferenceLinkText',
{
Expand All @@ -273,7 +273,7 @@ export function getUiSettings(): Record<string, UiSettingsParams<unknown>> {
'Controls the {maxRequestsLink} setting used for _msearch requests sent by OpenSearch Dashboards. ' +
'Set to 0 to disable this config and use the OpenSearch default.',
values: {
maxRequestsLink: `<a href="https://docs-beta.opensearch.org/opensearch/query-dsl/full-text/#multi-match"
maxRequestsLink: `<a href="https://opensearch.org/docs/opensearch/query-dsl/full-text/#multi-match"
target="_blank" rel="noopener" >max_concurrent_shard_requests</a>`,
},
}),
Expand Down Expand Up @@ -303,7 +303,7 @@ export function getUiSettings(): Record<string, UiSettingsParams<unknown>> {
},
[UI_SETTINGS.SEARCH_INCLUDE_FROZEN]: {
name: 'Search in frozen indices',
description: `Will include <a href="https://docs-beta.opensearch.org/opensearch/index-data"
description: `Will include <a href="https://opensearch.org/docs/opensearch/index-data"
target="_blank" rel="noopener">frozen indices</a> in results if enabled. Searching through frozen indices
might increase the search time.`,
value: false,
Expand Down Expand Up @@ -652,7 +652,7 @@ export function getUiSettings(): Record<string, UiSettingsParams<unknown>> {
'data.advancedSettings.timepicker.quickRanges.acceptedFormatsLinkText',
values: {
acceptedFormatsLink:
`<a href="https://docs-beta.opensearch.org/opensearch/units"
`<a href="https://opensearch.org/docs/opensearch/units"
target="_blank" rel="noopener">` +
i18n.translate('data.advancedSettings.timepicker.quickRanges.acceptedFormatsLinkText', {
defaultMessage: 'accepted formats',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ import {

/**
* Returns `OpenSearchQuerySort` which is used to sort records in the OpenSearch query
* https://docs-beta.opensearch.org/opensearch/ux/#sort-results
* https://opensearch.org/docs/opensearch/ux/#sort-results
* @param timeField
* @param tieBreakerField
* @param sortDir
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ export const EditIndexPattern = withRouter(
<EuiLink
// TODO: [RENAMEME] Need prod urls.
// issue: https://github.com/opensearch-project/OpenSearch-Dashboards/issues/335#issuecomment-868294864
href="https://docs-beta.opensearch.org/opensearch/index-templates"
href="https://opensearch.org/docs/opensearch/index-templates"
target="_blank"
external
>
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 1 addition & 4 deletions src/plugins/maps_legacy/public/map/map_messages.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,10 +115,7 @@ export const createZoomWarningMsg = (function () {
// TODO: [RENAMEME] Need prod urls.
values={{
wms: (
<a
target="_blank"
href="https://docs-beta.opensearch.org/docs/opensearch-dashboards/maptiles"
>
<a target="_blank" href="https://opensearch.org/docs/dashboards/maptiles/">
{`Custom WMS Configuration`}
</a>
),
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/maps_legacy/server/ui_settings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ export function getUiSettings(): Record<string, UiSettingsParams<unknown>> {
cellDimensionsLink:
// TODO: [RENAMEME] Need prod urls.
// issue: https://github.com/opensearch-project/OpenSearch-Dashboards/issues/335#issuecomment-868294864
`<a href="https://docs-beta.opensearch.org/dashboards/maptiles"
`<a href="https://opensearch.org/docs/dashboards/maptiles"
target="_blank" rel="noopener">` +
i18n.translate(
'maps_legacy.advancedSettings.visualization.tileMap.maxPrecision.cellDimensionsLinkText',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ function VegaHelpMenu() {
key="vegaHelp"
// TODO: [RENAMEME] Need prod urls.
// issue: https://github.com/opensearch-project/OpenSearch-Dashboards/issues/335#issuecomment-868294864
href="https://docs-beta.opensearch.org/docs/opensearch-dashboards"
href="https://opensearch.org/docs/dashboards"
target="_blank"
onClick={closePopover}
>
Expand Down

0 comments on commit 32e06f2

Please sign in to comment.