Rust

resource

Module

What a transfer moves: Resource, its common state and its kinds.

Contents

2 submodules, and what the module defines itself.

use utopia_migration::resource::Base;
Rust
pub struct Base

The state every resource has.

Also implements Default.
use utopia_migration::resource::Chunk;
Rust
pub struct Chunk

A chunk of a file or deployment being transferred.

use utopia_migration::resource::DatabaseResources;
Rust
pub struct DatabaseResources

The resource names of one database family: its entity (table or collection), field (column or attribute) and record (row or document).

use utopia_migration::resource::EntityResources;
Rust
pub struct EntityResources

The resource names scoped to one entity type: field, record and index.

use utopia_migration::Resource;
Rust
pub struct Resource

One resource: its common state and its kind.

use utopia_migration::Kind;
Rust
pub enum Kind

What a resource is: its type and the data of that type.

use utopia_migration::resource::CustomResource;
Rust
pub trait CustomResource: std::fmt::Debug + Send + Sync

Undocumented.

use utopia_migration::resource::database_resources;
Rust
pub fn database_resources(database: &str) -> Option<&'static DatabaseResources>

The map entry of database type database.

use utopia_migration::resource::is_supported;
Rust
pub fn is_supported<T: AsRef<str>, R: AsRef<str>>(types: &[T], resources: &[R]) -> bool

Whether any of types (or its legacy name) is in resources.

Rust
pub type ResourceRef = Arc<Resource>

A shared resource.

Rust
pub const ALL_RESOURCES: &[&str] = &[ types::COLUMN, types::BUCKET, types::TABLE, types::DATABASE, types::DATABASE_VECTORSDB, types::DATABASE_DOCUMENTSDB, types::ROW, types::FILE, types::FUNCTION, types::DEPLOYMENT, types::SITE, types::SITE_DEPLOYMENT, types::SITE_VARIABLE, types::HASH, types::INDEX, types::USER, types::ENVIRONMENT_VARIABLE, types::TEAM, types::MEMBERSHIP, types::AUTH_METHODS, types::POLICIES, types::OAUTH2_PROVIDER, types::PLATFORM, types::API_KEY, types::WEBHOOK, types::SMTP, types::PROJECT_VARIABLE, types::PROJECT_PROTOCOLS, types::PROJECT_LABELS,

Undocumented.

Rust
pub const DATABASE_TYPE_RESOURCE_MAP: &[DatabaseResources] = &[ DatabaseResources

Resource::DATABASE_TYPE_RESOURCE_MAP, in its order.

Rust
pub const ENTITY_TYPE_RESOURCE_MAP: &[EntityResources] = &[ EntityResources

Resource::ENTITY_TYPE_RESOURCE_MAP, in its order.

resource::status

Own page
Rust
pub const DISREGARDED: &str = "disregarded"

Kept for the transfer's own use, not transferred.

Rust
pub const ERROR: &str = "error"

Failed.

Rust
pub const PENDING: &str = "pending"

Not processed yet.

Rust
pub const PROCESSING: &str = "processing"

Being imported.

Rust
pub const SKIPPED: &str = "skip"

Not transferred (not requested, or already on the destination).

Rust
pub const SUCCESS: &str = "success"

Transferred.

Rust
pub const WARNING: &str = "warning"

Transferred with a warning.

resource::types

Own page
Rust
pub const API_KEY: &str = "api-key"

An API key.

Rust
pub const ATTRIBUTE: &str = "attribute"

An attribute (legacy name of a column).

Rust
pub const AUTH_METHODS: &str = "auth-methods"

The project's auth methods.

Rust
pub const BACKUP_POLICY: &str = "backup-policy"

A backup policy.

Rust
pub const BUCKET: &str = "bucket"

A storage bucket.

Rust
pub const COLLECTION: &str = "collection"

A collection (legacy name of a table).

Rust
pub const COLUMN: &str = "column"

A column.

Rust
pub const DATABASE: &str = "database"

A database.

Rust
pub const DATABASE_DOCUMENTSDB: &str = "documentsdb"

A DocumentsDB database.

Rust
pub const DATABASE_LEGACY: &str = "legacy"

A legacy database (type of a database document).

Rust
pub const DATABASE_TABLESDB: &str = "tablesdb"

A TablesDB database (type of a database document).

Rust
pub const DATABASE_VECTORSDB: &str = "vectorsdb"

A VectorsDB database.

Rust
pub const DEPLOYMENT: &str = "deployment"

A function deployment.

Rust
pub const DOCUMENT: &str = "document"

A document (legacy name of a row).

Rust
pub const ENVIRONMENT_VARIABLE: &str = "environment-variable"

A function variable.

Rust
pub const FILE: &str = "file"

A file.

Rust
pub const FUNCTION: &str = "function"

A function.

Rust
pub const HASH: &str = "hash"

A password hash.

Rust
pub const INDEX: &str = "index"

An index.

Rust
pub const MEMBERSHIP: &str = "membership"

A team membership.

Rust
pub const MESSAGE: &str = "message"

A message.

Rust
pub const OAUTH2_PROVIDER: &str = "oauth2-provider"

An OAuth2 provider (one type for every provider).

Rust
pub const PLATFORM: &str = "platform"

A platform.

Rust
pub const POLICIES: &str = "policies"

The project's auth policies.

Rust
pub const PROJECT_EMAIL_TEMPLATE: &str = "project-email-template"

A project email template.

Rust
pub const PROJECT_LABELS: &str = "project-labels"

The project's labels.

Rust
pub const PROJECT_PROTOCOLS: &str = "project-protocols"

The project's protocols.

Rust
pub const PROJECT_SERVICES: &str = "project-services"

The project's services.

Rust
pub const PROJECT_VARIABLE: &str = "project-variable"

A project variable.

Rust
pub const PROVIDER: &str = "provider"

A messaging provider.

Rust
pub const ROW: &str = "row"

A row.

Rust
pub const RULE: &str = "rule"

A domain rule.

Rust
pub const SITE: &str = "site"

A site.

Rust
pub const SITE_DEPLOYMENT: &str = "site-deployment"

A site deployment.

Rust
pub const SITE_VARIABLE: &str = "site-variable"

A site variable.

Rust
pub const SMTP: &str = "smtp"

The project's SMTP settings.

Rust
pub const SUBSCRIBER: &str = "subscriber"

A topic subscriber.

Rust
pub const TABLE: &str = "table"

A table.

Rust
pub const TEAM: &str = "team"

A team.

Rust
pub const TOPIC: &str = "topic"

A messaging topic.

Rust
pub const USER: &str = "user"

A user.

Rust
pub const WEBHOOK: &str = "webhook"

A webhook.