profile
viewpoint
If you are wondering where the data of this site comes from, please visit https://api.github.com/users/akoutmos/events. GitMemory does not store any data, but only uses NGINX to cache data for a period of time. The idea behind GitMemory is simply to give users a better reading experience.
Alexander Koutmos akoutmos Maybe here, maybe there https://akoutmos.com/ Primarily working with Elixir, Phoenix, Vue and good ol' JS these days.

akoutmos/doctor 103

Ensure that your Elixir project documentation is healthy

akoutmos/docker_elixir_19_release 10

Companion code for https://akoutmos.com/post/multipart-docker-and-elixir-1.9-releases/

akoutmos/elixir_popularity 10

Companion code for https://akoutmos.com/post/broadway-rabbitmq-and-the-rise-of-elixir/

akoutmos/book_store 5

Companion code for https://akoutmos.com/post/actor-model-genserver-app/

akoutmos/elixir_monitoring_prom 4

Companion code for https://akoutmos.com/post/prometheus-postgis-and-phoenix/

akoutmos/auto_finder 2

Companion code for https://akoutmos.com/post/elixir-logging-loki/

akoutmos/absinthe 0

The GraphQL toolkit for Elixir

akoutmos/amqp 0

Idiomatic Elixir client for RabbitMQ

akoutmos/angular-bing-maps 0

Set of angular directives to wrap the Bing Maps JS API

issue commentelixir-gettext/gettext

New mix task to check for missing translations

Closing this issue given that the PR has been merged. Thanks for the assistance everyone and the speedy reviews!

akoutmos

comment created time in a day

issue closedelixir-gettext/gettext

New mix task to check for missing translations

Opening up this issue to gauge interest from the maintainers in a new mix task for gettext that will check to see if there are any missing translations. Something like mix format --check-formatted but for translations. This can be useful in CI to ensure that the PO files are up to date prior to deployment. I am currently doing this with adhoc shell scripts...but I think this would be a useful tool to have directly in gettext.

If there is interest in this, I can put together an initial implementation :).

As always, thanks for all the effort everyone has put into gettext!! Really appreciate it!!

closed time in a day

akoutmos

pull request commentelixir-gettext/gettext

WIP: Added --check-unextracted to extract mix task

Finished the last bit of test clean up so all set on my end :).

akoutmos

comment created time in 2 days

push eventakoutmos/gettext

Alex Koutmos

commit sha f46632a6b9cd2988252d1dd6d01d2fb56c3e9224

Adjusted tests and supressed compiler warning for test modules

view details

push time in 2 days

pull request commentelixir-gettext/gettext

WIP: Added --check-unextracted to extract mix task

I guess --check-unextracted might be a bit misleading now that I think about it. I'd be ok with --check-up-to-date or perhaps --check-current for something shorter?

akoutmos

comment created time in 2 days

pull request commentelixir-gettext/gettext

WIP: Added --check-unextracted to extract mix task

I thought about this as well yesterday...and the conclusion that I came to was that while there are no new translations and the existing translations either changed lines/files, the POT file is still inaccurate with regards to the current state of the codebase. Hence why I made the PR the way that I did.

akoutmos

comment created time in 2 days

PR opened elixir-gettext/gettext

WIP: Added --check-unextracted to extract mix task

This PR addresses #286.

While still a work in progress (mostly test clean up that I want to do), I figured I would throw up the PR to get eyes on it sooner rather than later in case the approach I took was off.

Thanks in advance for reviewing the PR :)

+140 -14

0 comment

2 changed files

pr created time in 2 days

push eventakoutmos/gettext

Alex Koutmos

commit sha c52cbaaae39597968ddfc34b96d287b423cf07d8

Initial implementation of gettext --check-unextracted

view details

push time in 2 days

issue commentbeam-telemetry/telemetry_metrics_prometheus_core

Possible DoS while prometheus non scraping?

I did something like this in PromEx to solve this exact problem: https://github.com/akoutmos/prom_ex/blob/master/lib/prom_ex/ets_cron_flusher.ex

I can pull some of that work directly into this library if you think it would add value?

m1ome

comment created time in 3 days

issue commentelixir-gettext/gettext

New mix task to check for missing translations

Will do! Thanks :)

akoutmos

comment created time in 4 days

fork akoutmos/gettext

Internationalization and localization support for Elixir.

https://hexdocs.pm/gettext

fork in 5 days

issue commentelixir-gettext/gettext

New mix task to check for missing translations

Oooo. I like --check-unextracted. I'll put something together in the next few days and open up a PR :).

akoutmos

comment created time in 6 days

issue commentelixir-gettext/gettext

New mix task to check for missing translations

You can do something like follows to get information on whether a PO file is missing any translations:

$ msgfmt --statistics priv/gettext/en/LC_MESSAGES/default.po 

0 translated messages, 269 untranslated messages.

The check that I envision would be more about the creation of the POT file and would check to see if after adding new gettext "Some new text" statements in the code base, that an up to date POT file has been generated. Perhaps this would be a flag on mix gettext.extract? Something like mix gettext.extract --check-template-file?

akoutmos

comment created time in 6 days

issue openedelixir-gettext/gettext

New mix task to check for missing translations

Opening up this issue to gauge interest from the maintainers in a new mix task for gettext that will check to see if there are any missing translations. Something like mix format --check-formatted but for translations. This can be useful in CI to ensure that the PO files are up to date prior to deployment. I am currently doing this with adhoc shell scripts...but I think this would be a useful tool to have directly in gettext.

If there is interest in this, I can put together an initial implementation :).

As always, thanks for all the effort everyone has put into gettext!! Really appreciate it!!

created time in 6 days

release akoutmos/prom_ex

1.4.1

released time in 11 days

created tagakoutmos/prom_ex

tag1.4.1

An Elixir Prometheus metrics collection library built on top of Telemetry with accompanying Grafana dashboards

created time in 11 days

push eventakoutmos/prom_ex

Alex Koutmos

commit sha 8bcbb162dbd5cd1475941b296463b88f6c1803ba

Prepping for 1.4.1 release

view details

push time in 11 days

issue closedakoutmos/prom_ex

[BUG] PlugRouter plugin will fail to handle request not handled by a Plug.Router

Describe the bug A request not handled by a Plug.Router module won't have data under %Conn{private: %{plug_route: ...}} this will cause an error on the path/1 function

https://github.com/akoutmos/prom_ex/blob/1.4.0/lib/prom_ex/plugins/plug_router.ex#L211-L214

Error:

Handler {TelemetryMetricsPrometheus.Core.EventHandler, #PID<0.460.0>,
[:my_app, :prom_ex, :plug_router, :http, :request, :duration, :milliseconds]} has failed and has been detached.
Class=:error
Reason={:badkey, :plug_route, %{}}
Stacktrace=[
 {PromEx.Plugins.PlugRouter, :path, 1, [file: 'lib/prom_ex/plugins/plug_router.ex', line: 212]},
 {PromEx.Plugins.PlugRouter, :get_tags, 1, [file: 'lib/prom_ex/plugins/plug_router.ex', line: 220]},
 {TelemetryMetricsPrometheus.Core.Distribution, :handle_event, 4, [file: 'lib/core/distribution.ex', line: 72]},
 {:telemetry, :\"-execute/3-fun-0-\", 4, [file: '/Users/some_user/projects/my_app/deps/telemetry/src/telemetry.erl', line: 135]},
 {:lists, :foreach, 2, [file: 'lists.erl', line: 1342]},
 {:telemetry, :\"-execute/3-fun-0-\", 4, [ file: '/Users/some_user/projects/my_app/deps/telemetry/src/telemetry.erl',  line: 135]},
 {:lists, :foreach, 2, [file: 'lists.erl', line: 1342]}, {Plug.Telemetry, :\"-call/2-fun-0-\", 4, [file: 'lib/plug/telemetry.ex', line: 76]}
]

To Reproduce Steps to reproduce the behavior:

Add a plug that responds to a path that won't be resolved by Plug.Router, e.g:

Plug:

defmodule MyApp.HealthCheckPlug do
  @moduledoc false

  import Plug.Conn

  def init(opts), do: opts

  def call(%Plug.Conn{request_path: "/health"} = conn, _opts) do
    {:ok, version} = :application.get_key(:my_app, :vsn)
    body = %{version: List.to_string(version)}

    send_resp(conn, 200, Jason.encode!(body))
    |> halt()
  end

  def call(conn, _opts), do: conn
end

Router:

defmodule MyApp.Router do
  use Plug.Router

  plug MyApp.HealthCheckPlug

  plug :match
  plug :dispatch

  get "/hello" do
    send_resp(conn, 200, "world")
  end

  match _ do
    send_resp(conn, 404, "oops")
  end
end

Expected behavior The PlugRouter plug should not raise an error with those requests since, doing so causes the :telemetry handler to dettach

One should be able to either ignore the request using the :ignored_routes option, or handle the request and probably setting the path tag to some default, since we don't have the route info, and using the request_path from conn as a tag is too risky because of the unknown cardinality

closed time in 13 days

emoragaf

issue commentakoutmos/prom_ex

[BUG] PlugRouter plugin will fail to handle request not handled by a Plug.Router

Thanks for the fix! A new release will be cut in the next couple days :).

emoragaf

comment created time in 13 days

push eventakoutmos/prom_ex

Eduardo Moraga

commit sha e4343d0ed468fb7e853259c6706997f566369d72

Fix PlugRouter to handle request not resolved by Plug.Router (#96) * handles request without conn.private.plug_route info, sets path tag as Unknown, also allows ignore the request using conn.request_path * dialyzer fix, switch when for case

view details

push time in 13 days

PR merged akoutmos/prom_ex

Fix PlugRouter to handle request not resolved by Plug.Router

Change description

handles request without conn.private.plug_route info

  • sets path tag as Unknown for those cases
  • allows ignoring a request by comparing the :ignore_routes option values against the request conn.request_path when no conn.private.plug_route is present

What problem does this solve?

Issue number: #95

Example usage

Plugin usage continues to be the same

Checklist

  • [ ] I have added unit tests to cover my changes.
  • [ ] I have added documentation to cover my changes.
  • [ ] My changes have passed unit tests and have been tested E2E in an example project.
+25 -7

1 comment

1 changed file

emoragaf

pr closed time in 13 days

startedderek-zhou/tantivy-erl

started time in 14 days

delete branch akoutmos/prom_ex

delete branch : default_selected_interval

delete time in 14 days

push eventakoutmos/prom_ex

Alexander Koutmos

commit sha e74e6e5fcbe5bee657106a54096dfd2368a06e1c

Added ability to configure default selected time interval (#97)

view details

push time in 14 days

create barnchakoutmos/prom_ex

branch : default_selected_interval

created branch time in 14 days

created tagakoutmos/prom_ex

tag1.4.0

An Elixir Prometheus metrics collection library built on top of Telemetry with accompanying Grafana dashboards

created time in 17 days

release akoutmos/prom_ex

1.4.0

released time in 17 days

push eventakoutmos/prom_ex

Alex Koutmos

commit sha b412af5644bdd67ba525e0aa8959f6457380f6a5

Disabling PlugCowboy Plug.Router resolution until a better way can be found

view details

push time in 17 days