Skip to content

Commit 2017075

Browse files
committed
source-shopify-native: support multiple Shopify stores
Adds multi-store support allowing a single capture to replicate data from multiple Shopify stores. Each store uses Access Token authentication. Key changes: - StoreConfig model with per-store credentials (Access Token only) - Legacy single-store configs auto-migrated to multi-store format - Collection keys use ["/_meta/store", "/id"] for cross-store uniqueness - Dict-based state format keyed by store ID - Per-store HTTP sessions with independent rate limiting - Parallel store initialization via asyncio.gather - OAuth temporarily removed; will revisit when Flow/UI supports per-store OAuth Closes: #3508
1 parent d3f084c commit 2017075

35 files changed

Lines changed: 2143 additions & 646 deletions
Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,39 @@
1-
---
21
$defs:
32
Meta:
43
properties:
54
op:
65
default: u
7-
description: "Operation type (c: Create, u: Update, d: Delete)"
6+
description: 'Operation type (c: Create, u: Update, d: Delete)'
87
enum:
9-
- c
10-
- u
11-
- d
8+
- c
9+
- u
10+
- d
1211
title: Op
1312
type: string
1413
row_id:
1514
default: -1
16-
description: "Row ID of the Document, counting up from zero, or -1 if not known"
15+
description: Row ID of the Document, counting up from zero, or -1 if not known
1716
title: Row Id
1817
type: integer
18+
store:
19+
anyOf:
20+
- type: string
21+
- type: 'null'
22+
default: null
23+
description: The Shopify store this document belongs to
24+
title: Store
1925
title: Meta
2026
type: object
2127
additionalProperties: true
2228
properties:
2329
_meta:
24-
$ref: "#/$defs/Meta"
25-
default:
26-
op: u
27-
row_id: -1
30+
$ref: '#/$defs/Meta'
2831
description: Document metadata
2932
id:
3033
title: Id
3134
type: string
3235
required:
33-
- id
36+
- id
3437
title: ShopifyGraphQLResource
3538
type: object
3639
x-infer-schema: true
Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,39 @@
1-
---
21
$defs:
32
Meta:
43
properties:
54
op:
65
default: u
7-
description: "Operation type (c: Create, u: Update, d: Delete)"
6+
description: 'Operation type (c: Create, u: Update, d: Delete)'
87
enum:
9-
- c
10-
- u
11-
- d
8+
- c
9+
- u
10+
- d
1211
title: Op
1312
type: string
1413
row_id:
1514
default: -1
16-
description: "Row ID of the Document, counting up from zero, or -1 if not known"
15+
description: Row ID of the Document, counting up from zero, or -1 if not known
1716
title: Row Id
1817
type: integer
18+
store:
19+
anyOf:
20+
- type: string
21+
- type: 'null'
22+
default: null
23+
description: The Shopify store this document belongs to
24+
title: Store
1925
title: Meta
2026
type: object
2127
additionalProperties: true
2228
properties:
2329
_meta:
24-
$ref: "#/$defs/Meta"
25-
default:
26-
op: u
27-
row_id: -1
30+
$ref: '#/$defs/Meta'
2831
description: Document metadata
2932
id:
3033
title: Id
3134
type: string
3235
required:
33-
- id
36+
- id
3437
title: ShopifyGraphQLResource
3538
type: object
3639
x-infer-schema: true
Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,39 @@
1-
---
21
$defs:
32
Meta:
43
properties:
54
op:
65
default: u
7-
description: "Operation type (c: Create, u: Update, d: Delete)"
6+
description: 'Operation type (c: Create, u: Update, d: Delete)'
87
enum:
9-
- c
10-
- u
11-
- d
8+
- c
9+
- u
10+
- d
1211
title: Op
1312
type: string
1413
row_id:
1514
default: -1
16-
description: "Row ID of the Document, counting up from zero, or -1 if not known"
15+
description: Row ID of the Document, counting up from zero, or -1 if not known
1716
title: Row Id
1817
type: integer
18+
store:
19+
anyOf:
20+
- type: string
21+
- type: 'null'
22+
default: null
23+
description: The Shopify store this document belongs to
24+
title: Store
1925
title: Meta
2026
type: object
2127
additionalProperties: true
2228
properties:
2329
_meta:
24-
$ref: "#/$defs/Meta"
25-
default:
26-
op: u
27-
row_id: -1
30+
$ref: '#/$defs/Meta'
2831
description: Document metadata
2932
id:
3033
title: Id
3134
type: string
3235
required:
33-
- id
36+
- id
3437
title: ShopifyGraphQLResource
3538
type: object
3639
x-infer-schema: true
Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,39 @@
1-
---
21
$defs:
32
Meta:
43
properties:
54
op:
65
default: u
7-
description: "Operation type (c: Create, u: Update, d: Delete)"
6+
description: 'Operation type (c: Create, u: Update, d: Delete)'
87
enum:
9-
- c
10-
- u
11-
- d
8+
- c
9+
- u
10+
- d
1211
title: Op
1312
type: string
1413
row_id:
1514
default: -1
16-
description: "Row ID of the Document, counting up from zero, or -1 if not known"
15+
description: Row ID of the Document, counting up from zero, or -1 if not known
1716
title: Row Id
1817
type: integer
18+
store:
19+
anyOf:
20+
- type: string
21+
- type: 'null'
22+
default: null
23+
description: The Shopify store this document belongs to
24+
title: Store
1925
title: Meta
2026
type: object
2127
additionalProperties: true
2228
properties:
2329
_meta:
24-
$ref: "#/$defs/Meta"
25-
default:
26-
op: u
27-
row_id: -1
30+
$ref: '#/$defs/Meta'
2831
description: Document metadata
2932
id:
3033
title: Id
3134
type: string
3235
required:
33-
- id
36+
- id
3437
title: ShopifyGraphQLResource
3538
type: object
3639
x-infer-schema: true
Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,39 @@
1-
---
21
$defs:
32
Meta:
43
properties:
54
op:
65
default: u
7-
description: "Operation type (c: Create, u: Update, d: Delete)"
6+
description: 'Operation type (c: Create, u: Update, d: Delete)'
87
enum:
9-
- c
10-
- u
11-
- d
8+
- c
9+
- u
10+
- d
1211
title: Op
1312
type: string
1413
row_id:
1514
default: -1
16-
description: "Row ID of the Document, counting up from zero, or -1 if not known"
15+
description: Row ID of the Document, counting up from zero, or -1 if not known
1716
title: Row Id
1817
type: integer
18+
store:
19+
anyOf:
20+
- type: string
21+
- type: 'null'
22+
default: null
23+
description: The Shopify store this document belongs to
24+
title: Store
1925
title: Meta
2026
type: object
2127
additionalProperties: true
2228
properties:
2329
_meta:
24-
$ref: "#/$defs/Meta"
25-
default:
26-
op: u
27-
row_id: -1
30+
$ref: '#/$defs/Meta'
2831
description: Document metadata
2932
id:
3033
title: Id
3134
type: string
3235
required:
33-
- id
36+
- id
3437
title: ShopifyGraphQLResource
3538
type: object
3639
x-infer-schema: true

0 commit comments

Comments
 (0)