Skip to content

Commit

Permalink
Revert FELIX-6173
Browse files Browse the repository at this point in the history
git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@1865692 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information
cziegeler committed Aug 22, 2019
1 parent 3cc9411 commit 1dc9bb5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 11 deletions.
7 changes: 1 addition & 6 deletions log/src/main/java/org/apache/felix/log/Activator.java
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,10 @@
import java.util.Dictionary;
import java.util.Hashtable;

import org.osgi.framework.Bundle;
import org.osgi.framework.BundleActivator;
import org.osgi.framework.BundleContext;
import org.osgi.framework.Constants;
import org.osgi.framework.ServiceRegistration;
import org.osgi.framework.startlevel.FrameworkStartLevel;
import org.osgi.service.log.LogLevel;
import org.osgi.service.log.LogReaderService;
import org.osgi.service.log.LogService;
Expand Down Expand Up @@ -134,11 +132,8 @@ private static String getDefaultLogLevel(final BundleContext context) {
@Override
public void start(final BundleContext context) throws Exception
{
// get framework start level
final Bundle systemBundle = context.getBundle(Constants.SYSTEM_BUNDLE_ID);

// create the log instance
m_log = new Log(systemBundle.adapt(FrameworkStartLevel.class), getMaxSize(context), getStoreDebug(context));
m_log = new Log(getMaxSize(context), getStoreDebug(context));
// create the LoggerAdmin instance
m_loggerAdmin = new LoggerAdminImpl(getDefaultLogLevel(context), m_log);

Expand Down
6 changes: 1 addition & 5 deletions log/src/main/java/org/apache/felix/log/Log.java
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
import org.osgi.framework.ServiceEvent;
import org.osgi.framework.ServiceListener;
import org.osgi.framework.ServiceReference;
import org.osgi.framework.startlevel.FrameworkStartLevel;
import org.osgi.service.log.LogEntry;
import org.osgi.service.log.LogLevel;
import org.osgi.service.log.LogListener;
Expand All @@ -54,17 +53,14 @@ final class Log implements BundleListener, FrameworkListener, ServiceListener
private final int m_maxSize;
/** Whether or not to store debug messages. */
private final boolean m_storeDebug;
/** Framework start level. */
private final FrameworkStartLevel m_startLevel;

/**
* Create a new instance.
* @param maxSize the maximum size for the log
* @param storeDebug whether or not to store debug messages
*/
Log(final FrameworkStartLevel startLevel, final int maxSize, final boolean storeDebug)
Log(final int maxSize, final boolean storeDebug)
{
this.m_startLevel = startLevel;
this.m_maxSize = maxSize;
this.m_storeDebug = storeDebug;
}
Expand Down

0 comments on commit 1dc9bb5

Please sign in to comment.