summaryrefslogtreecommitdiff
path: root/exes
diff options
context:
space:
mode:
Diffstat (limited to 'exes')
-rw-r--r--exes/gateway/Cargo.toml3
-rw-r--r--exes/gateway/src/main.rs7
-rw-r--r--exes/ratelimit/Cargo.toml3
-rw-r--r--exes/ratelimit/src/main.rs7
-rw-r--r--exes/rest/Cargo.toml3
-rw-r--r--exes/rest/src/handler.rs12
-rw-r--r--exes/rest/src/main.rs7
-rw-r--r--exes/webhook/Cargo.toml3
-rw-r--r--exes/webhook/src/main.rs7
9 files changed, 7 insertions, 45 deletions
diff --git a/exes/gateway/Cargo.toml b/exes/gateway/Cargo.toml
index 375a020..3916138 100644
--- a/exes/gateway/Cargo.toml
+++ b/exes/gateway/Cargo.toml
@@ -22,6 +22,3 @@ twilight-gateway = { version = "0.14" }
twilight-model = "0.14"
bytes = "1.3.0"
async-nats = "0.26.0"
-
-[target.'cfg(not(target_os = "windows"))'.dependencies]
-tikv-jemallocator = { workspace = true } \ No newline at end of file
diff --git a/exes/gateway/src/main.rs b/exes/gateway/src/main.rs
index 900171c..f1b0298 100644
--- a/exes/gateway/src/main.rs
+++ b/exes/gateway/src/main.rs
@@ -1,11 +1,4 @@
use gateway::GatewayServer;
use leash::ignite;
-#[cfg(not(target_os = "windows"))]
-use tikv_jemallocator::Jemalloc;
-
-#[cfg(not(target_os = "windows"))]
-#[global_allocator]
-static GLOBAL: Jemalloc = Jemalloc;
-
ignite!(GatewayServer);
diff --git a/exes/ratelimit/Cargo.toml b/exes/ratelimit/Cargo.toml
index d7dc554..5be1a34 100644
--- a/exes/ratelimit/Cargo.toml
+++ b/exes/ratelimit/Cargo.toml
@@ -33,9 +33,6 @@ tracing-subscriber = { workspace = true }
test-log = { workspace = true }
env_logger = { workspace = true }
-[target.'cfg(not(target_os = "windows"))'.dependencies]
-tikv-jemallocator = { workspace = true }
-
[[bench]]
name = "bucket"
harness = false
diff --git a/exes/ratelimit/src/main.rs b/exes/ratelimit/src/main.rs
index b764367..2de812b 100644
--- a/exes/ratelimit/src/main.rs
+++ b/exes/ratelimit/src/main.rs
@@ -1,11 +1,4 @@
use leash::ignite;
use ratelimit::RatelimiterServerComponent;
-#[cfg(not(target_os = "windows"))]
-use tikv_jemallocator::Jemalloc;
-
-#[cfg(not(target_os = "windows"))]
-#[global_allocator]
-static GLOBAL: Jemalloc = Jemalloc;
-
ignite!(RatelimiterServerComponent);
diff --git a/exes/rest/Cargo.toml b/exes/rest/Cargo.toml
index d37da95..aed205f 100644
--- a/exes/rest/Cargo.toml
+++ b/exes/rest/Cargo.toml
@@ -30,6 +30,3 @@ hashring = "0.3.0"
tonic = "0.8.3"
tokio-stream = "0.1.11"
dns-lookup = "1.0.8"
-
-[target.'cfg(not(target_os = "windows"))'.dependencies]
-tikv-jemallocator = { workspace = true } \ No newline at end of file
diff --git a/exes/rest/src/handler.rs b/exes/rest/src/handler.rs
index 0070081..259ac1a 100644
--- a/exes/rest/src/handler.rs
+++ b/exes/rest/src/handler.rs
@@ -89,7 +89,7 @@ fn normalize_path(request_path: &str) -> (&str, &str) {
("/api", request_path)
}
}
-fn path_name(path: &Path) -> &'static str {
+const fn path_name(path: &Path) -> &'static str {
match path {
Path::ApplicationCommand(..) => "Application commands",
Path::ApplicationCommandId(..) => "Application command",
@@ -112,7 +112,9 @@ fn path_name(path: &Path) -> &'static str {
Path::ChannelsIdThreadMembersId(..) => "Thread member",
Path::ChannelsIdThreads(..) => "Channel threads",
Path::ChannelsIdTyping(..) => "Typing indicator",
- Path::ChannelsIdWebhooks(..) | Path::WebhooksId(..) => "Webhook",
+ Path::ChannelsIdWebhooks(..) | Path::WebhooksId(..) | Path::WebhooksIdToken(..) => {
+ "Webhook"
+ }
Path::Gateway => "Gateway",
Path::GatewayBot => "Gateway bot info",
Path::Guilds => "Guilds",
@@ -146,14 +148,15 @@ fn path_name(path: &Path) -> &'static str {
Path::GuildsIdScheduledEventsIdUsers(..) => "Users of a scheduled event",
Path::GuildsIdStickers(..) => "Guild stickers",
Path::GuildsIdTemplates(..) => "Guild templates",
- Path::GuildsIdTemplatesCode(..) => "Specific guild template",
+ Path::GuildsIdTemplatesCode(..) | Path::GuildsTemplatesCode(..) => {
+ "Specific guild template"
+ }
Path::GuildsIdThreads(..) => "Guild threads",
Path::GuildsIdVanityUrl(..) => "Guild vanity invite",
Path::GuildsIdVoiceStates(..) => "Guild voice states",
Path::GuildsIdWebhooks(..) => "Guild webhooks",
Path::GuildsIdWelcomeScreen(..) => "Guild welcome screen",
Path::GuildsIdWidget(..) => "Guild widget",
- Path::GuildsTemplatesCode(..) => "Specific guild template",
Path::InteractionCallback(..) => "Interaction callback",
Path::InvitesCode => "Invite info",
Path::OauthApplicationsMe => "Current application info",
@@ -167,7 +170,6 @@ fn path_name(path: &Path) -> &'static str {
Path::UsersIdGuildsId => "Guild from user",
Path::UsersIdGuildsIdMember => "Member of a guild",
Path::VoiceRegions => "Voice region list",
- Path::WebhooksIdToken(..) => "Webhook",
Path::WebhooksIdTokenMessagesId(..) => "Specific webhook message",
_ => "Unknown path!",
}
diff --git a/exes/rest/src/main.rs b/exes/rest/src/main.rs
index 1e73e09..fe8ada7 100644
--- a/exes/rest/src/main.rs
+++ b/exes/rest/src/main.rs
@@ -1,11 +1,4 @@
use leash::ignite;
use rest::ReverseProxyServer;
-#[cfg(not(target_os = "windows"))]
-use tikv_jemallocator::Jemalloc;
-
-#[cfg(not(target_os = "windows"))]
-#[global_allocator]
-static GLOBAL: Jemalloc = Jemalloc;
-
ignite!(ReverseProxyServer);
diff --git a/exes/webhook/Cargo.toml b/exes/webhook/Cargo.toml
index 7b4a185..0078a70 100644
--- a/exes/webhook/Cargo.toml
+++ b/exes/webhook/Cargo.toml
@@ -19,6 +19,3 @@ ed25519-dalek = "1"
twilight-model = { version = "0.14" }
async-nats = "0.26.0"
-
-[target.'cfg(not(target_os = "windows"))'.dependencies]
-tikv-jemallocator = "0.5" \ No newline at end of file
diff --git a/exes/webhook/src/main.rs b/exes/webhook/src/main.rs
index bbacda7..f531725 100644
--- a/exes/webhook/src/main.rs
+++ b/exes/webhook/src/main.rs
@@ -1,11 +1,4 @@
use leash::ignite;
use webhook::WebhookServer;
-#[cfg(not(target_os = "windows"))]
-use tikv_jemallocator::Jemalloc;
-
-#[cfg(not(target_os = "windows"))]
-#[global_allocator]
-static GLOBAL: Jemalloc = Jemalloc;
-
ignite!(WebhookServer);