Skip to content

Commit

Permalink
hotfix for max_dataclip_size_bytes
Browse files Browse the repository at this point in the history
  • Loading branch information
taylordowns2000 committed Jan 26, 2024
1 parent 2a8c747 commit ebb17d2
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ and this project adheres to

### Fixed

## [v2.0.0-rc6] - 2024-01-26
## [v2.0.0-rc7] - 2024-01-26

### Added

Expand Down
9 changes: 5 additions & 4 deletions config/runtime.exs
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ config :lightning,
:max_dataclip_size_bytes,
System.get_env("MAX_DATACLIP_SIZE_MB", "10")
|> String.to_integer()
|> Kernel.*(1000)
|> Kernel.*(1_000_000)

config :lightning,
:queue_result_retention_period,
Expand Down Expand Up @@ -259,12 +259,13 @@ if config_env() == :prod do
http: [
protocol_options: [
max_frame_size:
Application.get_env(:lightning, :max_dataclip_size_bytes),
# Not that if a request is more than 10x the max dataclip size, we cut
Application.get_env(:lightning, :max_dataclip_size_bytes, 10_000_000),
# Note that if a request is more than 10x the max dataclip size, we cut
# the connection immediately to prevent memory issues via the
# :max_skip_body_length setting.
max_skip_body_length:
Application.get_env(:lightning, :max_dataclip_size_bytes) * 10
Application.get_env(:lightning, :max_dataclip_size_bytes, 10_000_000) *
10
]
],
server: true
Expand Down
2 changes: 1 addition & 1 deletion mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ defmodule Lightning.MixProject do
def project do
[
app: :lightning,
version: "2.0.0-rc6",
version: "2.0.0-rc7",
elixir: "~> 1.15",
elixirc_paths: elixirc_paths(Mix.env()),
elixirc_options: [
Expand Down

0 comments on commit ebb17d2

Please sign in to comment.