Skip to content

Commit

Permalink
Add changeset. Change awsS3-discovery to s3-discovery. Change depende…
Browse files Browse the repository at this point in the history
…ncies

Signed-off-by: Sean Tan <seant@splunk.com>
  • Loading branch information
seant-splunk committed Sep 15, 2021
1 parent 72289da commit fab79ad
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 6 deletions.
6 changes: 6 additions & 0 deletions .changeset/curvy-books-help.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
'@backstage/backend-common': patch
'@backstage/plugin-catalog-backend': patch
---

Add AWS S3 Discovery Processor. Add readTree() to AwsS3UrlReader. Add ReadableArrayResponse type that implements ReadTreeResponse to use in AwsS3UrlReader's readTree()
4 changes: 2 additions & 2 deletions docs/integrations/aws-s3/discovery.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ configuration:
```yaml
catalog:
locations:
- type: awsS3-discovery
- type: s3-discovery
target: https://sample-bucket.s3.us-east-2.amazonaws.com/
```

Note the `awsS3-discovery` type, as this is not a regular `url` processor.
Note the `s3-discovery` type, as this is not a regular `url` processor.
2 changes: 1 addition & 1 deletion plugins/catalog-backend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@
"@octokit/graphql": "^4.5.8",
"@types/express": "^4.17.6",
"aws-sdk": "^2.840.0",
"aws-sdk-mock": "^5.2.1",
"codeowners-utils": "^1.0.2",
"core-js": "^3.6.5",
"cross-fetch": "^3.0.6",
Expand Down Expand Up @@ -73,6 +72,7 @@
"@types/supertest": "^2.0.8",
"@types/uuid": "^8.0.0",
"@types/yup": "^0.29.8",
"aws-sdk-mock": "^5.2.1",
"msw": "^0.29.0",
"sqlite3": "^5.0.1",
"supertest": "^6.1.3",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ const reader = UrlReaders.default({
describe('readLocation', () => {
const processor = new AwsS3DiscoveryProcessor(reader);
const spec = {
type: 'awsS3-discovery',
type: 's3-discovery',
target: 'https://testbucket.s3.us-east-2.amazonaws.com',
};

Expand All @@ -71,7 +71,7 @@ describe('readLocation', () => {
expect(generated.type).toBe('entity');
expect(generated.location).toEqual({
target: 'awsS3-mock-object.txt',
type: 'awsS3-discovery',
type: 's3-discovery',
});
expect(generated.entity).toEqual({ site_name: 'Test' });
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export class AwsS3DiscoveryProcessor implements CatalogProcessor {
emit: CatalogProcessorEmit,
parser: CatalogProcessorParser,
): Promise<boolean> {
if (location.type !== 'awsS3-discovery') {
if (location.type !== 's3-discovery') {
return false;
}

Expand Down

0 comments on commit fab79ad

Please sign in to comment.