This is an automated email from the ASF dual-hosted git repository.
pottlinger pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-tamaya.git
The following commit(s) were added to refs/heads/master by this push:
new 9bb527a TAMAYA-277: Fix warning
9bb527a is described below
commit 9bb527aec15a0a5fdbe2a33e5267ddd62e708a46
Author: Hugo Hirsch <[email protected]>
AuthorDate: Sun Apr 21 22:35:33 2019 +0200
TAMAYA-277: Fix warning
Use logger instead of dumping the stacktrace to System.err
---
.../main/java/org/apache/tamaya/core/internal/OSGIServiceLoader.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git
a/code/core/src/main/java/org/apache/tamaya/core/internal/OSGIServiceLoader.java
b/code/core/src/main/java/org/apache/tamaya/core/internal/OSGIServiceLoader.java
index 91367a7..48331c2 100644
---
a/code/core/src/main/java/org/apache/tamaya/core/internal/OSGIServiceLoader.java
+++
b/code/core/src/main/java/org/apache/tamaya/core/internal/OSGIServiceLoader.java
@@ -248,7 +248,7 @@ public class OSGIServiceLoader implements BundleListener {
LOG.fine("Creating Service...:" + serviceClass.getName());
return serviceClass.getConstructor().newInstance();
} catch (Exception ex) {
- ex.printStackTrace();
+ LOG.log(Level.SEVERE, "Error while creating service.", ex);
throw new IllegalStateException("Failed to createObject
service: " + serviceClass.getName(), ex);
}
}