Skip to content

Commit

Permalink
Fixes formatting and typos in documentation (opensearch-project#1697)
Browse files Browse the repository at this point in the history
Resolves opensearch-project#592

Signed-off-by: Tommy Markley <[email protected]>
  • Loading branch information
Tommy Markley authored Jun 13, 2022
1 parent 3ff99cf commit 89d3872
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
3 changes: 1 addition & 2 deletions TYPESCRIPT.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,7 @@ The first thing that will probably happen when you convert a `.js` file in our s

#### EUI component is missing types

1. Check https://github.com/elastic/eui/issues/256 to see if they know it’s missing, if it’s not on there, add it.
2. Temporarily get around the issue by adding the missing type in the `typings/@elastic/eui/index.d.ts` file. Bonus points if you write a PR yourself to the EUI repo to add the types, but having them available back in OpenSearch Dashboards will take some time, as a new EUI release will need to be generated, then that new release pointed to in OpenSearch Dashboards. Best, to make forward progress, to do a temporary workaround.
Temporarily get around the issue by adding the missing type in the `typings/@elastic/eui/index.d.ts` file. Bonus points if you write a PR yourself to the EUI repo to add the types, but having them available back in OpenSearch Dashboards will take some time, as a new EUI release will need to be generated, then that new release pointed to in OpenSearch Dashboards. Best, to make forward progress, to do a temporary workaround.

```ts
// typings/@elastic/eui/index.d.ts
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@ function getConfig(config) {
projectRoot: true,
};

if (!config || !config['@elastic/eslint-import-resolver-kibana']) return defaults;
return Object.assign(defaults, config['@elastic/eslint-import-resolver-kibana']);
if (!config || !config['@osd/eslint-import-resolver-opensearch-dashboards']) return defaults;
return Object.assign(defaults, config['@osd/eslint-import-resolver-opensearch-dashboards']);
}

function getRootPackageDir(dirRoot, dir, rootPackageName) {
Expand Down
4 changes: 2 additions & 2 deletions src/core/server/saved_objects/migrations/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Here is the gist of what happens if an index migration is necessary:
- Create an alias `.opensearch_dashboards` that points to `.opensearch_dashboards_1`
- Create a `.opensearch_dashboards_2` index
- Copy all documents from `.opensearch_dashboards_1` into `.opensearch_dashboards_2`, running them through any applicable migrations
- # Point the `.opensearch_dashboards` alias to `.opensearch_dashboards_2`
- Point the `.opensearch_dashboards` alias to `.opensearch_dashboards_2`

## Migrating OpenSearch Dashboards clusters

Expand All @@ -30,7 +30,7 @@ If OpenSearch Dashboards is being run in a cluster, migrations will be coordinat
- opensearch-dashboards-2 tries to begin the migration, but fails with the error `.opensearch_dashboards_4 already exists`
- opensearch-dashboards-2 logs that it failed to create the migration index, and instead begins polling
- Every few seconds, opensearch-dashboards-2 instance checks the `.opensearch_dashboards` index to see if it is done migrating
- # Once `.opensearch_dashboards` is determined to be up to date, the opensearch-dashboards-2 instance continues booting
- Once `.opensearch_dashboards` is determined to be up to date, the opensearch-dashboards-2 instance continues booting

In this example, if the `.opensearch_dashboards_4` index existed prior to OpenSearch Dashboards booting, the entire migration process will fail, as all OpenSearch Dashboards instances will assume another instance is migrating to the `.opensearch_dashboards_4` index. This problem is only fixable by deleting the `.opensearch_dashboards_4` index.

Expand Down

0 comments on commit 89d3872

Please sign in to comment.