Skip to content

Commit

Permalink
add very sparse resource_system doc
Browse files Browse the repository at this point in the history
  • Loading branch information
TomasEkeli committed Jun 26, 2023
1 parent 0a6e74a commit d61a58c
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 3 deletions.
11 changes: 11 additions & 0 deletions Source/content/en/docs/concepts/resource_system.md
@@ -0,0 +1,11 @@
---
title: Resource System
description: How to get access to storage
weight: 90
---

When using the [Dolittle SDK](https://github.com/dolittle/dotnet.sdk) you get access to the Resource System which is a way to get access to storage. The Resources you get will be separated by [Tenants]({{<ref tenants>}}) and unique in your current context. This means that you can depend on the stored data not leaking between tenants.

## Read Cache

The Read Cache is available from the Resource System as an `IMongoDatabase` that you can reference in your code. The database will be connected, and you can use normal MongoDB queries to get access to the data you store there.
4 changes: 2 additions & 2 deletions Source/content/en/docs/platform/studio/microservice.md
Expand Up @@ -9,7 +9,7 @@ A Microservice is a single unit of deployment in the Aigonix Platform. It is a c

A Microservice lives inside an [Application]({{<ref application>}}) and can be deployed to multiple [Environments]({{<ref environment>}}) in that application.

A Microservice in the Aigonix Platform is a Head and optionally a Runtime and data-storage. If you use the Dolittle Runtime you will have access to the [Event Store]({{<ref event_store>}}) and [Read Cache]({{<ref read_cache>}}) for that Microservice.
A Microservice in the Aigonix Platform is a Head and optionally a Runtime and data-storage. If you use the Dolittle Runtime you will have access to the [Event Store]({{<ref event_store>}}) and [Read Cache]({{<ref "resource_system#read_cache">}}) for that Microservice.

If you do not use the Dolittle Runtime the Microservice will be stateless and will not have access to any storage. Any state you need to store will have to be stored in an external service. You will have access to the local file-system, but that is not persisted between Microservice restarts, and we do not recommend relying upon it.

Expand All @@ -23,7 +23,7 @@ Head is the name of the pod where your Microservice Docker image is deployed. It

## Dolittle Runtime

Each Microservice can be deployed with the [Dolittle Runtime]({{<ref runtime>}}). The Dolittle Runtime is available as a docker image, and will be deployed alongside your Head. Your code communicates with the Runtime through the [Dolittle SDK]({{<ref sdk>}}). The Runtime is used to connect to the [Event Store]({{<ref event_store>}}) and will make the resource-system available to you, where you can get the Tenanted [Read Cache]({{<ref read_cache>}}) and to publish events to the [Event Horizon]({{<ref event_horizon>}}).
Each Microservice can be deployed with the [Dolittle Runtime](https://github.com/dolittle/runtime). The Dolittle Runtime is available as a docker image, and will be deployed alongside your Head. Your code communicates with the Runtime through the [Dolittle SDK](https://github.com/dolittle/dotnet.sdk). The Runtime is used to connect to the [Event Store]({{<ref event_store>}}) and will make the resource-system available to you, where you can get the Tenanted [Read Cache]({{<ref "resource_system#read_cache">}}) and to publish events to the [Event Horizon]({{<ref event_horizon>}}).

## Configuration

Expand Down
2 changes: 1 addition & 1 deletion Source/content/en/docs/platform/studio/overview.md
Expand Up @@ -21,7 +21,7 @@ When you run your [Microservices]({{<ref microservice>}}) in the Aigonix Platfor

You will define each [Application]({{<ref application>}}) with its [Environments]({{<ref environment>}}), and add Microservices to them. You define which Docker image to use for each Microservice, and whether or not you want to use the Dolittle Runtime. You can use a publically available image, or store your container image in the provided [container-registry]({{<ref container_registry>}}).

If you use the Dolittle Runtime one will be made available to your [Head]({{<ref "microservice#head">}}) and through it you will have access to [Tenanted resources]({{<ref tenants>}}) like the [Event Store]({{<ref event_store>}}) and [Read Cache]({{<ref read_cache>}}). If you do not use the [Dolittle Runtime]({{<ref runtime>}}) the service will run the assigned Docker-image without permanent storage (stateless).
If you use the Dolittle Runtime one will be made available to your [Head]({{<ref "microservice#head">}}) and through it you will have access to [Tenanted resources]({{<ref tenants>}}) like the [Event Store]({{<ref event_store>}}) and [Read Cache]({{<ref "resource_system#read_cache" >}}). If you do not use the [Dolittle Runtime](https://github.com/dolittle/runtime) the service will run the assigned Docker-image without permanent storage (stateless).

You can make your services available to the internet if you so wish. If you do not they will only be available within the platform.

Expand Down

0 comments on commit d61a58c

Please sign in to comment.