pub struct KafkaConfig {Show 13 fields
pub enabled: bool,
pub port: u16,
pub host: String,
pub broker_id: i32,
pub max_connections: usize,
pub log_retention_ms: i64,
pub log_segment_bytes: i64,
pub fixtures_dir: Option<PathBuf>,
pub auto_create_topics: bool,
pub default_partitions: i32,
pub default_replication_factor: i16,
pub advertised_host: Option<String>,
pub advertised_port: Option<u16>,
}Expand description
Kafka server configuration
Fields§
§enabled: boolEnable Kafka server
port: u16Server port
host: StringHost address
broker_id: i32Broker ID
max_connections: usizeMaximum connections
log_retention_ms: i64Log retention time in milliseconds
log_segment_bytes: i64Log segment size in bytes
fixtures_dir: Option<PathBuf>Fixtures directory
auto_create_topics: boolAuto-create topics
default_partitions: i32Default number of partitions for new topics
default_replication_factor: i16Default replication factor for new topics
advertised_host: Option<String>Hostname returned in Kafka MetadataResponse so clients reach the
broker after the bootstrap handshake. Defaults to host. On
hosted-mock deployments the orchestrator sets this to the public
<app>.fly.dev (or custom) hostname so external Kafka clients can
route correctly. The mockforge-kafka broker itself must consume this
value when constructing metadata responses for the wiring to be
observable end-to-end (tracked in #231).
advertised_port: Option<u16>Public port returned in Kafka MetadataResponse alongside
advertised_host. Defaults to port. Useful when Fly maps a
different public port (currently we keep them aligned at 9092).
Trait Implementations§
Source§impl Clone for KafkaConfig
impl Clone for KafkaConfig
Source§fn clone(&self) -> KafkaConfig
fn clone(&self) -> KafkaConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for KafkaConfig
impl Debug for KafkaConfig
Source§impl Default for KafkaConfig
impl Default for KafkaConfig
Source§impl<'de> Deserialize<'de> for KafkaConfigwhere
KafkaConfig: Default,
impl<'de> Deserialize<'de> for KafkaConfigwhere
KafkaConfig: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl JsonSchema for KafkaConfig
impl JsonSchema for KafkaConfig
Source§fn schema_name() -> String
fn schema_name() -> String
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn is_referenceable() -> bool
fn is_referenceable() -> bool
$ref keyword. Read moreAuto Trait Implementations§
impl Freeze for KafkaConfig
impl RefUnwindSafe for KafkaConfig
impl Send for KafkaConfig
impl Sync for KafkaConfig
impl Unpin for KafkaConfig
impl UnsafeUnpin for KafkaConfig
impl UnwindSafe for KafkaConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more