Commit 7b792451 authored by Loïc Albertin's avatar Loïc Albertin
Browse files

#1032: Refactor JOnAS Services APIs

  * extracted naming API
parent f5189f18
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<artifactId>jonas-apis-services</artifactId>
<groupId>org.ow2.jonas</groupId>
<version>6.0.0-M1-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>jonas-apis-services-naming</artifactId>
<name>JOnAS :: APIs :: Services :: Naming</name>
<packaging>bundle</packaging>
<dependencies>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-apis-services-core</artifactId>
<version>${project.version}</version>
</dependency>
</dependencies>
</project>
......@@ -30,8 +30,9 @@ import javax.naming.NamingException;
/**
* A <code>JComponentContextFactory</code> is a factory for JOnAS Component's Context.
* @see org.ow2.jonas.lib.naming.ComponentContext
*
* @author Guillaume Sauthier
* @see org.ow2.jonas.lib.naming.ComponentContext
*/
public interface JComponentContextFactory {
......@@ -47,34 +48,42 @@ public interface JComponentContextFactory {
* </ul>
*
* @param id the Context ID.
*
* @return Naming {@link Context} for component environment
* @throws NamingException If exception encountered when creating namespace.
*
* @throws NamingException If exception encountered when creating namespace.
*/
Context createComponentContext(String id) throws NamingException;
/**
* Create {@link Context} for component environments. The returned context
* is a Java EE Component Context.
* @param id the Context ID.
*
* @param id the Context ID.
* @param moduleContext the application context shared by all the components
* in a module
* @param appContext the application context shared by all the applications
* in a module
* @param appContext the application context shared by all the applications
*
* @return Naming {@link Context} for component environment
*
* @throws NamingException If exception encountered when creating namespace.
*/
Context createComponentContext(final String id, final Context moduleContext, final Context appContext) throws NamingException;
/**
* Add the given {@link JComponentContextFactoryDelegate} to this NamingManager instance.
*
* @param extension Added delegate
*
* @throws NamingException if the delegates is not added.
*/
void addDelegate(JComponentContextFactoryDelegate extension) throws NamingException;
/**
* Remove the given {@link JComponentContextFactoryDelegate} from this NamingManager instance.
*
* @param extension Removed delegate
*
* @throws NamingException if the delegates is not removed.
*/
void removeDelegate(JComponentContextFactoryDelegate extension) throws NamingException;
......
......@@ -19,6 +19,7 @@
<module>registry</module>
<module>depmonitor</module>
<module>configuration</module>
<module>naming</module>
</modules>
......
......@@ -82,6 +82,12 @@
<artifactId>jonas-services-api</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-apis-services-naming</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-management-javaee</artifactId>
......
......@@ -39,7 +39,7 @@
<dependencies>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-services-api</artifactId>
<artifactId>jonas-apis-services-naming</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
......
......@@ -33,3 +33,5 @@ DynamicImport-Package org.ow2.carol.jndi.intercept.spi, \
org.ow2.carol.jndi.spi, \
com.sun.jndi.url.rmi
-exportcontents org.ow2.jonas.naming
Embed-Dependency jonas-apis-services-naming;inline=true
\ No newline at end of file
......@@ -51,6 +51,12 @@
<artifactId>jonas-services-api</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-apis-services-naming</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-ejb-container</artifactId>
......
......@@ -60,6 +60,12 @@
<artifactId>jonas-apis-services-registry</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-apis-services-naming</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-apis-services-configuration</artifactId>
......
......@@ -40,6 +40,12 @@
<artifactId>jonas-apis-services-jmx</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-apis-services-naming</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-commons</artifactId>
......
......@@ -52,6 +52,12 @@
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-apis-services-naming</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-management-javaee</artifactId>
......
......@@ -57,6 +57,13 @@
<artifactId>log-api</artifactId>
</dependency>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-apis-services-naming</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-security-core</artifactId>
......
......@@ -36,7 +36,12 @@
<name>JOnAS :: Services :: Web Container :: Tomcat :: 7.0.x :: Core</name>
<dependencies>
<dependency>
<groupId>org.ow2.jonas</groupId>
<artifactId>jonas-apis-services-naming</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.ow2.spec.ee</groupId>
<artifactId>ow2-servlet-3.0-spec</artifactId>
......
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