# generated by datamodel-codegen:
#   filename:  metadataIngestion/dashboardServiceMetadataPipeline.json
#   timestamp: 2022-10-03T15:16:21+00:00

from __future__ import annotations

from enum import Enum
from typing import List, Optional

from pydantic import BaseModel, Extra, Field

from ..type import filterPattern


class DashboardMetadataConfigType(Enum):
    DashboardMetadata = 'DashboardMetadata'


class DashboardServiceMetadataPipeline(BaseModel):
    class Config:
        extra = Extra.forbid

    type: Optional[DashboardMetadataConfigType] = Field(
        DashboardMetadataConfigType.DashboardMetadata, description='Pipeline type'
    )
    dashboardFilterPattern: Optional[filterPattern.FilterPattern] = Field(
        None,
        description='Regex to only fetch tables or databases that matches the pattern.',
    )
    chartFilterPattern: Optional[filterPattern.FilterPattern] = Field(
        None, description='Regex exclude tables or databases that matches the pattern.'
    )
    dbServiceNames: Optional[List] = Field(
        None,
        description='List of Database Service Name for creation of lineage',
        title='Database Service Name List',
    )
