Commit a86ce5ef authored by Nicolas Tachker's avatar Nicolas Tachker
Browse files

JORAM-244: Update OSGi, felix and gogo version.

parent e3ee6530
......@@ -51,7 +51,7 @@
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi</artifactId>
<artifactId>org.osgi.core</artifactId>
</dependency>
</dependencies>
</project>
\ No newline at end of file
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -88,7 +88,7 @@ public class A3ManagedService extends CommonService implements ManagedService {
registration = bundleContext.registerService(
ManagedService.class.getName(),
this,
props);
(Dictionary)props);
}
protected void doStop() {
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -98,7 +98,7 @@ public class CommonService {
bundleContext.registerService(
ServerDesc.class.getName(),
serverDesc,
props);
(Dictionary)props);
if (logmon.isLoggable(BasicLevel.DEBUG))
logmon.log(BasicLevel.DEBUG, "CommonService ServerDesc register: " + serverDesc);
}
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -89,7 +89,7 @@ public class JoramManagedService extends CommonService implements ManagedService
registration = bundleContext.registerService(
ManagedService.class.getName(),
this,
props);
(Dictionary)props);
}
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2013 ScalAgent Distributed Technologies
* Copyright (C) 2013 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -22,6 +22,7 @@
*/
package fr.dyade.aaa.jndi2.osgi;
import java.util.Dictionary;
import java.util.Properties;
import org.objectweb.util.monolog.api.BasicLevel;
......@@ -54,7 +55,7 @@ public class Activator implements BundleActivator {
registration = context.registerService(
javax.naming.spi.ObjectFactory.class.getName(),
new scnURLContextFactory(),
props);
(Dictionary)props);
}
public void stop(BundleContext context) throws Exception {
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2004 - 2012 ScalAgent Distributed Technologies
* Copyright (C) 2004 - 2016 ScalAgent Distributed Technologies
* Copyright (C) 2004 - 2006 Bull SA
*
* This library is free software; you can redistribute it and/or
......@@ -27,6 +27,7 @@ package org.objectweb.joram.client.connector;
import java.io.FileNotFoundException;
import java.net.ConnectException;
import java.util.Date;
import java.util.Dictionary;
import java.util.Properties;
import javax.jms.Connection;
......@@ -510,7 +511,7 @@ public final class JoramAdapter extends JoramResourceAdapter implements JoramAda
registration = Activator.context.registerService(
AdminItf.class.getName(),
wrapper,
props);
(Dictionary) props);
if (logger.isLoggable(BasicLevel.DEBUG))
logger.log(BasicLevel.DEBUG, "Bundle context " + Activator.context + " registerService AdminWrapper " + getName());
}
......
/*
* Copyright (C) 2009 - 2013 ScalAgent Distributed Technologies
* Copyright (C) 2009 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -21,11 +21,15 @@
*/
package org.objectweb.joram.client.osgi;
import javax.naming.spi.ObjectFactory;
import org.objectweb.joram.client.jms.admin.AdminModule;
import org.objectweb.joram.client.jms.admin.JoramAdminConnect;
import org.objectweb.util.monolog.api.BasicLevel;
import org.objectweb.util.monolog.api.Logger;
import org.osgi.framework.BundleActivator;
import org.osgi.framework.BundleContext;
import org.osgi.framework.ServiceReference;
import fr.dyade.aaa.common.Debug;
......@@ -38,6 +42,8 @@ public class Activator implements BundleActivator {
public static final Logger logmon = Debug.getLogger(Activator.class.getName());
public static final String ADMIN_XML_PATH = "joram.adminXML";
private JoramAdminConnect joramAdminConnect;
private DestinationMSF destMSF = null;
private UserMSF userMSF = null;
......@@ -84,6 +90,23 @@ public class Activator implements BundleActivator {
sfq = new ServiceFtpQueue(context);
salq = new ServiceAliasQueue(context);
sadmin = new ServiceAdmin(context);
ClassLoader myClassLoader = getClass().getClassLoader();
ClassLoader originalContextClassLoader = Thread.currentThread().getContextClassLoader();
try {
Thread.currentThread().setContextClassLoader(myClassLoader);
String adminXmlFile = context.getProperty(ADMIN_XML_PATH);
if (adminXmlFile != null) {
ServiceReference<ObjectFactory> ref = context.getServiceReference(javax.naming.spi.ObjectFactory.class);
if (ref == null) {
if (logmon.isLoggable(BasicLevel.ERROR))
logmon.log(BasicLevel.ERROR, "No ServiceReference for javax.naming.spi.ObjectFactory, start jndi client bundle to use jndi.");
}
AdminModule.executeXMLAdmin(adminXmlFile);
}
} finally {
Thread.currentThread().setContextClassLoader(originalContextClassLoader);
}
}
/* (non-Javadoc)
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -104,7 +104,7 @@ public class ConnectionFactoryMSF implements ManagedServiceFactory {
registration = this.bundleContext.registerService(
ManagedServiceFactory.class.getName(),
this,
props);
(Dictionary)props);
cnxFactories = new HashMap<String, AbstractConnectionFactory>();
jndiHelper = new JndiHelper();
jndiNames = new HashMap<String, String>();
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -127,7 +127,7 @@ public class DestinationMSF implements ManagedServiceFactory {
registration = this.bundleContext.registerService(
ManagedServiceFactory.class.getName(),
this,
props);
(Dictionary)props);
destinations = new HashMap<String, Destination>();
jndiHelper = new JndiHelper();
jndiNames = new HashMap<String, String>();
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -98,7 +98,7 @@ public class ServiceAcquisitionQueue extends ServiceDestination implements Manag
registration = bundleContext.registerService(
ManagedServiceFactory.class.getName(),
this,
props);
(Dictionary)props);
}
public void doStop() {
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -98,7 +98,7 @@ public class ServiceAcquisitionTopic extends ServiceDestination implements Manag
registration = bundleContext.registerService(
ManagedServiceFactory.class.getName(),
this,
props);
(Dictionary)props);
}
public void doStop() {
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2013 ScalAgent Distributed Technologies
* Copyright (C) 2013 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -116,7 +116,7 @@ public class ServiceAdmin implements ManagedServiceFactory {
registration = this.bundleContext.registerService(
ManagedServiceFactory.class.getName(),
this,
props);
(Dictionary)props);
wrappers = new HashMap<String, AdminItf>();
connections = new HashMap<String, Connection>();
}
......@@ -232,7 +232,7 @@ public class ServiceAdmin implements ManagedServiceFactory {
registration = bundleContext.registerService(
AdminItf.class.getName(),
wrapper,
props);
(Dictionary)props);
if (logmon.isLoggable(BasicLevel.DEBUG))
logmon.log(BasicLevel.DEBUG, "doUpdated registration = " + registration);
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -94,7 +94,7 @@ public class ServiceAliasQueue extends ServiceDestination implements ManagedServ
registration = bundleContext.registerService(
ManagedServiceFactory.class.getName(),
this,
props);
(Dictionary)props);
}
public void doStop() {
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 - 2013 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -103,7 +103,7 @@ public class ServiceConnectionFactory implements ManagedServiceFactory {
registration = this.bundleContext.registerService(
ManagedServiceFactory.class.getName(),
this,
props);
(Dictionary)props);
cnxFactories = new HashMap<String, AbstractConnectionFactory>();
jndiHelper = new JndiHelper();
jndiNames = new HashMap<String, String>();
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 - 2013 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -303,12 +303,12 @@ public abstract class ServiceDestination {
reg = bundleContext.registerService(
javax.jms.Queue.class.getName(),
dest,
props);
(Dictionary)props);
else
reg = bundleContext.registerService(
javax.jms.Topic.class.getName(),
dest,
props);
(Dictionary)props);
registrations.put(pid, reg);
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -97,7 +97,7 @@ public class ServiceDistributionQueue extends ServiceDestination implements Mana
registration = bundleContext.registerService(
ManagedServiceFactory.class.getName(),
this,
props);
(Dictionary)props);
}
public void doStop() {
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -97,7 +97,7 @@ public class ServiceDistributionTopic extends ServiceDestination implements Mana
registration = bundleContext.registerService(
ManagedServiceFactory.class.getName(),
this,
props);
(Dictionary)props);
}
public void doStop() {
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -97,7 +97,7 @@ public class ServiceFtpQueue extends ServiceDestination implements ManagedServic
registration = bundleContext.registerService(
ManagedServiceFactory.class.getName(),
this,
props);
(Dictionary)props);
}
public void doStop() {
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -93,7 +93,7 @@ public class ServiceQueue extends ServiceDestination implements ManagedServiceFa
registration = bundleContext.registerService(
ManagedServiceFactory.class.getName(),
this,
props);
(Dictionary)props);
}
public void doStop() {
......
/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2012 ScalAgent Distributed Technologies
* Copyright (C) 2012 - 2016 ScalAgent Distributed Technologies
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -94,7 +94,7 @@ public class ServiceSchedulerQueue extends ServiceDestination implements Managed
registration = bundleContext.registerService(
ManagedServiceFactory.class.getName(),
this,
props);
(Dictionary)props);
}
public void doStop() {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment