getStatusLabel() — supabase Function Reference
Architecture documentation for the getStatusLabel() function in ReadReplicas.utils.ts from the supabase codebase.
Entity Profile
Dependency Diagram
graph TD f7db62c8_5925_c885_746c_cdc119199d8a["getStatusLabel()"] 51db4f53_58c2_7ad8_2211_ae5a7c3efd62["ReadReplicaRow()"] 51db4f53_58c2_7ad8_2211_ae5a7c3efd62 -->|calls| f7db62c8_5925_c885_746c_cdc119199d8a 0f6abc54_8616_41fd_dc72_99508a757f69["ReadReplicaNode()"] 0f6abc54_8616_41fd_dc72_99508a757f69 -->|calls| f7db62c8_5925_c885_746c_cdc119199d8a style f7db62c8_5925_c885_746c_cdc119199d8a fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
apps/studio/components/interfaces/Database/Replication/ReadReplicas/ReadReplicas.utils.ts lines 26–63
export const getStatusLabel = ({
initStatus,
status,
}: {
initStatus?: string
status?: string
}) => {
if (
initStatus === ReplicaInitializationStatus.InProgress ||
status === REPLICA_STATUS.COMING_UP ||
status === REPLICA_STATUS.UNKNOWN ||
status === REPLICA_STATUS.INIT_READ_REPLICA
) {
return 'Coming up'
}
if (
initStatus === ReplicaInitializationStatus.Failed ||
status === REPLICA_STATUS.INIT_READ_REPLICA_FAILED
) {
return 'Failed'
}
switch (status) {
case REPLICA_STATUS.GOING_DOWN:
return 'Going down'
case REPLICA_STATUS.RESTARTING:
return 'Restarting'
case REPLICA_STATUS.RESIZING:
return 'Resizing'
case REPLICA_STATUS.RESTORING:
return 'Restoring'
case REPLICA_STATUS.ACTIVE_HEALTHY:
return 'Healthy'
default:
return 'Unhealthy'
}
}
Domain
Subdomains
Called By
Source
Frequently Asked Questions
What does getStatusLabel() do?
getStatusLabel() is a function in the supabase codebase.
What calls getStatusLabel()?
getStatusLabel() is called by 2 function(s): ReadReplicaNode, ReadReplicaRow.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free