Giter VIP home page Giter VIP logo

Comments (6)

deadtrickster avatar deadtrickster commented on August 31, 2024

I believe we figured this out on ElixirForum.
For the history: process collector should be added to dependencies and registered via prometheus_registry:register_collector or Prometheus.Registry.register_collector.

from prometheus_process_collector.

hopewise avatar hopewise commented on August 31, 2024

Yes, I already did so like on ElixirForum as:
Prometheus.Registry.register_collector(:prometheus_process_collector)
but I got the error above, is this library supported on debian? what OS was it tested on?

from prometheus_process_collector.

deadtrickster avatar deadtrickster commented on August 31, 2024

Ubuntu it should really work on any Linux. can you show your mix,exs?

from prometheus_process_collector.

hopewise avatar hopewise commented on August 31, 2024

Here it is:

defmodule Trackware.Mixfile do
  use Mix.Project

  def project do
    [app: :trackware,
     version: "0.0.1",
     elixir: "~> 1.0",
     elixirc_paths: elixirc_paths(Mix.env),
     compilers: [:phoenix, :gettext] ++ Mix.compilers,
     build_embedded: Mix.env == :prod,
     start_permanent: Mix.env == :prod,
     aliases: aliases,
     deps: deps]
  end

  # Configuration for the OTP application.
  #
  # Type `mix help compile.app` for more information.
  def application do
    [mod: {Trackware, []},
     applications: [:phoenix, :phoenix_html, :cowboy, :logger, :gettext,
                    :phoenix_ecto, :postgrex, :ex_aws, :httpoison, :phoenix_pubsub, :joken, :httpoison, :cqex, :exrm, :edeliver,
                    :prometheus_ex, :prometheus_ecto, :prometheus_phoenix, :prometheus_plugs, :prometheus_process_collector]]
  end

  # Specifies which paths to compile per environment.
  defp elixirc_paths(:test), do: ["lib", "web", "test/support"]
  defp elixirc_paths(_),     do: ["lib", "web"]

  # Specifies your project dependencies.
  #
  # Type `mix help deps` for examples and options.
  defp deps do
    [{:phoenix, "~> 1.2.0"},
     {:phoenix_pubsub, "~> 1.0"},
     {:phoenix_ecto, "~> 3.0-rc"},
     {:postgrex, ">= 0.0.0"},
     {:phoenix_html, "~> 2.6"},
     {:phoenix_live_reload, "~> 1.0", only: :dev},
     {:gettext, "~> 0.9"},
     {:cowboy, "~> 1.0"},
     {:ex_aws, "~> 0.4.10"},
     {:poison, "~> 1.2"},
     {:httpoison, "~> 0.9.0"},
     {:joken, "~> 1.2"},
     {:edeliver, "~> 1.4.0"},
     {:exrm, "~> 1.0.3"},
     {:cqex, "~> 0.2.0"},
     {:cqerl, github: "matehat/cqerl"},
     {:uuid, "~> 1.1", override: true},
     {:prometheus_ex, "~> 1.0"},
     {:prometheus_ecto, "~> 1.0"},
     {:prometheus_phoenix, "~> 1.0"},
     {:prometheus_plugs, "~> 1.0"},
     {:prometheus_process_collector, "~> 1.0"},
     {:remote_monitor, "~> 0.1.0", only: :dev}]
  end

  # Aliases are shortcut or tasks specific to the current project.
  # For example, to create, migrate and run the seeds file at once:
  #
  #     $ mix ecto.setup
  #
  # See the documentation for `Mix` for more info on aliases.
  defp aliases do
    ["ecto.setup": ["ecto.create", "ecto.migrate", "run priv/repo/seeds.exs"],
     "ecto.reset": ["ecto.drop", "ecto.setup"]]
  end
end

from prometheus_process_collector.

deadtrickster avatar deadtrickster commented on August 31, 2024

So you have prometheus_process_collector in deps and applications... and it's still not loaded? Something really strange happends (OS-independent btw).

from prometheus_process_collector.

hopewise avatar hopewise commented on August 31, 2024

here is what in my r _build/dev/lib/

➜ prometheus_process_collector git:(master) ✗ pwd
/Users/samir/Documents/projects/elixir/_build/dev/lib/prometheus_process_collector

➜ prometheus_process_collector git:(master) ✗ ls
ebin mix.rebar.config

I will update deps, thanks

from prometheus_process_collector.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.