Revision 9e2380de
Added by Christine Fouant over 7 years ago
lib/runcible/base.rb | ||
---|---|---|
1 |
# Copyright (c) 2012 Red Hat |
|
2 |
# |
|
3 |
# MIT License |
|
4 | 1 |
# |
5 | 2 |
# Permission is hereby granted, free of charge, to any person obtaining |
6 | 3 |
# a copy of this software and associated documentation files (the |
... | ... | |
82 | 79 |
response = get_response(client, path, *args) |
83 | 80 |
process_response(response) |
84 | 81 |
|
82 |
rescue RestClient::ResourceNotFound => e |
|
83 |
log_info |
|
84 |
raise e |
|
85 | 85 |
rescue => e |
86 | 86 |
log_exception |
87 | 87 |
raise e |
... | ... | |
213 | 213 |
end |
214 | 214 |
end |
215 | 215 |
|
216 |
def log_info |
|
217 |
if self.config[:logging][:info] |
|
218 |
log_message = generate_log_message |
|
219 |
self.config[:logging][:logger].info(log_message) |
|
220 |
end |
|
221 |
end |
|
222 |
|
|
216 | 223 |
def generate_log_message |
217 | 224 |
RestClient.log.join('\n') |
218 | 225 |
end |
Also available in: Unified diff
Fixes #10866 - changes 404 exceptions from error to info