gruf 2.2.1 → 2.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8527045d1d987962200fe9f93d95d510dc065e13
4
- data.tar.gz: d5d07f8f3b79194510fb4b7d923d1a7d25cc158a
3
+ metadata.gz: b0e7891457a5fc0c9540a5347060adb81d943c2f
4
+ data.tar.gz: b6f8e81ec7ad9fda50874fd0dfc34493dd2fabce
5
5
  SHA512:
6
- metadata.gz: 40a3edb5d90cb4229344312eab599f9524d3d3e154fafaa6867e8e5958395ff518346e724d13b386f88964840ed48f4dec31f8c58b078f2c48936f90461c65e8
7
- data.tar.gz: 504cce2f076685d662b45f5d6769f748528d1618a83d312f8cef461242936ff4519cbdb99a430eb0cf6613d166d8e70aa2af01f4bc0b29268b18db4c8cb0a2c9
6
+ metadata.gz: 7881d0383409066521a069f99d1a978c67c281a6142eef378e7204dcb394fd7d3e53d0a82453bc36097e611fada3daded6bc6c91a7697a7e924bcbbbef2f6a2f
7
+ data.tar.gz: 6748606577097d0b5bf6cec7c4afe6254b71f3abd39b40a3a3ca1dde6ac43f43cb592fe14c83e51158e1929f25cb4e442cf2b2afe00f759332fe404558fee6e5
@@ -2,6 +2,10 @@ Changelog for the gruf gem. This includes internal history before the gem was ma
2
2
 
3
3
  ### Pending release
4
4
 
5
+ ### 2.2.2
6
+
7
+ - Added ignore_methods option for RequestLogging interceptor [#45]
8
+
5
9
  ### 2.2.1
6
10
 
7
11
  - Now changes proc title once server is ready to process incoming requests [#44]
data/README.md CHANGED
@@ -341,6 +341,7 @@ It comes with a few more options as well:
341
341
  | log_parameters | If set to true, will log parameters in the response | `false` |
342
342
  | blacklist | An array of parameter key names to redact from logging, in path.to.key format | `[]` |
343
343
  | redacted_string | The string to use for redacted parameters. | `REDACTED` |
344
+ | ignore_methods | An array of method names to ignore from logging. E.g. `['namespace.health.check']` | `[]` |
344
345
 
345
346
  It's important to maintain a safe blacklist should you decide to log parameters; gruf does no
346
347
  parameter sanitization on its own. We also recommend blacklisting parameters that may contain
@@ -43,6 +43,8 @@ module Gruf
43
43
  # @return [String]
44
44
  #
45
45
  def call
46
+ return yield if options.fetch(:ignore_methods, []).include?(request.method_name)
47
+
46
48
  result = Gruf::Interceptors::Timer.time do
47
49
  yield
48
50
  end
@@ -14,5 +14,5 @@
14
14
  # OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
15
15
  #
16
16
  module Gruf
17
- VERSION = '2.2.1'.freeze
17
+ VERSION = '2.2.2'.freeze
18
18
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gruf
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.1
4
+ version: 2.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Shaun McCormick
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-03-14 00:00:00.000000000 Z
11
+ date: 2018-03-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler