Uploaded image for project: 'Spring Data GemFire'
  1. Spring Data GemFire
  2. SGF-36

PoolFactoryBean can be instantiated before cache if namespace used

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.0.0
    • Fix Version/s: 1.0.1
    • Labels:
      None

      Description

      The <gfe:pool/> element has no reference to the gemfire cache. This means it can be instantiated before the cache, causing an Exception "... Caused by: java.lang.IllegalStateException: Distributed System must be created before creating pool".

      Work-around is to define using <bean/> syntax and adding a depends-on attribute...

      	<bean id="pool" class="org.springframework.data.gemfire.client.PoolFactoryBean"
      		depends-on="gemfire-cache">
      		<property name="locators">
      			<list>
      				<bean class="org.springframework.data.gemfire.client.PoolConnection">
      					<property name="host" value="${gemfire.locator.host}"/>
      					<property name="port" value="${gemfire.locator.port}"/>
      				</bean>
      			</list>
      		</property>
      	</bean>
      

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              costin Costin Leau
              Reporter:
              grussell Gary Russell
              Last updater:
              John Blum John Blum
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: