Commit Graph

115 Commits

Author SHA1 Message Date
luigirende 120a649caa
CosmosDBState - Add, as option, the partitionKey in QueryMethod (#3227)
Signed-off-by: luigirende <luigirende@gmail.com>
Signed-off-by: Luigi Rende <luigirende@gmail.com>
Signed-off-by: Bernd Verst <github@bernd.dev>
Co-authored-by: Bernd Verst <github@bernd.dev>
2024-01-24 16:49:33 -08:00
luigirende a7c64f4e8d
Add new filters type in the query of the state component (#3218)
Signed-off-by: Luigi Rende <luigirende@gmail.com>
Co-authored-by: Bernd Verst <github@bernd.dev>
2023-12-06 20:51:27 +00:00
Bernd Verst 9095b0e7e7
Switch to Go 1.21, Updates linter, updates workflows, adds sarama 1.42.1 (#3251)
Signed-off-by: Bernd Verst <github@bernd.dev>
2023-11-28 18:13:09 -08:00
Alessandro (Ale) Segala 934e86c4f7
Rename folder "internal" to "common" (#3225)
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
2023-11-14 11:36:38 -08:00
Alessandro (Ale) Segala f4e73b0e65
Update dapr/kit (#3205)
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
Signed-off-by: Bernd Verst <github@bernd.dev>
Co-authored-by: Bernd Verst <github@bernd.dev>
2023-11-02 16:20:56 -07:00
Alessandro (Ale) Segala b10ce96b49
State stores: expose TTL as a feature (#2987)
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
2023-08-04 09:38:22 -07:00
Alessandro (Ale) Segala 9ca07d9bca
Added `MultiMaxSize` to Cosmos DB state store (#3015)
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
2023-07-25 13:06:15 -07:00
Alessandro (Ale) Segala ec05809ee6
[Metadata] Update validator and some other fixes (#2984)
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
Co-authored-by: Bernd Verst <github@bernd.dev>
2023-07-17 22:17:22 +00:00
Josh van Leeuwen fa90710794
cosmosdb: return ttlExpiryTime in GetResponse (#2898)
Signed-off-by: joshvanl <me@joshvanl.dev>
2023-06-08 15:34:25 +00:00
Alessandro (Ale) Segala 1f27fd0e8b
Add conformance tests for etags in Bulk operations (#2843)
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
Signed-off-by: Artur Souza <artursouza.ms@outlook.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2023-05-17 16:28:29 -07:00
Alessandro (Ale) Segala e30d140479
Remove native/transactional BulkSet/BulkDelete from state stores (#2834)
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
2023-05-17 14:56:34 -07:00
Alessandro (Ale) Segala 5dad8a867c
Metadata parser: add support for built-in authentication profiles and metadata properties (#2760)
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
Co-authored-by: Bernd Verst <github@bernd.dev>
2023-04-12 00:04:34 +00:00
Alessandro (Ale) Segala 4f94da95cf
Refactor state store bulk operations (#2747)
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
2023-04-07 19:19:47 +00:00
Bernd Verst cfbac4d794
Refactor of Metadata parsing in Bindings (#2720)
Signed-off-by: Bernd Verst <github@bernd.dev>
Signed-off-by: Shivam Kumar <shivamkm07@gmail.com>
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
Signed-off-by: Roberto J Rojas <robertojrojas@gmail.com>
Signed-off-by: Alessandro (Ale) Segala <43508+ItalyPaleAle@users.noreply.github.com>
Signed-off-by: Roberto Rojas <robertojrojas@gmail.com>
Signed-off-by: spike <hello@spike.wiki>
Signed-off-by: zhangchao <zchao9100@gmail.com>
Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>
Signed-off-by: Deepanshu Agarwal <deepanshu.agarwal1984@gmail.com>
Signed-off-by: handlerww <handlerww@gmail.com>
Co-authored-by: Shivam Kumar <shivamkm07@gmail.com>
Co-authored-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
Co-authored-by: Roberto Rojas <robertojrojas@gmail.com>
Co-authored-by: spike <39330606+SpikeWong@users.noreply.github.com>
Co-authored-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>
Co-authored-by: Taction <zchao9100@gmail.com>
Co-authored-by: Deepanshu Agarwal <deepanshu.agarwal1984@gmail.com>
Co-authored-by: Yiwen Chen <handlerww@gmail.com>
2023-04-05 22:19:08 +00:00
Bernd Verst e5cbb34990
Add metadata analyzer tools (#2696)
Signed-off-by: Bernd Verst <github@bernd.dev>
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
Co-authored-by: Alessandro (Ale) Segala <43508+ItalyPaleAle@users.noreply.github.com>
2023-03-24 18:34:36 +00:00
Bernd Verst 3a616c5678 Remove Track 1 SDK references
Signed-off-by: Bernd Verst <github@bernd.dev>
2023-02-27 12:44:32 -08:00
Bernd Verst 4068531538
Merge branch 'master' into metadata 2023-02-22 16:46:43 -08:00
Josh van Leeuwen d098e38d6a
Propagate context from caller to appropriate places in the code (#2474)
* Propagates contexts to callers where appropriate.

Signed-off-by: joshvanl <me@joshvanl.dev>

* Updates units tests with new func signature

Signed-off-by: joshvanl <me@joshvanl.dev>

* Fix linting errors

Signed-off-by: joshvanl <me@joshvanl.dev>

* Add atomic gate to alicloud rocketmq close channel.

Signed-off-by: joshvanl <me@joshvanl.dev>

* bindings/aws/kinesis use a separate ctx variable name

Signed-off-by: joshvanl <me@joshvanl.dev>

* binding/kafka: use atomic to prevent closing the channel twice

Signed-off-by: joshvanl <me@joshvanl.dev>

* bindings/mqtt3: use atomic bool to prevent close channel being closed multiple times

Signed-off-by: joshvanl <me@joshvanl.dev>

* bindings/mqtt3: use Background context for handle operations:w

Signed-off-by: joshvanl <me@joshvanl.dev>

* state/cocroachdb: add context to Ping()

Signed-off-by: joshvanl <me@joshvanl.dev>

* bindings/postgres: add comment explaining use of context.

Signed-off-by: joshvanl <me@joshvanl.dev>

* Adds comment header to health/pinger.go

Signed-off-by: joshvanl <me@joshvanl.dev>

* pubsub/aws/snssqs: add waitgroup to wait for all go routines to finish
and block on Close(). Shuts down the subscription if there are no topic
handlers.

Signed-off-by: joshvanl <me@joshvanl.dev>

* pubsub/mqtt3: add atomic bool to prevent multiple channel closes. Add
wait group to block close on all goroutines to finish.

Signed-off-by: joshvanl <me@joshvanl.dev>

* pubsub/rabbitmq: fixes race conditions, uses atomic to prevent multiple
closes, add wait group to block close on all goroutines

Signed-off-by: joshvanl <me@joshvanl.dev>

* pubsub/redis: revert ctx passed when it could be cancelled. Add wait
group wait when closing.

Signed-off-by: joshvanl <me@joshvanl.dev>

* state/postges: pass context in init, and wait group on close.

Signed-off-by: joshvanl <me@joshvanl.dev>

* Update all `Ping()` to `PingContext()` where possible.

Signed-off-by: joshvanl <me@joshvanl.dev>

* state/in-memory: add atomic bool to prevent closing channel multiple
times. Add wait group to block on close()

Signed-off-by: joshvanl <me@joshvanl.dev>

* state/mysql: don't use same ctx variable name

Signed-off-by: joshvanl <me@joshvanl.dev>

* Pass correct loop context to redis go routines

Signed-off-by: joshvanl <me@joshvanl.dev>

* Rename context when creating timeouts in state

Signed-off-by: joshvanl <me@joshvanl.dev>

* Remove state.Features() from requiring a context

Signed-off-by: joshvanl <me@joshvanl.dev>

* Revert wasm request handle Close func to be without context to
implement io.Closer interface. Add 5 second timeout. Add io.Closer
assertion in test.

Signed-off-by: joshvanl <me@joshvanl.dev>

* Remove superfluous go lint vet directive

Signed-off-by: joshvanl <me@joshvanl.dev>

* Change Configuration Init function to take context

Signed-off-by: joshvanl <me@joshvanl.dev>

* Updates input binding interface to include a `Close() error` function. `Close`
blocks until all resources have been released and go routines have returned.

Signed-off-by: joshvanl <me@joshvanl.dev>

* Change `Close() error` in input binding struct to `io.Closer` interface.

Signed-off-by: joshvanl <me@joshvanl.dev>

* Update go.mod files to point to dapr/dapr PR https://github.com/dapr/dapr/pull/5831

Signed-off-by: joshvanl <me@joshvanl.dev>

* pubsub/redis: watch closeCh to shutdown worker instead of init context.

Signed-off-by: joshvanl <me@joshvanl.dev>

* pubsub/aws/snssqs + bindings/kubemq: ensure closeCh is caught so Close
correctly returns

Signed-off-by: joshvanl <me@joshvanl.dev>

* Close kubemq binding client on close. Ensure kafka consumer channel
cannot be closed more than once.

Signed-off-by: joshvanl <me@joshvanl.dev>

* Tweaks

Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>

* Fixed cert tests

Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>

* binding/mqtt3: add inline Background context instead of passing to
handleMessage

Signed-off-by: joshvanl <me@joshvanl.dev>

* pubsub/mqtt3: remove context from createSubscriberClientOptions

Signed-off-by: joshvanl <me@joshvanl.dev>

* pubsub/mqtt3: Remove `ResetConnection` func

Signed-off-by: joshvanl <me@joshvanl.dev>

* pubsub/kafka: Don't resubscribe if Subscribe is cancelled.

Signed-off-by: joshvanl <me@joshvanl.dev>

* binding/mqtt3: don't use context to control establishing connection

Signed-off-by: joshvanl <me@joshvanl.dev>

* bindings/mqtt3: Fix linting errors

Signed-off-by: joshvanl <me@joshvanl.dev>

---------

Signed-off-by: joshvanl <me@joshvanl.dev>
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
Co-authored-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
Co-authored-by: Yaron Schneider <schneider.yaron@live.com>
2023-02-16 14:18:35 -08:00
Bernd Verst b1c1304a86 Add and update component metadata definition files
Signed-off-by: Bernd Verst <github@bernd.dev>
2023-02-13 17:09:09 -08:00
ItalyPaleAle b1cc54f62c Merge branch 'master' of https://github.com/dapr/components-contrib into postgres-ttl
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
2022-12-13 21:16:57 +00:00
ItalyPaleAle a1c863d7fd Small fixes
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
2022-12-13 10:11:36 -08:00
1046102779 2dd7433a59 feature: add context to state API
Signed-off-by: 1046102779 <seachen@tencent.com>
2022-12-08 15:56:51 +08:00
Bernd Verst efa96b26ed
Merge branch 'master' into postgres-ttl 2022-11-28 17:57:53 -08:00
Ryan Lettieri c736bcc506 Hotfix for StateTransactionRequest with etag crash
Signed-off-by: Ryan Lettieri <ryanLettieri@microsoft.com>
2022-11-28 15:27:14 -08:00
ItalyPaleAle c54286a60d Added TTL support for postgres
TODO: garbage collection
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
2022-11-22 00:24:04 +00:00
ItalyPaleAle a6eb406fc2 Extracted common ParseTTL method
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
2022-11-21 23:43:28 +00:00
Bernd Verst 2698482f34 Add user agent back to Cosmos DB state store
Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>
2022-11-15 14:55:20 -08:00
Bernd Verst ede060959a
Refactors all state store to standardize metadata parsing (#2257) 2022-11-05 15:36:44 -07:00
1046102779 203c6c7757 feature: add context to state API
Signed-off-by: 1046102779 <seachen@tencent.com>
2022-10-25 07:21:35 +08:00
1046102779 8bc4286cdf feature: add context to state API
Signed-off-by: 1046102779 <seachen@tencent.com>
2022-10-24 11:04:48 +08:00
1046102779 1ed4c39d8c feature: add context to state API
Signed-off-by: 1046102779 <seachen@tencent.com>
2022-10-24 10:16:21 +08:00
1046102779 5a367b401a feature: add context to state API
Signed-off-by: 1046102779 <seachen@tencent.com>
2022-10-21 17:25:14 +08:00
Alessandro (Ale) Segala f15a50581d
Component metadata schema and tools (#2077)
* Component metadata schema and tools

Includes tools to generate and validate components' schema, and a CI check to ensure the schema is always up-to-date.

Also, includes schemas for 4 components as a starter

Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>

* Changed version as requested

Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>

* fix workflow

Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>

Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>
Co-authored-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>
2022-09-27 10:44:54 -07:00
Bernd Verst ea219576df
Apply suggestions from code review
Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>
2022-09-23 13:42:45 -07:00
Ryan Lettieri 02645149b5 Changing greater than symbol to greater than or equals logic in cosmos statestore
Signed-off-by: Ryan Lettieri <ryanLettieri@microsoft.com>
2022-09-23 14:27:06 -06:00
Ryan Lettieri 93708273d4 Removing page size option from cosmos statestore
Signed-off-by: Ryan Lettieri <ryanLettieri@microsoft.com>
2022-09-23 14:15:41 -06:00
Ryan Lettieri 0b8d937ccd Fixing page limit on cosmosdb
Signed-off-by: Ryan Lettieri <ryanLettieri@microsoft.com>
2022-09-23 14:04:15 -06:00
Ryan Lettieri aa0228becd Cleaning up transactional code in cosmosdb statestore
Signed-off-by: Ryan Lettieri <ryanLettieri@microsoft.com>
2022-09-16 15:04:30 -06:00
ItalyPaleAle 3c2e82a0e7 💄
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
2022-09-16 20:49:14 +00:00
ItalyPaleAle cec34b9a95 💄
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
2022-09-16 20:44:40 +00:00
ItalyPaleAle 0ed1a8acf0 Misc fixes
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
2022-09-16 20:32:02 +00:00
ItalyPaleAle fd881e20f7 Use dapr/kit/ptr instead of old ptr
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
2022-09-16 19:41:48 +00:00
Ryan Lettieri 79c039c08d Using helper method to grab partition key or default to empty string
Signed-off-by: Ryan Lettieri <ryanLettieri@microsoft.com>
2022-09-16 12:44:06 -06:00
Ryan Lettieri 097737f6cd Adding timeout to transactional batch in comsosdb statestore
Signed-off-by: Ryan Lettieri <ryanLettieri@microsoft.com>
2022-09-15 16:58:09 -06:00
Ryan Lettieri 705070036d Fixing conformance test for cosmosDB for track2sdk
Signed-off-by: Ryan Lettieri <ryanLettieri@microsoft.com>
2022-09-15 14:58:58 -06:00
Ryan Lettieri 5d112f4d33 Fixing linter issues
Signed-off-by: Ryan Lettieri <ryanLettieri@microsoft.com>
2022-09-14 15:58:57 -06:00
Ryan Lettieri 8a9b4b4986 Updated cosmos query to be compliant with new format/structure
Signed-off-by: Ryan Lettieri <ryanLettieri@microsoft.com>
2022-09-14 15:50:58 -06:00
Ryan Lettieri 8425950aac Temporary revert of cosmosdb item marshalling
Signed-off-by: Ryan Lettieri <ryanLettieri@microsoft.com>
2022-09-13 11:19:22 -06:00
Ryan Lettieri 97a91c0b8f Changing cosmos header checks to lower case
Signed-off-by: Ryan Lettieri <ryanLettieri@microsoft.com>
2022-09-09 14:08:45 -06:00
Ryan Lettieri 34c24ba994 Adding capability for cross partition query in cosmos with track2SDK
Signed-off-by: Ryan Lettieri <ryanLettieri@microsoft.com>
2022-09-09 13:52:49 -06:00