@@ -13,7 +13,7 @@ use mithril_common::entities::{
1313 HexEncodedGenesisVerificationKey , HexEncodedKey , ProtocolParameters , SignedEntityConfig ,
1414 SignedEntityTypeDiscriminants ,
1515} ;
16- use mithril_common:: { CardanoNetwork , StdResult } ;
16+ use mithril_common:: { AggregateSignatureType , CardanoNetwork , StdResult } ;
1717use mithril_doc:: { Documenter , DocumenterDefault , StructDoc } ;
1818use mithril_era:: adapters:: EraReaderAdapterType ;
1919
@@ -382,6 +382,11 @@ pub trait ConfigurationSource {
382382
383383 white_list
384384 }
385+
386+ /// Aggregate signature type
387+ fn aggregate_signature_type ( & self ) -> AggregateSignatureType {
388+ panic ! ( "get_aggregate_signature_type is not implemented." ) ;
389+ }
385390}
386391
387392/// Serve command configuration
@@ -557,6 +562,9 @@ pub struct ServeCommandConfiguration {
557562 /// Custom origin tag of client request added to the whitelist (comma
558563 /// separated list).
559564 pub custom_origin_tag_white_list : Option < String > ,
565+
566+ /// Aggregate signature type used to create certificates
567+ pub aggregate_signature_type : AggregateSignatureType ,
560568}
561569
562570/// Uploader needed to copy the snapshot once computed.
@@ -689,6 +697,7 @@ impl ServeCommandConfiguration {
689697 persist_usage_report_interval_in_seconds : 10 ,
690698 leader_aggregator_endpoint : None ,
691699 custom_origin_tag_white_list : None ,
700+ aggregate_signature_type : AggregateSignatureType :: Concatenation ,
692701 }
693702 }
694703
@@ -880,6 +889,10 @@ impl ConfigurationSource for ServeCommandConfiguration {
880889 None => self . get_local_server_url ( ) ,
881890 }
882891 }
892+
893+ fn aggregate_signature_type ( & self ) -> AggregateSignatureType {
894+ self . aggregate_signature_type
895+ }
883896}
884897
885898/// Default configuration with all the default values for configurations.
@@ -955,6 +968,9 @@ pub struct DefaultConfiguration {
955968
956969 /// Time interval at which metrics are persisted in event database (in seconds).
957970 pub persist_usage_report_interval_in_seconds : u64 ,
971+
972+ /// Aggregate signature type used to create certificates
973+ pub aggregate_signature_type : String ,
958974}
959975
960976impl Default for DefaultConfiguration {
@@ -986,6 +1002,7 @@ impl Default for DefaultConfiguration {
9861002 metrics_server_ip : "0.0.0.0" . to_string ( ) ,
9871003 metrics_server_port : 9090 ,
9881004 persist_usage_report_interval_in_seconds : 10 ,
1005+ aggregate_signature_type : "Concatenation" . to_string ( ) ,
9891006 }
9901007 }
9911008}
@@ -1069,6 +1086,7 @@ impl Source for DefaultConfiguration {
10691086 ( "step" . to_string( ) , ValueKind :: from( * v. step) , )
10701087 ] )
10711088 ) ;
1089+ register_config_value ! ( result, & namespace, myself. aggregate_signature_type) ;
10721090 Ok ( result)
10731091 }
10741092}
0 commit comments