alvinalexander.com | career | drupal | java | mac | mysql | perl | scala | uml | unix  

ActiveMQ example source code file (ldap-spring.xml)

This example ActiveMQ source code file (ldap-spring.xml) is included in the DevDaily.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Java - ActiveMQ tags/keywords

apache, asf, asf, entries, is, license, license, of, see, the, the, version, you, you

The ActiveMQ ldap-spring.xml source code

<?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.
-->

<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN"
  "http://www.springframework.org/dtd/spring-beans.dtd">

<beans>
  <bean id="environment" class="org.springframework.beans.factory.config.PropertiesFactoryBean">
    <property name="properties">
      <props>
        <prop key="java.naming.security.authentication">simple
        <prop key="java.naming.security.principal">uid=admin,ou=system
        <prop key="java.naming.security.credentials">secret
        <!---->
        <!---->
        <!---->
        <!---->
        <!-- Set this key to a space delimited set of attributeType descriptions
             and their OID's if you want an attributeType to be handled as 
             binary content.
 
             The server will use the schema to derive the set of attributeTypes
             to treat as binary.  The union if the values you provide here 
             will be taken as the set of binaries. Note to be consistent you 
             must add both the OID and all the names an attributeType can have.
        -->
        <!-- 
        <prop key="java.naming.ldap.attributes.binary">
        -->
      </props>
    </property>
  </bean>
  
  <bean id="configuration" class="org.apache.directory.server.core.configuration.MutableStartupConfiguration">
    <property name="workingDirectory">example.com

    <!-- Uncomment below to have the server load entries on startup!        -->
    <!-- ldifDirectory property can point to a relative file, directory or  -->
    <!-- can point to an absolute path to either using the URL path         -->
    <!-- notation: i.e. file:///Users/jack/apacheds/ldifs                   -->

    <!-- Entries will optionally be filtered using LdifLoadFilters in the   -->
    <!-- order specified.  The included Krb5KdcEntryFilter will filter      -->
    <!-- kerberos principals creating keys for them using their             -->
    <!-- userPassword attribute if present.                                 -->

    <!--
    </property>
    <property name="ldifFilters">
      <list>
        <bean class="org.apache.directory.server.protocol.shared.store.Krb5KdcEntryFilter"/>
      </list>
    </property>-->

    <property name="allowAnonymousAccess">false
    <property name="accessControlEnabled">false
    <!--  
    <property name="enableNtp">false
    <property name="enableKerberos">false
    <property name="enableChangePassword">false
    <property name="ldapPort">10389
    <property name="contextPartitionConfigurations">
      <set>
        <ref bean="examplePartitionConfiguration"/>
      </set>
    </property>
    -->
    <property name="bootstrapSchemas">
      <set>
        <bean class="org.apache.directory.server.core.schema.bootstrap.AutofsSchema"/>
        <bean class="org.apache.directory.server.core.schema.bootstrap.CorbaSchema"/>
        <bean class="org.apache.directory.server.core.schema.bootstrap.CoreSchema"/>
        <bean class="org.apache.directory.server.core.schema.bootstrap.CosineSchema"/>
        <bean class="org.apache.directory.server.core.schema.bootstrap.ApacheSchema"/>
        <bean class="org.apache.directory.server.core.schema.bootstrap.CollectiveSchema"/>
        <bean class="org.apache.directory.server.core.schema.bootstrap.InetorgpersonSchema"/>
        <bean class="org.apache.directory.server.core.schema.bootstrap.JavaSchema"/>
        <bean class="org.apache.directory.server.core.schema.bootstrap.Krb5kdcSchema"/>
        <bean class="org.apache.directory.server.core.schema.bootstrap.NisSchema"/>
        <bean class="org.apache.directory.server.core.schema.bootstrap.SystemSchema"/>
        <bean class="org.apache.directory.server.core.schema.bootstrap.ApachednsSchema"/>
      </set>
    </property>
    
      <!-- 
    <property name="extendedOperationHandlers">
      <list>
        <bean class="org.apache.directory.server.ldap.support.extended.GracefulShutdownHandler"/>
        <bean class="org.apache.directory.server.ldap.support.extended.LaunchDiagnosticUiHandler"/>
       </list>
    </property>

    <property name="interceptorConfigurations">
      <list>
        <bean class="org.apache.directory.server.core.configuration.MutableInterceptorConfiguration">
          <property name="name">normalizationService
          <property name="interceptor">
            <bean class="org.apache.directory.server.core.normalization.NormalizationService" />
          </property>
        </bean>
        <bean class="org.apache.directory.server.core.configuration.MutableInterceptorConfiguration">
          <property name="name">authenticationService
          <property name="interceptor">
            <bean class="org.apache.directory.server.core.authn.AuthenticationService" />
          </property>
        </bean>
        <bean class="org.apache.directory.server.core.configuration.MutableInterceptorConfiguration">
          <property name="name">referralService
          <property name="interceptor">
            <bean class="org.apache.directory.server.core.referral.ReferralService" />
          </property>
        </bean>
        <bean class="org.apache.directory.server.core.configuration.MutableInterceptorConfiguration">
          <property name="name">authorizationService
          <property name="interceptor">
            <bean class="org.apache.directory.server.core.authz.AuthorizationService" />
          </property>
        </bean>
        <bean class="org.apache.directory.server.core.configuration.MutableInterceptorConfiguration">
          <property name="name">defaultAuthorizationService
          <property name="interceptor">
            <bean class="org.apache.directory.server.core.authz.DefaultAuthorizationService" />
          </property>
        </bean>
        <bean class="org.apache.directory.server.core.configuration.MutableInterceptorConfiguration">
          <property name="name">exceptionService
          <property name="interceptor">
            <bean class="org.apache.directory.server.core.exception.ExceptionService" />
          </property>
        </bean>
        <bean class="org.apache.directory.server.core.configuration.MutableInterceptorConfiguration">
          <property name="name">schemaService
          <property name="interceptor">
            <bean class="org.apache.directory.server.core.schema.SchemaService" />
          </property>
        </bean>
        <bean class="org.apache.directory.server.core.configuration.MutableInterceptorConfiguration">
          <property name="name">subentryService
          <property name="interceptor">
            <bean class="org.apache.directory.server.core.subtree.SubentryService" />
          </property>
        </bean>
        <bean class="org.apache.directory.server.core.configuration.MutableInterceptorConfiguration">
          <property name="name">operationalAttributeService
          <property name="interceptor">
            <bean class="org.apache.directory.server.core.operational.OperationalAttributeService" />
          </property>
        </bean>
        <bean class="org.apache.directory.server.core.configuration.MutableInterceptorConfiguration">
          <property name="name">collectiveAttributeService
          <property name="interceptor">
            <bean class="org.apache.directory.server.core.collective.CollectiveAttributeService" />
          </property>
        </bean>
        <bean class="org.apache.directory.server.core.configuration.MutableInterceptorConfiguration">
          <property name="name">eventService
          <property name="interceptor">
            <bean class="org.apache.directory.server.core.event.EventService" />
          </property>
        </bean>
      </list>
    </property>
 -->
  </bean>
  
  <bean id="examplePartitionConfiguration" class="org.apache.directory.server.core.configuration.MutableDirectoryPartitionConfiguration">
    <property name="name">example
    <property name="suffix">dc=example,dc=com
    <property name="indexedAttributes">
      <set>
        <value>dc
        <value>ou
        <value>objectClass
        <value>krb5PrincipalName
        <value>uid
      </set>
    </property>
    <property name="contextEntry">
      <value>
        objectClass: top
        objectClass: domain
        objectClass: extensibleObject
        dc: example
      </value>
    </property>
  </bean>

  <bean class="org.springframework.beans.factory.config.CustomEditorConfigurer">
    <property name="customEditors">
      <map>
        <entry key="javax.naming.directory.Attributes">
          <bean class="org.apache.directory.server.core.configuration.AttributesPropertyEditor"/>
        </entry>
      </map>
   </property>
  </bean>
</beans>

Other ActiveMQ examples (source code examples)

Here is a short list of links related to this ActiveMQ ldap-spring.xml source code file:

... this post is sponsored by my books ...

#1 New Release!

FP Best Seller

 

new blog posts

 

Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.

A percentage of advertising revenue from
pages under the /java/jwarehouse URI on this website is
paid back to open source projects.