camel_component_api/
lib.rs1pub mod bundle;
11pub mod component;
12pub mod component_context;
13pub mod consumer;
14pub mod endpoint;
15pub mod health_registry;
16pub mod runtime_observability;
17
18pub mod network_retry;
19pub mod producer;
20pub mod registrar;
21#[cfg(any(test, feature = "test-support"))]
22pub mod test_support;
23
24pub use bundle::ComponentBundle;
25pub use component::Component;
26pub use component_context::{ComponentContext, NoOpComponentContext};
27pub use consumer::{
28 ConcurrencyModel, Consumer, ConsumerContext, ExchangeEnvelope, SecurityContext,
29};
30pub use endpoint::{Endpoint, PollingConsumer};
31pub use health_registry::{
32 HealthCheckRegistry, NoOpHealthCheckRegistry, noop_health_check_registry,
33};
34pub use runtime_observability::RuntimeObservability;
35
36pub use network_retry::{
37 NetworkRetryPolicy, is_retryable_camel_error, retry_async, retry_async_cancelable,
38};
39pub use producer::ProducerContext;
40pub use registrar::ComponentRegistrar;
41#[cfg(any(test, feature = "test-support"))]
42pub use test_support::PanicRuntimeObservability;
43
44pub use camel_api::{
46 AsyncHealthCheck, Body, BodyType, BoxProcessor, CamelError, CheckResult, Exchange,
47 HealthStatus, Message, RouteAction, RouteStatus, RuntimeCommand, RuntimeCommandBus,
48 RuntimeCommandResult, RuntimeHandle, RuntimeQuery, RuntimeQueryBus, RuntimeQueryResult,
49 StreamBody, StreamMetadata, Value,
50};
51
52pub use camel_endpoint::{UriComponents, UriConfig, parse_uri};
54pub mod uri {
57 pub fn parse_bool_param(s: &str) -> Result<bool, String> {
60 match s.to_lowercase().as_str() {
61 "true" | "1" | "yes" => Ok(true),
62 "false" | "0" | "no" => Ok(false),
63 _ => Err(format!("invalid boolean value: '{}'", s)),
64 }
65 }
66}