Author: norman
Date: Wed Jun 29 11:33:01 2011
New Revision: 1141052

URL: http://svn.apache.org/viewvc?rev=1141052&view=rev
Log:
Add OSGI support for LMTPServer, IMAPServer, POP3Server, SMTPServer. See 
JAMES-835

Added:
    james/server/trunk/imapserver/src/main/resources/META-INF/
    james/server/trunk/imapserver/src/main/resources/META-INF/spring/
    
james/server/trunk/imapserver/src/main/resources/META-INF/spring/imapserver-context.xml
      - copied unchanged from r1141048, 
james/server/trunk/dnsservice-dnsjava/src/main/resources/META-INF/spring/imapserver-context.xml
    
james/server/trunk/imapserver/src/main/resources/META-INF/spring/imapserver-osgi.xml
      - copied unchanged from r1141048, 
james/server/trunk/dnsservice-dnsjava/src/main/resources/META-INF/spring/imapserver-osgi.xml
    james/server/trunk/lmtpserver/src/main/resources/
    james/server/trunk/lmtpserver/src/main/resources/META-INF/
    james/server/trunk/lmtpserver/src/main/resources/META-INF/spring/
    
james/server/trunk/lmtpserver/src/main/resources/META-INF/spring/lmtpserver-context.xml
    
james/server/trunk/lmtpserver/src/main/resources/META-INF/spring/lmtpserver-osgi.xml
    james/server/trunk/pop3server/src/main/resources/META-INF/
    james/server/trunk/pop3server/src/main/resources/META-INF/spring/
    
james/server/trunk/pop3server/src/main/resources/META-INF/spring/pop3server-context.xml
    
james/server/trunk/pop3server/src/main/resources/META-INF/spring/pop3server-osgi.xml
    james/server/trunk/smtpserver/src/main/resources/META-INF/
    james/server/trunk/smtpserver/src/main/resources/META-INF/spring/
    
james/server/trunk/smtpserver/src/main/resources/META-INF/spring/smtpserver-context.xml
      - copied unchanged from r1141048, 
james/server/trunk/dnsservice-dnsjava/src/main/resources/META-INF/spring/smtpserver-context.xml
    
james/server/trunk/smtpserver/src/main/resources/META-INF/spring/smtpserver-osgi.xml
      - copied, changed from r1141048, 
james/server/trunk/dnsservice-dnsjava/src/main/resources/META-INF/spring/smtpserver-osgi.xml
Removed:
    
james/server/trunk/dnsservice-dnsjava/src/main/resources/META-INF/spring/imapserver-context.xml
    
james/server/trunk/dnsservice-dnsjava/src/main/resources/META-INF/spring/imapserver-osgi.xml
    
james/server/trunk/dnsservice-dnsjava/src/main/resources/META-INF/spring/pop3server-context.xml
    
james/server/trunk/dnsservice-dnsjava/src/main/resources/META-INF/spring/pop3server-osgi.xml
    
james/server/trunk/dnsservice-dnsjava/src/main/resources/META-INF/spring/smtpserver-context.xml
    
james/server/trunk/dnsservice-dnsjava/src/main/resources/META-INF/spring/smtpserver-osgi.xml
Modified:
    james/server/trunk/dnsservice-dnsjava/pom.xml
    james/server/trunk/imapserver/pom.xml
    james/server/trunk/lmtpserver/pom.xml
    james/server/trunk/pop3server/pom.xml
    james/server/trunk/smtpserver/pom.xml

Modified: james/server/trunk/dnsservice-dnsjava/pom.xml
URL: 
http://svn.apache.org/viewvc/james/server/trunk/dnsservice-dnsjava/pom.xml?rev=1141052&r1=1141051&r2=1141052&view=diff
==============================================================================
--- james/server/trunk/dnsservice-dnsjava/pom.xml (original)
+++ james/server/trunk/dnsservice-dnsjava/pom.xml Wed Jun 29 11:33:01 2011
@@ -30,7 +30,7 @@
   <properties>
       <!-- OSGI stuff -->
     <james.osgi.export>
-      org.apache.james.*
+      org.apache.james.dnsservice.*
     </james.osgi.export>
     <james.osgi.import>
       *

Modified: james/server/trunk/imapserver/pom.xml
URL: 
http://svn.apache.org/viewvc/james/server/trunk/imapserver/pom.xml?rev=1141052&r1=1141051&r2=1141052&view=diff
==============================================================================
--- james/server/trunk/imapserver/pom.xml (original)
+++ james/server/trunk/imapserver/pom.xml Wed Jun 29 11:33:01 2011
@@ -27,6 +27,16 @@
   <groupId>org.apache.james</groupId>
   <artifactId>james-server-imapserver</artifactId>
   <name>Apache James Server IMAP</name>
+  <properties>
+      <!-- OSGI stuff -->
+    <james.osgi.export>
+      org.apache.james.imapserver.*
+    </james.osgi.export>
+    <james.osgi.import>
+      *
+    </james.osgi.import>
+  </properties> 
+  
   <dependencies>
    <dependency>
       <groupId>org.apache.james</groupId>

Modified: james/server/trunk/lmtpserver/pom.xml
URL: 
http://svn.apache.org/viewvc/james/server/trunk/lmtpserver/pom.xml?rev=1141052&r1=1141051&r2=1141052&view=diff
==============================================================================
--- james/server/trunk/lmtpserver/pom.xml (original)
+++ james/server/trunk/lmtpserver/pom.xml Wed Jun 29 11:33:01 2011
@@ -27,6 +27,20 @@
   <groupId>org.apache.james</groupId>
   <artifactId>james-server-lmtpserver</artifactId>
   <name>Apache James Server LMTP</name>
+  <properties>
+      <!-- OSGI stuff -->
+    <james.osgi.export>
+      org.apache.james.lmtpserver.*
+    </james.osgi.export>
+    <james.osgi.import>
+      *
+    </james.osgi.import>
+    <!-- Allow dynamic imports because the user is allowed to add handlers and 
hooks -->
+    <james.osgi.dynamic>
+      *
+    </james.osgi.dynamic>
+  </properties> 
+  
   <dependencies>
     <dependency>
       <groupId>org.apache.james</groupId>

Added: 
james/server/trunk/lmtpserver/src/main/resources/META-INF/spring/lmtpserver-context.xml
URL: 
http://svn.apache.org/viewvc/james/server/trunk/lmtpserver/src/main/resources/META-INF/spring/lmtpserver-context.xml?rev=1141052&view=auto
==============================================================================
--- 
james/server/trunk/lmtpserver/src/main/resources/META-INF/spring/lmtpserver-context.xml
 (added)
+++ 
james/server/trunk/lmtpserver/src/main/resources/META-INF/spring/lmtpserver-context.xml
 Wed Jun 29 11:33:01 2011
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+    <!--
+        ! Licensed to the Apache Software Foundation (ASF) under one ! ! or
+        more contributor license agreements. See the NOTICE file ! !
+        distributed with this work for additional information ! ! regarding
+        copyright ownership. The ASF licenses this file ! ! to you under the
+        Apache License, Version 2.0 (the ! ! "License"); you may not use this
+        file except in compliance ! ! with the License. You may obtain a copy
+        of the License at ! ! ! ! http://www.apache.org/licenses/LICENSE-2.0 !
+        ! ! ! Unless required by applicable law or agreed to in writing, ! !
+        software distributed under the License is distributed on an ! ! "AS
+        IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY ! ! KIND, either
+        express or implied. See the License for the ! ! specific language
+        governing permissions and limitations ! ! under the License. !
+    -->
+
+
+<beans xmlns="http://www.springframework.org/schema/beans"; 
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
+       xmlns:camel="http://camel.apache.org/schema/spring";
+       xsi:schemaLocation="http://www.springframework.org/schema/beans 
http://www.springframework.org/schema/beans/spring-beans-3.0.xsd";>
+  
+    <!-- Import PostBeanProcessors -->
+    <import 
resource="classpath*:org/apache/james/container/spring/server-context.xml"/>
+    
+    <!-- 
+      SMTP Server
+     -->
+    <bean id="lmtpserver" 
class="org.apache.james.lmtpserver.netty.LMTPServer"/>
+    
+</beans>

Added: 
james/server/trunk/lmtpserver/src/main/resources/META-INF/spring/lmtpserver-osgi.xml
URL: 
http://svn.apache.org/viewvc/james/server/trunk/lmtpserver/src/main/resources/META-INF/spring/lmtpserver-osgi.xml?rev=1141052&view=auto
==============================================================================
--- 
james/server/trunk/lmtpserver/src/main/resources/META-INF/spring/lmtpserver-osgi.xml
 (added)
+++ 
james/server/trunk/lmtpserver/src/main/resources/META-INF/spring/lmtpserver-osgi.xml
 Wed Jun 29 11:33:01 2011
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied.  See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+<beans:beans                                                                   
         
+   xmlns="http://www.springframework.org/schema/osgi";                          
         
+   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
+   xmlns:beans="http://www.springframework.org/schema/beans";             
+   xmlns:osgi="http://www.springframework.org/schema/osgi";                     
         
+   xsi:schemaLocation="http://www.springframework.org/schema/osgi  
+       http://www.springframework.org/schema/osgi/spring-osgi-1.2.xsd
+       http://www.springframework.org/schema/beans   
+       http://www.springframework.org/schema/beans/spring-beans-3.0.xsd";>      
             
+
+    <osgi:service ref="lmtpserver">
+      <osgi:interfaces>
+       
<beans:value>org.apache.james.lmtpserver.netty.LMTPServerMBean</beans:value>
+      </osgi:interfaces>
+    </osgi:service>
+</beans:beans>

Modified: james/server/trunk/pop3server/pom.xml
URL: 
http://svn.apache.org/viewvc/james/server/trunk/pop3server/pom.xml?rev=1141052&r1=1141051&r2=1141052&view=diff
==============================================================================
--- james/server/trunk/pop3server/pom.xml (original)
+++ james/server/trunk/pop3server/pom.xml Wed Jun 29 11:33:01 2011
@@ -27,6 +27,19 @@
   <groupId>org.apache.james</groupId>
   <artifactId>james-server-pop3server</artifactId>
   <name>Apache James Server POP3</name>
+  <properties>
+      <!-- OSGI stuff -->
+    <james.osgi.export>
+      org.apache.james.pop3server.*
+    </james.osgi.export>
+    <james.osgi.import>
+      *
+    </james.osgi.import>
+    <!-- Allow dynamic imports because the user is allowed to add handlers and 
hooks -->
+    <james.osgi.dynamic>
+      *
+    </james.osgi.dynamic>
+  </properties> 
   <dependencies>
     <dependency>
       <groupId>org.apache.james</groupId>

Added: 
james/server/trunk/pop3server/src/main/resources/META-INF/spring/pop3server-context.xml
URL: 
http://svn.apache.org/viewvc/james/server/trunk/pop3server/src/main/resources/META-INF/spring/pop3server-context.xml?rev=1141052&view=auto
==============================================================================
--- 
james/server/trunk/pop3server/src/main/resources/META-INF/spring/pop3server-context.xml
 (added)
+++ 
james/server/trunk/pop3server/src/main/resources/META-INF/spring/pop3server-context.xml
 Wed Jun 29 11:33:01 2011
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+    <!--
+        ! Licensed to the Apache Software Foundation (ASF) under one ! ! or
+        more contributor license agreements. See the NOTICE file ! !
+        distributed with this work for additional information ! ! regarding
+        copyright ownership. The ASF licenses this file ! ! to you under the
+        Apache License, Version 2.0 (the ! ! "License"); you may not use this
+        file except in compliance ! ! with the License. You may obtain a copy
+        of the License at ! ! ! ! http://www.apache.org/licenses/LICENSE-2.0 !
+        ! ! ! Unless required by applicable law or agreed to in writing, ! !
+        software distributed under the License is distributed on an ! ! "AS
+        IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY ! ! KIND, either
+        express or implied. See the License for the ! ! specific language
+        governing permissions and limitations ! ! under the License. !
+    -->
+
+
+<beans xmlns="http://www.springframework.org/schema/beans"; 
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
+       xmlns:camel="http://camel.apache.org/schema/spring";
+       xsi:schemaLocation="http://www.springframework.org/schema/beans 
http://www.springframework.org/schema/beans/spring-beans-3.0.xsd";>
+  
+    <!-- Import PostBeanProcessors -->
+    <import 
resource="classpath*:org/apache/james/container/spring/server-context.xml"/>
+    
+    <!-- 
+      POP3 Server
+     -->
+    <bean id="pop3server" 
class="org.apache.james.pop3server.netty.POP3Server"/>
+    
+</beans>

Added: 
james/server/trunk/pop3server/src/main/resources/META-INF/spring/pop3server-osgi.xml
URL: 
http://svn.apache.org/viewvc/james/server/trunk/pop3server/src/main/resources/META-INF/spring/pop3server-osgi.xml?rev=1141052&view=auto
==============================================================================
--- 
james/server/trunk/pop3server/src/main/resources/META-INF/spring/pop3server-osgi.xml
 (added)
+++ 
james/server/trunk/pop3server/src/main/resources/META-INF/spring/pop3server-osgi.xml
 Wed Jun 29 11:33:01 2011
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied.  See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+<beans:beans                                                                   
         
+   xmlns="http://www.springframework.org/schema/osgi";                          
         
+   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
+   xmlns:beans="http://www.springframework.org/schema/beans";             
+   xmlns:osgi="http://www.springframework.org/schema/osgi";                     
         
+   xsi:schemaLocation="http://www.springframework.org/schema/osgi  
+       http://www.springframework.org/schema/osgi/spring-osgi-1.2.xsd
+       http://www.springframework.org/schema/beans   
+       http://www.springframework.org/schema/beans/spring-beans-3.0.xsd";>      
             
+
+    <osgi:service ref="pop3server">
+      <osgi:interfaces>
+       
<beans:value>org.apache.james.pop3server.netty.POP3ServerMBean</beans:value>
+      </osgi:interfaces>
+    </osgi:service>                            
+</beans:beans>

Modified: james/server/trunk/smtpserver/pom.xml
URL: 
http://svn.apache.org/viewvc/james/server/trunk/smtpserver/pom.xml?rev=1141052&r1=1141051&r2=1141052&view=diff
==============================================================================
--- james/server/trunk/smtpserver/pom.xml (original)
+++ james/server/trunk/smtpserver/pom.xml Wed Jun 29 11:33:01 2011
@@ -27,6 +27,19 @@
   <groupId>org.apache.james</groupId>
   <artifactId>james-server-smtpserver</artifactId>
   <name>Apache James Server SMTP</name>
+  <properties>
+      <!-- OSGI stuff -->
+    <james.osgi.export>
+      org.apache.james.smtpserver*
+    </james.osgi.export>
+    <james.osgi.import>
+      *
+    </james.osgi.import>
+    <!-- Allow dynamic imports because the user is allowed to add handlers and 
hooks -->
+    <james.osgi.dynamic>
+      *
+    </james.osgi.dynamic>
+  </properties> 
   <dependencies>
     <dependency>
       <groupId>org.apache.james</groupId>

Copied: 
james/server/trunk/smtpserver/src/main/resources/META-INF/spring/smtpserver-osgi.xml
 (from r1141048, 
james/server/trunk/dnsservice-dnsjava/src/main/resources/META-INF/spring/smtpserver-osgi.xml)
URL: 
http://svn.apache.org/viewvc/james/server/trunk/smtpserver/src/main/resources/META-INF/spring/smtpserver-osgi.xml?p2=james/server/trunk/smtpserver/src/main/resources/META-INF/spring/smtpserver-osgi.xml&p1=james/server/trunk/dnsservice-dnsjava/src/main/resources/META-INF/spring/smtpserver-osgi.xml&r1=1141048&r2=1141052&rev=1141052&view=diff
==============================================================================
--- 
james/server/trunk/dnsservice-dnsjava/src/main/resources/META-INF/spring/smtpserver-osgi.xml
 (original)
+++ 
james/server/trunk/smtpserver/src/main/resources/META-INF/spring/smtpserver-osgi.xml
 Wed Jun 29 11:33:01 2011
@@ -27,7 +27,7 @@
        http://www.springframework.org/schema/beans   
        http://www.springframework.org/schema/beans/spring-beans-3.0.xsd";>      
             
 
-    <osgi:service ref="lmtpserver">
+    <osgi:service ref="smtpserver">
       <osgi:interfaces>
        
<beans:value>org.apache.james.smtpserver.netty.SMTPServerMBean</beans:value>
       </osgi:interfaces>



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to