Skip to content

Commit

Permalink
Move spring-integration-hazelcast from extensions
Browse files Browse the repository at this point in the history
* Update javadocs
* Upgrade from log4j to log4j2
* Remove unnecessary test deps.
* Change from implmementation to api
* Remove unneeded test deps.
* Fix HZ XSD to be "versionless"
* Use `com.google.code.findbugs:annotations` dep to avoid warning from HZ code base
  • Loading branch information
Robert Höglund authored and artembilan committed May 25, 2022
1 parent 040438f commit a322f5c
Show file tree
Hide file tree
Showing 83 changed files with 9,032 additions and 3 deletions.
15 changes: 12 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@ ext {
commonsNetVersion = '3.8.0'
curatorVersion = '4.3.0'
derbyVersion = '10.14.2.0'
findbugsVersion = '3.0.1'
ftpServerVersion = '1.2.0'
googleJsr305Version = '3.0.2'
greenmailVersion = '2.0.0-alpha-2'
groovyVersion = '3.0.10'
hamcrestVersion = '2.2'
Expand Down Expand Up @@ -251,8 +251,8 @@ configure(javaProjects) { subproject ->
}

// JSR-305 only used for non-required meta-annotations
compileOnly "com.google.code.findbugs:jsr305:$googleJsr305Version"
testImplementation "com.google.code.findbugs:jsr305:$googleJsr305Version"
compileOnly "com.google.code.findbugs:annotations:$findbugsVersion"
testImplementation "com.google.code.findbugs:annotations:$findbugsVersion"
testImplementation("org.awaitility:awaitility:$awaitilityVersion") {
exclude group: 'org.hamcrest'
}
Expand Down Expand Up @@ -1080,6 +1080,15 @@ project('spring-integration-bom') {
}
}


project('spring-integration-hazelcast') {
description = 'Spring Integration Hazelcast Support'
dependencies {
api "com.hazelcast:hazelcast:$hazelcastVersion"
api project(':spring-integration-core')
}
}

sonarqube {
properties {
property 'sonar.links.homepage', linkHomepage
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
/*
* Copyright 2015-2022 the original author or authors.
*
* Licensed 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
*
* https://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.
*/

package org.springframework.integration.hazelcast;

/**
* Enumeration of Cache Event Types.
*
* @author Eren Avsarogullari
* @author Artem Bilan
*
* @since 6.0
*
* @see org.springframework.integration.hazelcast.inbound.AbstractHazelcastMessageProducer
*/
public enum CacheEventType {

/**
* The Hazelcast ADDED event.
*/
ADDED,

/**
* The Hazelcast REMOVED event.
*/
REMOVED,

/**
* The Hazelcast UPDATED event.
*/
UPDATED,

/**
* The Hazelcast EVICTED event.
*/
EVICTED,

/**
* The Hazelcast EXPIRED event.
*/
EXPIRED,

/**
* The Hazelcast EVICT_ALL event.
*/
EVICT_ALL,

/**
* The Hazelcast CLEAR_ALL event.
*/
CLEAR_ALL

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
/*
* Copyright 2015-2022 the original author or authors.
*
* Licensed 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
*
* https://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.
*/

package org.springframework.integration.hazelcast;

/**
* Enumeration of Cache Listening Policy Type.
*
* @author Eren Avsarogullari
* @author Artem Bilan
*
* @since 6.0
*
* @see org.springframework.integration.hazelcast.inbound.AbstractHazelcastMessageProducer
*/
public enum CacheListeningPolicyType {

/**
* Only the local Hazelcast node can accept event.
*/
SINGLE,

/**
* All subscribed members can accept event.
*/
ALL

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
/*
* Copyright 2015-2022 the original author or authors.
*
* Licensed 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
*
* https://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.
*/

package org.springframework.integration.hazelcast;

/**
* Enumeration of Hazelcast Cluster Monitor Types.
*
* @author Eren Avsarogullari
* @author Artem Bilan
*
* @since 6.0
*
* @see org.springframework.integration.hazelcast.inbound.HazelcastClusterMonitorMessageProducer
* @see com.hazelcast.core.DistributedObjectListener
* @see com.hazelcast.core.LifecycleListener
*/
public enum ClusterMonitorType {

/**
* The membership listener mode.
*/
MEMBERSHIP,

/**
* The distributed object listener mode.
*/
DISTRIBUTED_OBJECT,

/**
* The migration listener mode.
*/
MIGRATION,

/**
* The listener listener mode.
*/
LIFECYCLE,

/**
* The client listener mode.
*/
CLIENT

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
/*
* Copyright 2015-2022 the original author or authors.
*
* Licensed 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
*
* https://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.
*/

package org.springframework.integration.hazelcast;

/**
* Enumeration of Distributed SQL Iteration Type.
*
* @author Eren Avsarogullari
* @author Artem Bilan
*
* @since 6.0
*
* @see org.springframework.integration.hazelcast.inbound.HazelcastDistributedSQLMessageSource
* @see com.hazelcast.map.IMap
*/
public enum DistributedSQLIterationType {

/**
* The {@link com.hazelcast.map.IMap#entrySet()} to iterate.
*/
ENTRY,

/**
* The {@link com.hazelcast.map.IMap#keySet()} to iterate.
*/
KEY,

/**
* The {@link com.hazelcast.map.IMap#localKeySet()} to iterate.
*/
LOCAL_KEY,

/**
* The {@link com.hazelcast.map.IMap#values()} to iterate.
*/
VALUE

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
/*
* Copyright 2015-2022 the original author or authors.
*
* Licensed 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
*
* https://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.
*/

package org.springframework.integration.hazelcast;

/**
* Hazelcast Message Headers.
*
* @author Eren Avsarogullari
* @author Artem Bilan
*
* @since 6.0
*/
public abstract class HazelcastHeaders {

private static final String PREFIX = "hazelcast_";

/**
* The event type header name.
*/
public static final String EVENT_TYPE = PREFIX + "eventType";

/**
* The member header name.
*/
public static final String MEMBER = PREFIX + "member";

/**
* The cache name header name.
*/
public static final String CACHE_NAME = PREFIX + "cacheName";

/**
* The publishing time header name.
*/
public static final String PUBLISHING_TIME = PREFIX + "publishingTime";

}

0 comments on commit a322f5c

Please sign in to comment.