The Spring Session for GemFire libraries are available from the Broadcom Customer Support Portal.

Prerequisites

  1. Log in to the Broadcom Customer Support Portal with your customer credentials. For more information about login requirements, see the Download Broadcom products and software article.
  2. Go to the VMware Tanzu GemFire downloads page, select VMware Tanzu GemFire, click Show All Releases.
  3. Find the release named Click Green Token for Repository Access and click the Token Download icon on the right. This opens the instructions on how to use the GemFire artifact repository. At the top, the Access Token is provided. Click Copy to Clipboard. You will use this Access Token as the password.

Maven

Repository and Credential Setup

  1. Modify your project’s pom.xml file by adding the following repository definition:

        <repository>
          <id>gemfire-release-repo</id>
          <name>GemFire Release Repository</name>
          <url>https://packages.broadcom.com/artifactory/gemfire/</url>
        </repository>
    
  2. To access the artifacts, you must add an entry to your .m2/settings.xml file:

      <settings>
        <servers>
          <server>
            <id>gemfire-release-repo</id>
            <username>EXAMPLE-USERNAME</username>
            <password>MY-PASSWORD</password>
          </server>
        </servers>
      </settings>
    

    Where:

    • EXAMPLE-USERNAME is your support.broadcom.com user name.
    • MY-PASSWORD is the Access Token you copied in step 3 in Prerequisites.

Add the Libraries to your Project

After setting up the repository and credentials, add the Spring Session for GemFire library to your application. To support multiple GemFire versions, the Spring Session for GemFire library requires users to specify an explicit dependency on the desired version of GemFire.

In the following examples:

  • Replace the springSessionForGemFire.version with the version of the library that your project requires.
  • Replace the vmwareGemFire.version with the version of GemFire that your project requires.
  • Replace the <artifactId>spring-session-3.3-gemfire-10.1</artifactId> with the version of Spring Session + the version of GemFire your application requires.

Client Applications

Add the following to your pom.xml file:

    <properties>
        <springSessionForGemFire.version>1.0.0</springSessionForGemFire.version>
        <vmwareGemFire.version>10.1.1</vmwareGemFire.version>
    </properties>    
    
    <dependencies>
       <dependency>
           <groupId>com.vmware.gemfire</groupId>
           <artifactId>spring-session-3.3-gemfire-10.1</artifactId>
           <version>${springSessionForGemFire.version}</version>
       </dependency>
       <dependency>
           <groupId>com.vmware.gemfire</groupId>
           <artifactId>gemfire-core</artifactId>
           <version>${vmwareGemFire.version}</version>
       </dependency>
    <!--if using continuous queries-->
       <dependency>
            <groupId>com.vmware.gemfire</groupId>
            <artifactId>gemfire-cq</artifactId>
            <version>${vmwareGemFire.version}</version>
       </dependency>
    </dependencies>

Server Applications

NOTE: The server dependencies are only required if the user is starting an embedded GemFire server using Spring.

Add the following to your pom.xml file:

   <properties>
         <springSessionForGemFire.version>1.0.0</springSessionForGemFire.version>
         <vmwareGemFire.version>10.1.1</vmwareGemFire.version>
   </properties>         
   
   <dependencies>
       <dependency>
           <groupId>com.vmware.gemfire</groupId>
           <artifactId>spring-session-3.3-gemfire-10.1</artifactId>
           <version>${springSessionForGemFire.version}</version>
       </dependency>
       <dependency>
              <groupId>com.vmware.gemfire</groupId>
              <artifactId>gemfire-server-all</artifactId>
              <version>${vmwareGemFire.version}</version>
              <exclusions>
                   <exclusion>
                        <groupId>com.vmware.gemfire</groupId>
                        <artifactId>gemfire-log4j</artifactId>
                   </exclusion>
              </exclusions>
       </dependency>
   </dependencies>

Your application is now ready to connect with your GemFire instance.

Gradle

Repository and Credential Setup

  1. Add the following block to the repositories section of the build.gradle file:

      repositories {
        maven {
          credentials {
            username "gemfireRepoUsername"
            password "gemfireRepoPassword"
          }
          url = uri("https://packages.broadcom.com/artifactory/gemfire/")
        }
      }
    
  2. Add your credentials to the local .gradle/gradle.properties or project gradle.properties file.

    gemfireRepoUsername=MY-USERNAME
    gemfireRepoPassword=MY-PASSWORD
    

    Where:

    • EXAMPLE-USERNAME is your support.broadcom.com username.
    • MY-PASSWORD is the Access Token you copied in step 3 in Prerequisites.

Add the Libraries to your Project

After setting up the repository and credentials, add the Spring Session for GemFire library to your application. To support multiple GemFire versions, the Spring Session for GemFire library requires users to specify an explicit dependency on the desired version of GemFire.

In the following examples:

  • Replace the springSessionForGemFire.version with the version of the library that your project requires.
  • Replace the vmwareGemFire.version with the version of GemFire that your project requires.
  • Replace the spring-session-3.3-gemfire-10.1 with the version of Spring Session + the version of GemFire your application requires.

Client Applications

Add the following to your build.gradle file.

        ext {
            springSessionForGemFireVersion = '1.0.0'
            vmwareGemFireVersion = '10.1.1'
        }
        
        dependencies {
            implementation "com.vmware.gemfire:spring-session-3.3-gemfire-10.1:$springSessionForGemFireVersion"
            implementation "com.vmware.gemfire:gemfire-core:$vmwareGemFireVersion"
            // if using continuous queries
            implementation "com.vmware.gemfire:gemfire-cq:$vmwareGemFireVersion"
        }

Server Applications

NOTE: The server dependencies are only required if the user is starting an embedded GemFire server using Spring.

        ext {
            springSessionForGemFireVersion = '1.0.0'
            vmwareGemFireVersion = '10.1.1'
        }
    
        dependencies {
           implementation "com.vmware.gemfire:spring-session-3.3-gemfire-10.1:$springSessionForGemFireVersion"
           implementation ("com.vmware.gemfire:gemfire-server-all:$vmwareGemFireVersion"){
           exclude group: 'com.vmware.gemfire', module: 'gemfire-log4j'
           }
        }
check-circle-line exclamation-circle-line close-line
Scroll to top icon