import { FleioId, IBaseFleioObjectModel } from '../../base-model/base-fleio-object.model';
import { IClientModel } from '@fleio-api/client-user/model/client.model';
import { IProjectModel } from '@fleio-api/openstack/project/model/project.model';
import { IFlavorModel } from '@fleio-api/openstack/model/flavor.model';

export interface IDbaasInstanceModel extends IBaseFleioObjectModel {
  project: IProjectModel;
  region: string;
  status: string;
  operating_status: string;
  name: string;
  flavor: IFlavorModel;
  volume: Record<string, any>;
  volume_id?: FleioId;
  locality: string;
  access: Record<string, any>;
  addresses: Array<Record<string, any>>;
  created: Date;
  updated: Date;
  service_status_updated: Date;
  datastore: Record<string, string>;
  availability_zone: string;
  client?: IClientModel;
  server_id?: FleioId;
  fault?: Record<string, string>;
  replicas?: Array<{
    name: string;
    id: string;
  }>;
  replica_of?: {
    name: string;
    id: string;
  };
}
