Skip to content

Commit 0c82c4a

Browse files
authored
Source gainsight-px: Migrate to manifest-only (#44414)
1 parent 9eaa524 commit 0c82c4a

File tree

13 files changed

+2494
-2389
lines changed

13 files changed

+2494
-2389
lines changed
Original file line numberDiff line numberDiff line change
@@ -1,78 +1,65 @@
1-
# Gainsight Px Source
1+
# Gainsight PX source connector
22

3-
This is the repository for the Gainsight Px configuration based source connector.
4-
For information about how to use this connector within Airbyte, see [the documentation](https://docs.airbyte.com/integrations/sources/gainsight-px).
3+
This directory contains the manifest-only connector for `source-gainsight-px`.
4+
This _manifest-only_ connector is not a Python package on its own, as it runs inside of the base `source-declarative-manifest` image.
55

6-
## Local development
6+
For information about how to configure and use this connector within Airbyte, see [the connector's full documentation](https://docs.airbyte.com/integrations/sources/gainsight-px).
77

8-
#### Create credentials
8+
## Local development
99

10-
**If you are a community contributor**, follow the instructions in the [documentation](https://docs.airbyte.com/integrations/sources/gainsight-px)
11-
to generate the necessary credentials. Then create a file `secrets/config.json` conforming to the `source_gainsight_px/spec.yaml` file.
12-
Note that any directory named `secrets` is gitignored across the entire Airbyte repo, so there is no danger of accidentally checking in sensitive information.
13-
See `integration_tests/sample_config.json` for a sample config file.
10+
We recommend using the Connector Builder to edit this connector.
11+
Using either Airbyte Cloud or your local Airbyte OSS instance, navigate to the **Builder** tab and select **Import a YAML**.
12+
Then select the connector's `manifest.yaml` file to load the connector into the Builder. You're now ready to make changes to the connector!
1413

15-
**If you are an Airbyte core member**, copy the credentials in Lastpass under the secret name `source gainsight-px test creds`
16-
and place them into `secrets/config.json`.
14+
If you prefer to develop locally, you can follow the instructions below.
1715

18-
### Locally running the connector docker image
16+
### Building the docker image
1917

20-
#### Build
18+
You can build any manifest-only connector with `airbyte-ci`:
2119

22-
**Via [`airbyte-ci`](https://github.com/airbytehq/airbyte/blob/master/airbyte-ci/connectors/pipelines/README.md) (recommended):**
20+
1. Install [`airbyte-ci`](https://github.com/airbytehq/airbyte/blob/master/airbyte-ci/connectors/pipelines/README.md)
21+
2. Run the following command to build the docker image:
2322

2423
```bash
2524
airbyte-ci connectors --name=source-gainsight-px build
2625
```
2726

28-
An image will be built with the tag `airbyte/source-gainsight-px:dev`.
27+
An image will be available on your host with the tag `airbyte/source-gainsight-px:dev`.
2928

30-
**Via `docker build`:**
29+
### Creating credentials
3130

32-
```bash
33-
docker build -t airbyte/source-gainsight-px:dev .
34-
```
31+
**If you are a community contributor**, follow the instructions in the [documentation](https://docs.airbyte.com/integrations/sources/gainsight-px)
32+
to generate the necessary credentials. Then create a file `secrets/config.json` conforming to the `spec` object in the connector's `manifest.yaml` file.
33+
Note that any directory named `secrets` is gitignored across the entire Airbyte repo, so there is no danger of accidentally checking in sensitive information.
3534

36-
#### Run
35+
### Running as a docker container
3736

38-
Then run any of the connector commands as follows:
37+
Then run any of the standard source connector commands:
3938

40-
```
39+
```bash
4140
docker run --rm airbyte/source-gainsight-px:dev spec
4241
docker run --rm -v $(pwd)/secrets:/secrets airbyte/source-gainsight-px:dev check --config /secrets/config.json
4342
docker run --rm -v $(pwd)/secrets:/secrets airbyte/source-gainsight-px:dev discover --config /secrets/config.json
4443
docker run --rm -v $(pwd)/secrets:/secrets -v $(pwd)/integration_tests:/integration_tests airbyte/source-gainsight-px:dev read --config /secrets/config.json --catalog /integration_tests/configured_catalog.json
4544
```
4645

47-
## Testing
46+
### Running the CI test suite
4847

4948
You can run our full test suite locally using [`airbyte-ci`](https://github.com/airbytehq/airbyte/blob/master/airbyte-ci/connectors/pipelines/README.md):
5049

5150
```bash
5251
airbyte-ci connectors --name=source-gainsight-px test
5352
```
5453

55-
### Customizing acceptance Tests
56-
57-
Customize `acceptance-test-config.yml` file to configure tests. See [Connector Acceptance Tests](https://docs.airbyte.com/connector-development/testing-connectors/connector-acceptance-tests-reference) for more information.
58-
If your connector requires to create or destroy resources for use during acceptance tests create fixtures for it and place them inside integration_tests/acceptance.py.
59-
60-
## Dependency Management
61-
62-
All of your dependencies should go in `setup.py`, NOT `requirements.txt`. The requirements file is only used to connect internal Airbyte dependencies in the monorepo for local development.
63-
We split dependencies between two groups, dependencies that are:
64-
65-
- required for your connector to work need to go to `MAIN_REQUIREMENTS` list.
66-
- required for the testing need to go to `TEST_REQUIREMENTS` list
67-
68-
### Publishing a new version of the connector
69-
70-
You've checked out the repo, implemented a million dollar feature, and you're ready to share your changes with the world. Now what?
54+
## Publishing a new version of the connector
7155

72-
1. Make sure your changes are passing our test suite: `airbyte-ci connectors --name=source-gainsight-px test`
73-
2. Bump the connector version in `metadata.yaml`: increment the `dockerImageTag` value. Please follow [semantic versioning for connectors](https://docs.airbyte.com/contributing-to-airbyte/resources/pull-requests-handbook/#semantic-versioning-for-connectors).
74-
3. Make sure the `metadata.yaml` content is up to date.
75-
4. Make the connector documentation and its changelog is up to date (`docs/integrations/sources/gainsight-px.md`).
56+
If you want to contribute changes to `source-gainsight-px`, here's how you can do that:
57+
1. Make your changes locally, or load the connector's manifest into Connector Builder and make changes there.
58+
2. Make sure your changes are passing our test suite with `airbyte-ci connectors --name=source-gainsight-px test`
59+
3. Bump the connector version (please follow [semantic versioning for connectors](https://docs.airbyte.com/contributing-to-airbyte/resources/pull-requests-handbook/#semantic-versioning-for-connectors)):
60+
- bump the `dockerImageTag` value in in `metadata.yaml`
61+
4. Make sure the connector documentation and its changelog is up to date (`docs/integrations/sources/gainsight-px.md`).
7662
5. Create a Pull Request: use [our PR naming conventions](https://docs.airbyte.com/contributing-to-airbyte/resources/pull-requests-handbook/#pull-request-title-convention).
7763
6. Pat yourself on the back for being an awesome contributor.
7864
7. Someone from Airbyte will take a look at your PR and iterate with you to merge it into master.
65+
8. Once your PR is merged, the new version of the connector will be automatically published to Docker Hub and our connector registry.

airbyte-integrations/connectors/source-gainsight-px/__init__.py

-3
This file was deleted.

airbyte-integrations/connectors/source-gainsight-px/acceptance-test-config.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ connector_image: airbyte/source-gainsight-px:dev
44
acceptance_tests:
55
spec:
66
tests:
7-
- spec_path: "source_gainsight_px/spec.yaml"
7+
- spec_path: "manifest.yaml"
88
connection:
99
tests:
1010
- config_path: "secrets/config.json"

airbyte-integrations/connectors/source-gainsight-px/main.py

-8
This file was deleted.

0 commit comments

Comments
 (0)