@@ -1457,7 +1457,7 @@ def _on_relation_changed_event(self, event: RelationChangedEvent) -> None:
1457
1457
class ProviderData (Data ):
1458
1458
"""Base provides-side of the data products relation."""
1459
1459
1460
- DATABASE_FIELD = "database"
1460
+ RESOURCE_FIELD = "database"
1461
1461
1462
1462
def __init__ (
1463
1463
self ,
@@ -1626,7 +1626,7 @@ def _update_relation_data(self, relation: Relation, data: Dict[str, str]) -> Non
1626
1626
req_secret_fields = []
1627
1627
1628
1628
keys = set (data .keys ())
1629
- if self .fetch_relation_field (relation .id , self .DATABASE_FIELD ) is None and (
1629
+ if self .fetch_relation_field (relation .id , self .RESOURCE_FIELD ) is None and (
1630
1630
keys - {"endpoints" , "read-only-endpoints" , "replset" }
1631
1631
):
1632
1632
raise PrematureDataAccessError (
@@ -3305,7 +3305,7 @@ class KafkaRequiresEvents(CharmEvents):
3305
3305
class KafkaProviderData (ProviderData ):
3306
3306
"""Provider-side of the Kafka relation."""
3307
3307
3308
- DATABASE_FIELD = "topic"
3308
+ RESOURCE_FIELD = "topic"
3309
3309
3310
3310
def __init__ (self , model : Model , relation_name : str ) -> None :
3311
3311
super ().__init__ (model , relation_name )
@@ -3556,7 +3556,7 @@ class OpenSearchRequiresEvents(CharmEvents):
3556
3556
class OpenSearchProvidesData (ProviderData ):
3557
3557
"""Provider-side of the OpenSearch relation."""
3558
3558
3559
- DATABASE_FIELD = "index"
3559
+ RESOURCE_FIELD = "index"
3560
3560
3561
3561
def __init__ (self , model : Model , relation_name : str ) -> None :
3562
3562
super ().__init__ (model , relation_name )
0 commit comments