Placeholder Plugin Providers for Repos and added testPlugin struct (#1532)
* Create minimalistic plugin map and test plugin. * Pass secrets and attributes to the plugin when creating catalogs or sets. Add tests for CreateSet and CreateCatalog repo methods. * make fmt and extract out getPrivateCatalog and getCatalog helper methods. * Exporting TestPluginServer so it can be used in the handlers. * Keep separate persisted data from host catalogs lookups which facilitate passing it onto the plugins. * Add TODO to merge get Catalog and get Persisted data. * Adding tests for unimplemented being returned by the plugin. * Use GetFields() instead of AsMap() to confirm attributes should be populated. Make clone consistent between catalog and sets. Co-authored-by: Jeff Mitchell <jeffrey.mitchell@gmail.com>
This commit is contained in:
1 parent
ea939a4445
commit
bbfef2802f
30 files changed
+669
-227
No files matched your search
@@ -7742,9 +7742,7 @@ alter table wh_session_connection_accumulating_fact
|
||||
create_time wt_timestamp,
|
||||
update_time wt_timestamp,
|
||||
version wt_version,
|
||||
attributes bytea not null
|
||||
constraint attributes_must_not_be_empty
|
||||
check(length(attributes) > 0),
|
||||
attributes bytea not null,
|
||||
constraint host_catalog_fkey
|
||||
foreign key (scope_id, public_id)
|
||||
references host_catalog (scope_id, public_id)
|
||||
@@ -7814,9 +7812,7 @@ alter table wh_session_connection_accumulating_fact
|
||||
create_time wt_timestamp,
|
||||
update_time wt_timestamp,
|
||||
version wt_version,
|
||||
attributes bytea not null
|
||||
constraint attributes_must_not_be_empty
|
||||
check(length(attributes) > 0),
|
||||
attributes bytea not null,
|
||||
constraint host_plugin_set_catalog_id_name_uq
|
||||
unique(catalog_id, name),
|
||||
constraint host_set_fkey
|
||||
@@ -7864,7 +7860,7 @@ create table host_set_preferred_endpoint (
|
||||
constraint priority_must_be_greater_than_zero
|
||||
check(priority > 0),
|
||||
condition text not null
|
||||
constraint condition_must_not_be_empty
|
||||
constraint condition_must_not_be_too_short
|
||||
check(length(trim(condition)) > 4) -- minimum is 'dns:*'
|
||||
constraint condition_must_not_be_too_long
|
||||
check(length(trim(condition)) < 255)
|
||||
|
||||
Reference in new issue
Block a user