<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Functionality on Porch Documentation</title><link>/docs/5_architecture_and_components/controllers/repository-controller/functionality/</link><description>Recent content in Functionality on Porch Documentation</description><generator>Hugo</generator><language>en-us</language><atom:link href="/docs/5_architecture_and_components/controllers/repository-controller/functionality/index.xml" rel="self" type="application/rss+xml"/><item><title>Sync Behavior</title><link>/docs/5_architecture_and_components/controllers/repository-controller/functionality/sync-behavior/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>/docs/5_architecture_and_components/controllers/repository-controller/functionality/sync-behavior/</guid><description>&lt;h2 id="overview">Overview&lt;/h2>&lt;p>The Repository controller uses two types of sync operations to keep repositories up-to-date:&lt;/p>
&lt;ul>
&lt;li>&lt;strong>Health checks&lt;/strong>: Lightweight connectivity validation that runs frequently to detect failures quickly&lt;/li>
&lt;li>&lt;strong>Full syncs&lt;/strong>: Complete repository synchronization that runs less often to fetch content and discover packages&lt;/li>
&lt;/ul>
&lt;p>The controller intelligently decides which operation to perform based on repository state and configured scheduling.&lt;/p>
&lt;h2 id="sync-operations">Sync Operations&lt;/h2>&lt;h3 id="health-check">Health Check&lt;/h3>&lt;p>Health checks perform quick connectivity validation without fetching repository contents. They execute synchronously in the reconcile loop, validating only that the repository is reachable without the overhead of git operations.&lt;/p></description></item><item><title>Error Handling</title><link>/docs/5_architecture_and_components/controllers/repository-controller/functionality/error-handling/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>/docs/5_architecture_and_components/controllers/repository-controller/functionality/error-handling/</guid><description>&lt;h2 id="overview">Overview&lt;/h2>&lt;p>When repository operations fail, the controller uses intelligent retry logic based on error type. Different errors require different retry strategies - transient network issues retry quickly, while authentication problems that need manual intervention retry less frequently to avoid wasting resources.&lt;/p>
&lt;p>For how errors affect sync scheduling behavior, see 
&lt;a href="/docs/5_architecture_and_components/controllers/repository-controller/functionality/sync-behavior/#sync-behavior-during-errors">Sync Behavior During Errors&lt;/a>.&lt;/p>
&lt;h2 id="error-specific-retry-intervals">Error-Specific Retry Intervals&lt;/h2>&lt;p>The controller analyzes error messages to determine appropriate retry timing:&lt;/p>
&lt;table>
 &lt;thead>
 &lt;tr>
 &lt;th>Error Type&lt;/th>
 &lt;th>Retry Interval&lt;/th>
 &lt;th>Error Patterns&lt;/th>
 &lt;th>Rationale&lt;/th>
 &lt;/tr>
 &lt;/thead>
 &lt;tbody>
 &lt;tr>
 &lt;td>&lt;strong>Network Issues&lt;/strong>&lt;/td>
 &lt;td>30 seconds&lt;/td>
 &lt;td>&amp;ldquo;no such host&amp;rdquo;, &amp;ldquo;connection refused&amp;rdquo;&lt;/td>
 &lt;td>Often transient, retry quickly&lt;/td>
 &lt;/tr>
 &lt;tr>
 &lt;td>&lt;strong>Authentication&lt;/strong>&lt;/td>
 &lt;td>10 minutes&lt;/td>
 &lt;td>&amp;ldquo;authentication required&amp;rdquo;, &amp;ldquo;permission denied&amp;rdquo;&lt;/td>
 &lt;td>Needs manual fix, avoid spam&lt;/td>
 &lt;/tr>
 &lt;tr>
 &lt;td>&lt;strong>Git Repo/Branch&lt;/strong>&lt;/td>
 &lt;td>2 minutes&lt;/td>
 &lt;td>&amp;ldquo;not found&amp;rdquo;, &amp;ldquo;invalid&amp;rdquo;, &amp;ldquo;branch&amp;rdquo;&lt;/td>
 &lt;td>May be transient (repo creation)&lt;/td>
 &lt;/tr>
 &lt;tr>
 &lt;td>&lt;strong>Timeouts&lt;/strong>&lt;/td>
 &lt;td>1 minute&lt;/td>
 &lt;td>&amp;ldquo;timeout&amp;rdquo;, &amp;ldquo;deadline exceeded&amp;rdquo;&lt;/td>
 &lt;td>Network congestion, moderate retry&lt;/td>
 &lt;/tr>
 &lt;tr>
 &lt;td>&lt;strong>TLS/SSL Issues&lt;/strong>&lt;/td>
 &lt;td>5 minutes&lt;/td>
 &lt;td>&amp;ldquo;certificate&amp;rdquo;, &amp;ldquo;tls&amp;rdquo;, &amp;ldquo;ssl&amp;rdquo;&lt;/td>
 &lt;td>Configuration issues, less frequent&lt;/td>
 &lt;/tr>
 &lt;tr>
 &lt;td>&lt;strong>Rate Limiting&lt;/strong>&lt;/td>
 &lt;td>5 minutes&lt;/td>
 &lt;td>&amp;ldquo;rate limit&amp;rdquo;, &amp;ldquo;too many requests&amp;rdquo;&lt;/td>
 &lt;td>Need to back off from API&lt;/td>
 &lt;/tr>
 &lt;tr>
 &lt;td>&lt;strong>Default&lt;/strong>&lt;/td>
 &lt;td>30 seconds&lt;/td>
 &lt;td>All other errors&lt;/td>
 &lt;td>Configurable fallback&lt;/td>
 &lt;/tr>
 &lt;/tbody>
&lt;/table>
&lt;h2 id="recovery-behavior">Recovery Behavior&lt;/h2>&lt;p>When a repository enters an error state, the controller adjusts its behavior to focus on recovery:&lt;/p></description></item><item><title>Status Management</title><link>/docs/5_architecture_and_components/controllers/repository-controller/functionality/status-management/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>/docs/5_architecture_and_components/controllers/repository-controller/functionality/status-management/</guid><description>&lt;h2 id="overview">Overview&lt;/h2>&lt;p>The Repository controller maintains detailed status information to track sync operations, detect changes, and provide observability. The status includes both standard Kubernetes conditions and custom fields specific to repository synchronization.&lt;/p>
&lt;h2 id="status-fields">Status Fields&lt;/h2>&lt;h3 id="repository-information">Repository Information&lt;/h3>&lt;p>The &lt;code>packageCount&lt;/code> field shows how many package revisions were discovered during the last sync.&lt;/p>
&lt;h3 id="git-commit-tracking">Git Commit Tracking&lt;/h3>&lt;p>For git repositories, the &lt;code>gitCommitHash&lt;/code> field contains the commit hash of the configured branch, enabling GitOps workflows to track which version is currently synced.&lt;/p></description></item></channel></rss>