Skip to main content

Message bus events

This document provides detailed documentation for all events used in the Infrahub message bus system.

info

For more detailed explanations on how these events are used within Infrahub, see the event system documentation.

Messages events​

Git Branch Heads​

Event git.branch_heads.get​

Description: Read the remote head of every branch of a repository from a worker's local clone.

Priority: 4

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone
repository_idThe unique ID of the RepositorystringNone
repository_nameThe name of the repositorystringNone
repository_kindThe kind of the repositorystringNone
locationThe external URL of the repositorystringNone
branchesThe branches whose remote heads are readarrayNone

Git Commit Log​

Event git.commit_log.get​

Description: Read the commit log of a repository from a worker's local clone.

Priority: 4

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone
repository_idThe unique ID of the RepositorystringNone
repository_nameThe name of the repositorystringNone
repository_kindThe kind of the repositorystringNone
locationThe external URL of the repositorystringNone
infrahub_branch_nameInfrahub branch the log is read forstringNone
git_refRemote branch or read-only ref whose history is listedstringNone
imported_commitCommit imported on the Infrahub branchN/ANone
limitNumber of commits to returnintegerNone
offsetNumber of commits to skip from the headintegerNone
include_pending_countWhether to count the commits not yet importedbooleanNone

Git File​

Event git.file.get​

Description: Read a file from a Git repository.

Priority: 4

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone
branch_nameThe Infrahub branch the file request is scoped tostringNone
commitThe commit id to use to access the filestringNone
fileThe path and filename within the repositorystringNone
repository_idThe unique ID of the RepositorystringNone
repository_nameThe name of the repositorystringNone
repository_kindThe kind of the repositorystringNone

Git Repository​

Event git.repository.connectivity​

Description: Validate connectivity and credentials to remote repository.

Priority: 3

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone
repository_nameThe name of the repositorystringNone
repository_locationThe location of repositorystringNone
default_branchThe branch that must exist on the remote; when unset, only connectivity is checkedN/ANone
requires_writeWhether the check must also confirm write (push) access to the remotebooleanFalse

Refresh Git​

Event refresh.git.clone​

Description: Ask every worker to create its local copy of a repository if it has none, without changing any checkout.

Priority: 3

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone
repository_idThe unique ID of the repositorystringNone
repository_nameThe name of the repositorystringNone
repository_kindThe type of repositorystringNone
infrahub_branch_nameInfrahub branch whose ref a new copy checks outstringNone

Event refresh.git.fetch​

Description: Fetch a repository remote changes.

Priority: 3

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone
locationThe external URL of the repositorystringNone
repository_idThe unique ID of the repositorystringNone
repository_nameThe name of the repositorystringNone
repository_kindThe type of repositorystringNone
infrahub_branch_nameInfrahub branch on which to sync the remote repositorystringNone
infrahub_branch_idId of the Infrahub branch on which to sync the remote repositorystringNone
commitCommit SHA to check out, pinned by the sync orchestrator instead of pulling the latest upstream HEADN/ANone
branchesEvery branch to converge with its pinned commit, the first one repeating the single-branch fieldsN/ANone

Event refresh.git.branch_deleted​

Description: Notify workers that a branch was deleted from the remote repository.

Priority: 3

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone
repository_idThe unique ID of the repositorystringNone
repository_nameThe name of the repositorystringNone
repository_kindThe type of repositorystringNone
branch_nameThe name of the branch that was deletedstringNone

Refresh Registry​

Event refresh.registry.branches​

Description: Sent to indicate that the registry should be refreshed and new branch data loaded.

Priority: 3

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone

Event refresh.registry.rebased_branch​

Description: Sent to refresh a rebased branch within the local registry.

Priority: 3

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone
branchThe branch that was rebasedstringNone

Refresh Settings​

Event refresh.settings.response_delay​

Description: Broadcast to update the API response delay on every running API worker process.

Priority: 3

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone
response_delayDelay in seconds to add to each API requestintegerNone

Send Echo​

Event send.echo.request​

Description: Sent a echo request, a ping message for example.

Priority: 5

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone
messageThe message to sendstringNone

Responses events​

Git Branch Heads​

Event git.branch_heads.get​

Priority: 4

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone
passedN/AbooleanTrue
routing_keyN/Astringgit.branch_heads.get
data.fetched_atN/AN/ANone
data.unavailable_reasonN/AN/ANone
data.warm_up_task_idN/AN/ANone
data.branchesN/AarrayNone
data.error_messageN/AN/ANone
errorsN/AarrayNone
initial_messageInitial message in dict format, the primary goal of this field is to provide additional context when there is an errorN/ANone

Git Commit Log​

Event git.commit_log.get​

Priority: 4

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone
passedN/AbooleanTrue
routing_keyN/Astringgit.commit_log.get
data.conditionN/AN/ANone
data.remote_headN/AN/ANone
data.imported_commitN/AN/ANone
data.pending_countN/AN/ANone
data.fetched_atN/AN/ANone
data.unavailable_reasonN/AN/ANone
data.warm_up_task_idN/AN/ANone
data.commitsN/AarrayNone
data.error_messageN/AN/ANone
errorsN/AarrayNone
initial_messageInitial message in dict format, the primary goal of this field is to provide additional context when there is an errorN/ANone

Git File​

Event git.file.get​

Priority: 4

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone
passedN/AbooleanTrue
routing_keyN/Astringgit.file.get
data.contentN/AN/ANone
data.error_messageN/AN/ANone
data.http_codeN/AN/ANone
errorsN/AarrayNone
initial_messageInitial message in dict format, the primary goal of this field is to provide additional context when there is an errorN/ANone

Send Echo​

Event send.echo.request​

Priority: 5

KeyDescriptionTypeDefault Value
metaMeta properties for the messageN/ANone
passedN/AbooleanTrue
routing_keyN/Astringsend.echo.request
data.responseThe response stringstring
errorsN/AarrayNone
initial_messageInitial message in dict format, the primary goal of this field is to provide additional context when there is an errorN/ANone