promwrapgen

command module
v0.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 12, 2024 License: MIT Imports: 9 Imported by: 0

README

promwrapgen

promwrapgen wraps an interface or a struct and adds prometheus metrics such as success count, error count, total count and duration

THIS IS A WIP

TODO

  • Handle slice ... operator
  • Only work on targets passed not all interfaces in file
  • Pass method name and other method related information Total, Success and Error
  • Get list of targets not just one
  • Let users decided what metrics they want
  • Handle time package conflict
  • Some logic is stupid and slow but finish it first for prometheus metric only on interfaces and then refactor.
  • Add struct wrapping support?? What if struct methods are in multiple files???
  • Extract wrapping funtionality.
  • Enable users to extend wrapping functionallity to add custom logic to their interfaces
  • Custom metrics?
  • Refactor and make it more clever.

Usage


Testing

TODO

TODO

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
examples
readme_usage
Code generated by github.com/itzloop/promwrapgen.
Code generated by github.com/itzloop/promwrapgen.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL