From 69f16a51444b4663945a896bf30eb2dcb3fa6d30 Mon Sep 17 00:00:00 2001 From: Jim Crossley Date: Wed, 23 Jun 2021 13:29:07 -0400 Subject: [PATCH] Fixed docs Verified `cargo doc --all-features` works Signed-off-by: Jim Crossley --- src/actix/mod.rs | 5 +---- src/lib.rs | 8 +------- src/rdkafka/kafka_producer_record.rs | 2 +- src/rdkafka/mod.rs | 1 - src/reqwest/mod.rs | 5 +---- src/warp/filter.rs | 2 +- src/warp/mod.rs | 4 +--- src/warp/reply.rs | 2 +- 8 files changed, 7 insertions(+), 22 deletions(-) diff --git a/src/actix/mod.rs b/src/actix/mod.rs index ec88a84..ea3f322 100644 --- a/src/actix/mod.rs +++ b/src/actix/mod.rs @@ -1,4 +1,4 @@ -//! This crate integrates the [cloudevents-sdk](https://docs.rs/cloudevents-sdk) with [Actix web](https://docs.rs/actix-web/) to easily send and receive CloudEvents. +//! This module integrates the [cloudevents-sdk](https://docs.rs/cloudevents-sdk) with [Actix web](https://docs.rs/actix-web/) to easily send and receive CloudEvents. //! //! To deserialize an HTTP request as CloudEvent: //! @@ -38,10 +38,7 @@ //! ) //! } //! ``` -//! -//! Check out the [cloudevents-sdk](https://docs.rs/cloudevents-sdk) docs for more details on how to use [`cloudevents::Event`] -#![doc(html_root_url = "https://docs.rs/cloudevents-sdk/0.3.1")] #![deny(broken_intra_doc_links)] #[macro_use] diff --git a/src/lib.rs b/src/lib.rs index 8f4018a..d78c7b9 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -29,15 +29,9 @@ //! * The [`EventBuilder`] trait and implementations, to create [`Event`] instances //! * The implementation of [`serde::Serialize`] and [`serde::Deserialize`] for [`Event`] to serialize/deserialize CloudEvents to/from JSON //! * Traits and utilities in [`message`] to implement Protocol Bindings -//! -//! If you're looking for Protocol Binding implementations, look at crates: -//! -//! * [cloudevents-sdk-actix-web](https://docs.rs/cloudevents-sdk-actix-web): Integration with [Actix Web](https://github.com/actix/actix-web) -//! * [cloudevents-sdk-reqwest](https://docs.rs/cloudevents-sdk-reqwest): Integration with [reqwest](https://github.com/seanmonstar/reqwest) -//! * [cloudevents-sdk-rdkafka](https://docs.rs/cloudevents-sdk-rdkafka): Integration with [rdkafka](https://fede1024.github.io/rust-rdkafka) +//! * Feature-guarded modules for various Protocol Binding implementations, e.g. actix, reqwest, warp, rdkafka //! -#![doc(html_root_url = "https://docs.rs/cloudevents-sdk/0.3.1")] #![deny(broken_intra_doc_links)] #[cfg(feature = "cloudevents-actix")] diff --git a/src/rdkafka/kafka_producer_record.rs b/src/rdkafka/kafka_producer_record.rs index b5122cc..c3e8951 100644 --- a/src/rdkafka/kafka_producer_record.rs +++ b/src/rdkafka/kafka_producer_record.rs @@ -11,7 +11,7 @@ use rdkafka::producer::{BaseRecord, FutureRecord}; /// Implements [`StructuredSerializer`] & [`BinarySerializer`] traits. /// /// To instantiate a new `MessageRecord` from an [`Event`], -/// look at [`Self::from_event`] or use [`StructuredDeserializer::deserialize_structured`](cloudevents::message::StructuredDeserializer::deserialize_structured) +/// look at [`Self::from_event`] or use [`StructuredDeserializer::deserialize_structured`](crate::message::StructuredDeserializer::deserialize_structured) /// or [`BinaryDeserializer::deserialize_binary`]. pub struct MessageRecord { pub(crate) headers: OwnedHeaders, diff --git a/src/rdkafka/mod.rs b/src/rdkafka/mod.rs index 00f2baa..31c279e 100644 --- a/src/rdkafka/mod.rs +++ b/src/rdkafka/mod.rs @@ -48,7 +48,6 @@ //! # } //! ``` -#![doc(html_root_url = "https://docs.rs/cloudevents-sdk/0.3.1")] #![deny(broken_intra_doc_links)] #[macro_use] diff --git a/src/reqwest/mod.rs b/src/reqwest/mod.rs index edb25ed..544218f 100644 --- a/src/reqwest/mod.rs +++ b/src/reqwest/mod.rs @@ -1,4 +1,4 @@ -//! This crate integrates the [cloudevents-sdk](https://docs.rs/cloudevents-sdk) with [reqwest](https://docs.rs/reqwest/) to easily send and receive CloudEvents. +//! This module integrates the [cloudevents-sdk](https://docs.rs/cloudevents-sdk) with [reqwest](https://docs.rs/reqwest/) to easily send and receive CloudEvents. //! //! ``` //! use cloudevents::reqwest::{RequestBuilderExt, ResponseExt}; @@ -26,10 +26,7 @@ //! # Ok(()) //! # } //! ``` -//! -//! Check out the [cloudevents-sdk](https://docs.rs/cloudevents-sdk) docs for more details on how to use [`cloudevents::Event`]. -#![doc(html_root_url = "https://docs.rs/cloudevents-sdk/0.3.1")] #![deny(broken_intra_doc_links)] #[macro_use] diff --git a/src/warp/filter.rs b/src/warp/filter.rs index 965ea86..3a9c51d 100644 --- a/src/warp/filter.rs +++ b/src/warp/filter.rs @@ -13,7 +13,7 @@ pub struct EventFilterError { impl warp::reject::Reject for EventFilterError {} /// -/// # Extracts [`cloudevents::Event`] from incoming request +/// # Extracts [`crate::Event`] from incoming request /// /// ``` /// use cloudevents::warp::filter::to_event; diff --git a/src/warp/mod.rs b/src/warp/mod.rs index 93691f8..64867e5 100644 --- a/src/warp/mod.rs +++ b/src/warp/mod.rs @@ -1,4 +1,4 @@ -//! This crate integrates the [cloudevents-sdk](https://docs.rs/cloudevents-sdk) with [Warp web service framework](https://docs.rs/warp/) +//! This module integrates the [cloudevents-sdk](https://docs.rs/cloudevents-sdk) with [Warp web service framework](https://docs.rs/warp/) //! to easily send and receive CloudEvents. //! //! To deserialize an HTTP request as CloudEvent @@ -57,8 +57,6 @@ //! }); //! warp::serve(routes).run(([127, 0, 0, 1], 3030)); //! ``` -//! -//! Check out the [cloudevents-sdk](https://docs.rs/cloudevents-sdk) docs for more details on how to use [`cloudevents::Event`] #[macro_use] mod headers; diff --git a/src/warp/reply.rs b/src/warp/reply.rs index 9103ba6..4f91abf 100644 --- a/src/warp/reply.rs +++ b/src/warp/reply.rs @@ -5,7 +5,7 @@ use http::StatusCode; use warp::reply::Response; /// -/// # Serializes [`cloudevents::Event`] as a http response +/// # Serializes [`crate::Event`] as a http response /// /// ``` /// use cloudevents::warp::reply::from_event;