@@ -98,8 +98,9 @@ func (b *base) reconcileAccessor(ctx context.Context, obj corev1alpha1.BindingAc
9898 }
9999
100100 var (
101- boundAPIs []corev1alpha1.BoundAPI
102- notExported []string
101+ boundAPIs []corev1alpha1.BoundAPI
102+ notExported []string
103+ pendingSchema []string
103104 )
104105 for _ , api := range spec .APIs {
105106 exported , ok := conn .Status .ExportsAPI (api .Name )
@@ -114,7 +115,9 @@ func (b *base) reconcileAccessor(ctx context.Context, obj corev1alpha1.BindingAc
114115 crd := & apiextensionsv1.CustomResourceDefinition {}
115116 if err := b .client .Get (ctx , client.ObjectKey {Name : api .Name }, crd ); err != nil {
116117 if apierrors .IsNotFound (err ) {
117- notExported = append (notExported , api .Name )
118+ // The API is exported, but the Connection has not installed the
119+ // synthesized CRD yet — a transient wait, not "not exported".
120+ pendingSchema = append (pendingSchema , api .Name )
118121 continue
119122 }
120123 return fmt .Errorf ("getting synthesized CRD %q: %w" , api .Name , err )
@@ -151,6 +154,11 @@ func (b *base) reconcileAccessor(ctx context.Context, obj corev1alpha1.BindingAc
151154 fmt .Sprintf ("APIs not exported by the provider yet: %s" , strings .Join (notExported , ", " )))
152155 return nil
153156 }
157+ if len (pendingSchema ) > 0 {
158+ setReady (status , obj , metav1 .ConditionFalse , corev1alpha1 .ReasonPending ,
159+ fmt .Sprintf ("waiting for the Connection to install the synthesized CRD(s): %s" , strings .Join (pendingSchema , ", " )))
160+ return nil
161+ }
154162
155163 // Sync related Secrets/ConfigMaps in the declared direction, scoped like the
156164 // binding.
0 commit comments