Skip to content

Commit

Permalink
Update rust-axum samples
Browse files Browse the repository at this point in the history
  • Loading branch information
Elric Milon committed Jan 28, 2025
1 parent fad6fa1 commit 7057ab9
Show file tree
Hide file tree
Showing 64 changed files with 102 additions and 102 deletions.
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7.11.0-SNAPSHOT
7.12.0-SNAPSHOT
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ conversion = [

[dependencies]
async-trait = "0.1"
axum = "0.7"
axum-extra = { version = "0.9", features = ["cookie", "multipart"] }
axum = "0.8"
axum-extra = { version = "0.10", features = ["cookie", "multipart"] }
base64 = "0.22"
bytes = "1"
chrono = { version = "0.4", features = ["serde"] }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ server, you can easily generate a server stub.
To see how to make this your own, look here: [README]((https://openapi-generator.tech))

- API version: 1.0.0
- Generator version: 7.11.0-SNAPSHOT
- Generator version: 7.12.0-SNAPSHOT



Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use std::collections::HashMap;

use axum::{body::Body, extract::*, response::Response, routing::*};
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::{header::CONTENT_TYPE, HeaderMap, HeaderName, HeaderValue, Method, StatusCode};
use tracing::error;
Expand All @@ -26,7 +26,7 @@ where
Router::new()
.route("/v71/paymentMethods", get(get_payment_methods::<I, A, C>))
.route(
"/v71/paymentMethods/:id",
"/v71/paymentMethods/{id}",
get(get_payment_method_by_id::<I, A, C>),
)
.route("/v71/payments", post(post_make_payment::<I, A, C>))
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7.11.0-SNAPSHOT
7.12.0-SNAPSHOT
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ conversion = [

[dependencies]
async-trait = "0.1"
axum = "0.7"
axum-extra = { version = "0.9", features = ["cookie", "multipart"] }
axum = "0.8"
axum-extra = { version = "0.10", features = ["cookie", "multipart"] }
base64 = "0.22"
bytes = "1"
chrono = { version = "0.4", features = ["serde"] }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ server, you can easily generate a server stub.
To see how to make this your own, look here: [README]((https://openapi-generator.tech))

- API version: 1.0.7
- Generator version: 7.11.0-SNAPSHOT
- Generator version: 7.12.0-SNAPSHOT



Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use std::collections::HashMap;

use axum::{body::Body, extract::*, response::Response, routing::*};
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::{header::CONTENT_TYPE, HeaderMap, HeaderName, HeaderValue, Method, StatusCode};
use tracing::error;
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7.11.0-SNAPSHOT
7.12.0-SNAPSHOT
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ conversion = [

[dependencies]
async-trait = "0.1"
axum = "0.7"
axum-extra = { version = "0.9", features = ["cookie", "multipart"] }
axum = "0.8"
axum-extra = { version = "0.10", features = ["cookie", "multipart"] }
base64 = "0.22"
bytes = "1"
chrono = { version = "0.4", features = ["serde"] }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ server, you can easily generate a server stub.
To see how to make this your own, look here: [README]((https://openapi-generator.tech))

- API version: 1.0.7
- Generator version: 7.11.0-SNAPSHOT
- Generator version: 7.12.0-SNAPSHOT



Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use std::collections::HashMap;

use axum::{body::Body, extract::*, response::Response, routing::*};
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::{header::CONTENT_TYPE, HeaderMap, HeaderName, HeaderValue, Method, StatusCode};
use tracing::error;
Expand Down Expand Up @@ -29,7 +29,7 @@ where
.route("/complex-query-param",
get(complex_query_param_get::<I, A>)
)
.route("/enum_in_path/:path_param",
.route("/enum_in_path/{path_param}",
get(enum_in_path_path_param_get::<I, A>)
)
.route("/form-test",
Expand All @@ -50,7 +50,7 @@ where
.route("/multiget",
get(multiget_get::<I, A>)
)
.route("/multiple-path-params-with-very-long-path-to-test-formatting/:path_param_a/:path_param_b",
.route("/multiple-path-params-with-very-long-path-to-test-formatting/{path_param_a}/{path_param_b}",
get(multiple_path_params_with_very_long_path_to_test_formatting_path_param_a_path_param_b_get::<I, A>)
)
.route("/multiple_auth_scheme",
Expand All @@ -77,7 +77,7 @@ where
.route("/repos",
post(create_repo::<I, A>)
)
.route("/repos/:repo_id",
.route("/repos/{repo_id}",
get(get_repo_info::<I, A>).get(get_repo_info::<I, A>)
)
.route("/required_octet_stream",
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7.11.0-SNAPSHOT
7.12.0-SNAPSHOT
4 changes: 2 additions & 2 deletions samples/server/petstore/rust-axum/output/ops-v3/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ conversion = [

[dependencies]
async-trait = "0.1"
axum = "0.7"
axum-extra = { version = "0.9", features = ["cookie", "multipart"] }
axum = "0.8"
axum-extra = { version = "0.10", features = ["cookie", "multipart"] }
base64 = "0.22"
bytes = "1"
chrono = { version = "0.4", features = ["serde"] }
Expand Down
2 changes: 1 addition & 1 deletion samples/server/petstore/rust-axum/output/ops-v3/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ server, you can easily generate a server stub.
To see how to make this your own, look here: [README]((https://openapi-generator.tech))

- API version: 0.0.1
- Generator version: 7.11.0-SNAPSHOT
- Generator version: 7.12.0-SNAPSHOT



Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use std::collections::HashMap;

use axum::{body::Body, extract::*, response::Response, routing::*};
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::{header::CONTENT_TYPE, HeaderMap, HeaderName, HeaderValue, Method, StatusCode};
use tracing::error;
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7.11.0-SNAPSHOT
7.12.0-SNAPSHOT
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ conversion = [

[dependencies]
async-trait = "0.1"
axum = "0.7"
axum-extra = { version = "0.9", features = ["cookie", "multipart"] }
axum = "0.8"
axum-extra = { version = "0.10", features = ["cookie", "multipart"] }
base64 = "0.22"
bytes = "1"
chrono = { version = "0.4", features = ["serde"] }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ server, you can easily generate a server stub.
To see how to make this your own, look here: [README]((https://openapi-generator.tech))

- API version: 1.0.0
- Generator version: 7.11.0-SNAPSHOT
- Generator version: 7.12.0-SNAPSHOT



Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use std::collections::HashMap;

use axum::{body::Body, extract::*, response::Response, routing::*};
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::{header::CONTENT_TYPE, HeaderMap, HeaderName, HeaderValue, Method, StatusCode};
use tracing::error;
Expand Down Expand Up @@ -40,7 +40,7 @@ where
put(test_body_with_query_params::<I, A>),
)
.route(
"/v2/fake/hyphenParam/:hyphen_param",
"/v2/fake/hyphenParam/{hyphen_param}",
get(hyphen_param::<I, A>),
)
.route(
Expand Down Expand Up @@ -77,28 +77,22 @@ where
"/v2/pet",
post(add_pet::<I, A, C>).put(update_pet::<I, A, C>),
)
.route("/v2/pet/findByStatus", get(find_pets_by_status::<I, A, C>))
.route("/v2/pet/findByTags", get(find_pets_by_tags::<I, A, C>))
.route(
"/v2/pet/:pet_id",
"/v2/pet/{pet_id}",
delete(delete_pet::<I, A, C>)
.get(get_pet_by_id::<I, A, C>)
.post(update_pet_with_form::<I, A, C>),
)
.route("/v2/pet/:pet_id/uploadImage", post(upload_file::<I, A, C>))
.route("/v2/pet/findByStatus", get(find_pets_by_status::<I, A, C>))
.route("/v2/pet/findByTags", get(find_pets_by_tags::<I, A, C>))
.route("/v2/pet/{pet_id}/uploadImage", post(upload_file::<I, A, C>))
.route("/v2/store/inventory", get(get_inventory::<I, A, C>))
.route("/v2/store/order", post(place_order::<I, A, C>))
.route(
"/v2/store/order/:order_id",
"/v2/store/order/{order_id}",
delete(delete_order::<I, A, C>).get(get_order_by_id::<I, A, C>),
)
.route("/v2/user", post(create_user::<I, A>))
.route(
"/v2/user/:username",
delete(delete_user::<I, A>)
.get(get_user_by_name::<I, A>)
.put(update_user::<I, A>),
)
.route(
"/v2/user/createWithArray",
post(create_users_with_array_input::<I, A>),
Expand All @@ -109,6 +103,12 @@ where
)
.route("/v2/user/login", get(login_user::<I, A>))
.route("/v2/user/logout", get(logout_user::<I, A>))
.route(
"/v2/user/{username}",
delete(delete_user::<I, A>)
.get(get_user_by_name::<I, A>)
.put(update_user::<I, A>),
)
.with_state(api_impl)
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7.11.0-SNAPSHOT
7.12.0-SNAPSHOT
4 changes: 2 additions & 2 deletions samples/server/petstore/rust-axum/output/petstore/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ conversion = [

[dependencies]
async-trait = "0.1"
axum = "0.7"
axum-extra = { version = "0.9", features = ["cookie", "multipart"] }
axum = "0.8"
axum-extra = { version = "0.10", features = ["cookie", "multipart"] }
base64 = "0.22"
bytes = "1"
chrono = { version = "0.4", features = ["serde"] }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ server, you can easily generate a server stub.
To see how to make this your own, look here: [README]((https://openapi-generator.tech))

- API version: 1.0.0
- Generator version: 7.11.0-SNAPSHOT
- Generator version: 7.12.0-SNAPSHOT



Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use async_trait::async_trait;
use axum::extract::*;
use axum_extra::extract::{CookieJar, Multipart};
use axum_extra::extract::{CookieJar, Host, Multipart};
use bytes::Bytes;
use http::Method;
use serde::{Deserialize, Serialize};
Expand Down
Loading

0 comments on commit 7057ab9

Please sign in to comment.