removed class CassandraClusterConnection
This commit is contained in:
parent
c02408cc90
commit
60ddd56e8e
|
@ -8,7 +8,7 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
|
||||||
|
|
||||||
- Feature #25901-fix, same as feature 25901 but with minor fixes related to deprecated methods and classes
|
- Feature #25901-fix, same as feature 25901 but with minor fixes related to deprecated methods and classes
|
||||||
|
|
||||||
## [v1.17.1] - 2023-10-30
|
## [v1.18.0-SNAPSHOT] - 2023-10-30
|
||||||
|
|
||||||
- Implementation of databookstore using rest api of social service client
|
- Implementation of databookstore using rest api of social service client
|
||||||
|
|
||||||
|
|
23
pom.xml
23
pom.xml
|
@ -11,7 +11,7 @@
|
||||||
|
|
||||||
<groupId>org.gcube.portal</groupId>
|
<groupId>org.gcube.portal</groupId>
|
||||||
<artifactId>social-networking-library</artifactId>
|
<artifactId>social-networking-library</artifactId>
|
||||||
<version>1.17.1-SNAPSHOT</version>
|
<version>1.18.0-SNAPSHOT</version>
|
||||||
<name>gCube Social Networking Library</name>
|
<name>gCube Social Networking Library</name>
|
||||||
<description>
|
<description>
|
||||||
The gCube Social Networking Library is the 'bridge' between your gCube Applications and the social networking facilities.
|
The gCube Social Networking Library is the 'bridge' between your gCube Applications and the social networking facilities.
|
||||||
|
@ -46,7 +46,7 @@
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.gcube.social-networking</groupId>
|
<groupId>org.gcube.social-networking</groupId>
|
||||||
<artifactId>social-service-client</artifactId>
|
<artifactId>social-service-client</artifactId>
|
||||||
<version>[1.1.0, 2.0.0)</version>
|
<version>[1.3.0-SNAPSHOT, 2.0.0)</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.google</groupId>
|
<groupId>com.google</groupId>
|
||||||
|
@ -56,7 +56,6 @@
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.gcube.resources.discovery</groupId>
|
<groupId>org.gcube.resources.discovery</groupId>
|
||||||
<artifactId>ic-client</artifactId>
|
<artifactId>ic-client</artifactId>
|
||||||
<version>1.0.4</version>
|
|
||||||
<scope>provided</scope>
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
|
@ -129,6 +128,24 @@
|
||||||
<skipTests>true</skipTests>
|
<skipTests>true</skipTests>
|
||||||
</configuration>
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-javadoc-plugin</artifactId>
|
||||||
|
<configuration>
|
||||||
|
<additionalparam>-Xdoclint:none</additionalparam>
|
||||||
|
<additionalJOption>-Xdoclint:none</additionalJOption>
|
||||||
|
</configuration>
|
||||||
|
<version>3.1.0</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>generate-doc</id>
|
||||||
|
<phase>install</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>jar</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
</build>
|
</build>
|
||||||
|
|
||||||
|
|
|
@ -1,15 +1,45 @@
|
||||||
package org.gcube.portal.databook.server;
|
package org.gcube.portal.databook.server;
|
||||||
|
|
||||||
import java.util.*;
|
import java.util.ArrayList;
|
||||||
|
import java.util.Collections;
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
import javax.mail.internet.AddressException;
|
import javax.mail.internet.AddressException;
|
||||||
|
|
||||||
import org.gcube.portal.databook.shared.*;
|
import org.gcube.portal.databook.shared.Attachment;
|
||||||
import org.gcube.portal.databook.shared.ex.*;
|
import org.gcube.portal.databook.shared.Comment;
|
||||||
|
import org.gcube.portal.databook.shared.Feed;
|
||||||
import org.gcube.social_networking.social_networking_client_library.*;
|
import org.gcube.portal.databook.shared.FeedType;
|
||||||
|
import org.gcube.portal.databook.shared.Invite;
|
||||||
|
import org.gcube.portal.databook.shared.InviteOperationResult;
|
||||||
|
import org.gcube.portal.databook.shared.InviteStatus;
|
||||||
|
import org.gcube.portal.databook.shared.Like;
|
||||||
|
import org.gcube.portal.databook.shared.Notification;
|
||||||
|
import org.gcube.portal.databook.shared.NotificationChannelType;
|
||||||
|
import org.gcube.portal.databook.shared.NotificationType;
|
||||||
|
import org.gcube.portal.databook.shared.Post;
|
||||||
|
import org.gcube.portal.databook.shared.PostType;
|
||||||
|
import org.gcube.portal.databook.shared.RangeFeeds;
|
||||||
|
import org.gcube.portal.databook.shared.RangePosts;
|
||||||
|
import org.gcube.portal.databook.shared.ex.ColumnNameNotFoundException;
|
||||||
|
import org.gcube.portal.databook.shared.ex.CommentIDNotFoundException;
|
||||||
|
import org.gcube.portal.databook.shared.ex.FeedIDNotFoundException;
|
||||||
|
import org.gcube.portal.databook.shared.ex.FeedTypeNotFoundException;
|
||||||
|
import org.gcube.portal.databook.shared.ex.InviteIDNotFoundException;
|
||||||
|
import org.gcube.portal.databook.shared.ex.InviteStatusNotFoundException;
|
||||||
|
import org.gcube.portal.databook.shared.ex.LikeIDNotFoundException;
|
||||||
|
import org.gcube.portal.databook.shared.ex.NotificationChannelTypeNotFoundException;
|
||||||
|
import org.gcube.portal.databook.shared.ex.NotificationIDNotFoundException;
|
||||||
|
import org.gcube.portal.databook.shared.ex.NotificationTypeNotFoundException;
|
||||||
|
import org.gcube.portal.databook.shared.ex.PrivacyLevelTypeNotFoundException;
|
||||||
|
import org.gcube.social_networking.social_networking_client_library.CommentClient;
|
||||||
|
import org.gcube.social_networking.social_networking_client_library.HashTagClient;
|
||||||
|
import org.gcube.social_networking.social_networking_client_library.InviteClient;
|
||||||
|
import org.gcube.social_networking.social_networking_client_library.LikeClient;
|
||||||
|
import org.gcube.social_networking.social_networking_client_library.NotificationClient;
|
||||||
|
import org.gcube.social_networking.social_networking_client_library.PostClient;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
|
||||||
|
@ -32,21 +62,11 @@ public final class DBCassandraAstyanaxImpl implements DatabookStore {
|
||||||
private static LikeClient likeClient;
|
private static LikeClient likeClient;
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* connection instance
|
|
||||||
*/
|
|
||||||
private CassandraClusterConnection conn;
|
|
||||||
|
|
||||||
protected CassandraClusterConnection getConnection() {
|
|
||||||
return conn;
|
|
||||||
}
|
|
||||||
/**
|
/**
|
||||||
* use this constructor carefully from test classes
|
* use this constructor carefully from test classes
|
||||||
* @param dropSchema set true if you want do drop the current and set up new one
|
* @param dropSchema set true if you want do drop the current and set up new one
|
||||||
*/
|
*/
|
||||||
protected DBCassandraAstyanaxImpl(boolean dropSchema) {
|
protected DBCassandraAstyanaxImpl(boolean dropSchema) {
|
||||||
|
|
||||||
conn = new CassandraClusterConnection(dropSchema);
|
|
||||||
try {
|
try {
|
||||||
postClient = new PostClient();
|
postClient = new PostClient();
|
||||||
notificationClient = new NotificationClient();
|
notificationClient = new NotificationClient();
|
||||||
|
@ -63,7 +83,6 @@ public final class DBCassandraAstyanaxImpl implements DatabookStore {
|
||||||
* public constructor, no dropping schema is allowed
|
* public constructor, no dropping schema is allowed
|
||||||
*/
|
*/
|
||||||
public DBCassandraAstyanaxImpl() {
|
public DBCassandraAstyanaxImpl() {
|
||||||
conn = new CassandraClusterConnection(false);
|
|
||||||
try {
|
try {
|
||||||
postClient = new PostClient();
|
postClient = new PostClient();
|
||||||
notificationClient = new NotificationClient();
|
notificationClient = new NotificationClient();
|
||||||
|
@ -81,7 +100,6 @@ public final class DBCassandraAstyanaxImpl implements DatabookStore {
|
||||||
* public constructor, no dropping schema is allowed, infrastructureName is given.
|
* public constructor, no dropping schema is allowed, infrastructureName is given.
|
||||||
*/
|
*/
|
||||||
public DBCassandraAstyanaxImpl(String infrastructureName) {
|
public DBCassandraAstyanaxImpl(String infrastructureName) {
|
||||||
conn = new CassandraClusterConnection(false, infrastructureName);
|
|
||||||
try {
|
try {
|
||||||
postClient = new PostClient();
|
postClient = new PostClient();
|
||||||
notificationClient = new NotificationClient();
|
notificationClient = new NotificationClient();
|
||||||
|
@ -867,7 +885,6 @@ public final class DBCassandraAstyanaxImpl implements DatabookStore {
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public void closeConnection() {
|
public void closeConnection() {
|
||||||
conn.closeConnection();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -12,9 +12,6 @@ import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
|
||||||
import com.datastax.oss.driver.api.core.CqlSession;
|
|
||||||
import com.datastax.oss.driver.api.core.metadata.Metadata;
|
|
||||||
import com.datastax.oss.driver.api.core.metadata.schema.KeyspaceMetadata;
|
|
||||||
import org.gcube.common.portal.GCubePortalConstants;
|
import org.gcube.common.portal.GCubePortalConstants;
|
||||||
import org.gcube.common.portal.PortalContext;
|
import org.gcube.common.portal.PortalContext;
|
||||||
import org.gcube.common.resources.gcore.ServiceEndpoint;
|
import org.gcube.common.resources.gcore.ServiceEndpoint;
|
||||||
|
|
Loading…
Reference in New Issue