m_component.getLogger().warn("Exception while invoking callback method", e.getCause()); m_component.getLogger().warn("Exception while trying to invoke callback method", e); props.put(key, resourceProperties.get(key).toString()); } else { m_component.getLogger().warn( "Custom resource property is overlapping with the default resource property for key: %s", key);
@SuppressWarnings("unchecked") @Override public Dictionary<String, Object> getProperties() { Event event = getService(); if (event != null) { Bundle bundle = (Bundle) event.getEvent(); if (m_propagateCallbackInstance != null && m_propagateCallbackMethod != null) { try { CallbackTypeDef callbackInfo = new CallbackTypeDef(Bundle.class, bundle); return (Dictionary<String, Object>) InvocationUtil.invokeCallbackMethod(m_propagateCallbackInstance, m_propagateCallbackMethod, callbackInfo.m_sigs, callbackInfo.m_args); } catch (InvocationTargetException e) { m_component.getLogger().warn("Exception while invoking callback method", e.getCause()); } catch (Throwable e) { m_component.getLogger().warn("Exception while trying to invoke callback method", e); } throw new IllegalStateException("Could not invoke callback"); } else { return ServiceUtil.toR6Dictionary(bundle.getHeaders()); } } else { throw new IllegalStateException("cannot find bundle"); } }
return (Dictionary<String, Object>) InvocationUtil.invokeCallbackMethod(m_propagateCallbackInstance, m_propagateCallbackMethod, callbackInfo.m_sigs, callbackInfo.m_args); } catch (InvocationTargetException e) { m_component.getLogger().warn("Exception while invoking callback method", e.getCause()); } catch (Throwable e) { m_component.getLogger().warn("Exception while trying to invoke callback method", e);
@Override public Object addingService(@SuppressWarnings("rawtypes") ServiceReference reference) { try { ServiceEventImpl event = new ServiceEventImpl(m_component, reference, null); if (obtainServiceBeforeInjecting()) { Object service = event.getEvent(); // will dereference the service object. if (service == null) { // service concurrently removed, ignore return null; } } return event; } catch (IllegalStateException e) { // most likely our bundle is being stopped. Only log an exception if our component is enabled. if (m_component.isActive()) { m_component.getLogger().warn("could not handle service dependency for component %s", e, m_component.getComponentDeclaration().getClassName()); } return null; } }
logger.warn("Failed to create configurable for configuration type %s!", e, configTypes != null ? Arrays.toString(configTypes) : null);
m_component.getLogger().warn("could not handle service dependency for component %s", e, m_component.getComponentDeclaration().getClassName());