Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ingres: poll: do not poll before notifying systemd #13

Merged
merged 1 commit into from
Aug 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/ingres/poll.rs
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ impl Poller {
/// How far back to go in the run history is decided by `MAX_NEW_RUN_AGE`,
/// the most recent run id already known for the repository and the list
/// of runs the `create::jobs::Manager` is interested in.
pub async fn poll_once(&self) -> octocrab::Result<()> {
async fn poll_once(&self) -> octocrab::Result<()> {
let cfg = self.config.get();

// These are runs for which we have jobs in "interesting" states,
Expand Down
4 changes: 0 additions & 4 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,6 @@ async fn forrest() -> anyhow::Result<()> {
// missed webhooks.
let poller = ingres::Poller::new(config.clone(), auth.clone(), job_manager);

// Make sure we can reach GitHub and our authentication works before
// signaling readiness to systemd.
poller.poll_once().await?;

log::info!("Startup complete. Handling requests");

// Notify systemd that we are ready to handle requests.
Expand Down
Loading