Comments (5)
Hey @olitomlinson
Yeah we've been running with all properties excluded from indexing for a while. That was driven more from a performance aspect in our case but happily helped with costing too. So we're running no indexing and compressed data at the moment and seeing huge ROI for that. Obviously the compression really only works when you're interacting with the state store in a key-value kind of way but that is how Dapr works through the state management API so it's relevant.
Truth be told, they've made our product viable in the longer term.
I'll try get a PR out for this soon 👍🏻
from docs.
@KrylixZA IMO this is good content to add!
Also, did you attempt to disable indexing on the container, as it's my understanding that this can be a huge RU saver for writes?
from docs.
Going back to your original point about compressing the state, I assume you're doing all this in your application layer?
To me it seems reasonable there should be an option to compression / decompression the state transparently by the cosmosDb state store component, so that end-users such as yourself don't have to take on this responsibility. What do you think?
from docs.
Is there something inherent to actors that cause extra queries to be done here? I am thinking, if you were to build the same "workflow" without the actors and query the state you need from a database each time your long running transaction needs to continue, would that be cheaper than using actors?
I guess what I'm getting at here is, does the actor framework abuse cosmos or is this just by nature of what you are asking it to do? If the latter, I don't really see how a warning is relevant.
from docs.
Hey @joshuadmatthews
From my experience, the actor framework is extremely efficient at managing state interactions.
Given it only reads from state when the actor is hydrated, you're saving a read every time the actor is called and it's sitting alive in memory.
The only thing about actor state is that it's raw, formatted JSON. By nature, raw JSON uses up a lot of KBs, and therefore RU/s in CosmosDB. This is because of all the white space and line endings to make it formatted.
Building the same code without the actor pattern would be very hard to get right. Specifically working around the race conditions reading and writing state. Actors are good at that, by nature of their implementation. You'd likely build it worse if you had to do it yourself. Or at least I would ;)
Alls I am suggesting, instead of a warning, is just a little note block that informs the user that if they are using actors and have no intention to query the state through bindings or the SDK directly, then dapr is only going to use the state in a key-value fashion. And by virtue of that, users stand to gain a lot in terms of financial benefits if they store their actor state in a compressed format.
from docs.
Related Issues (20)
- Outbox pattern can format the message structure that is sent
- Correct link for known limitations in workflows page HOT 3
- [Pubsub RabbitMQ] Single Active consumer subscription parameter HOT 1
- GCP PubSub Component: Support Configurable MaxOutstanding* & MaxConcurrentConnection Settings HOT 2
- Add Prometheus Service Discovery Example for Dapr Metrics HOT 1
- Two types of tutorials, should be unified
- Update diagram deck for 1.14
- v1.14 docs release endgame
- Scheduler Service Production Usage Guidelines HOT 1
- Update docs for the 1.13.5 release
- [Cryptography] Add Python examples to docs
- Resiliency: Action based on response HTTP status code for retry
- Component resiliency example is using app resiliency example HOT 1
- --image flag not present HOT 3
- Add Python examples in How to: Use the cryptography APIs HOT 4
- Links not rendered HOT 1
- Actors. Describe the Actor StateManager class.
- I am trying to configure resilience policy for pubsub component using Javascript sdk. But no document or demo code available. HOT 11
- Clarify the documentation on how/when trace context will be available in workflow activity for trace propagation to external services HOT 1
- Add description how to propagate tracing information for rawPayload messages
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from docs.