cleaning logs

This commit is contained in:
Ahmed Salah Tawfik Ibrahim 2024-04-16 15:03:57 +02:00
parent bcbec61646
commit 01821f5da3
3 changed files with 6 additions and 6 deletions

View File

@ -4,7 +4,7 @@
All notable changes to this project will be documented in this file. All notable changes to this project will be documented in this file.
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [v2.0.0] - 2023-12-04 ## [v2.0.0-SNAPSHOT] - 2023-12-04
- Support for Cassandra 4.1.3 using DataStax java driver - Support for Cassandra 4.1.3 using DataStax java driver

View File

@ -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>2.0.0</version> <version>2.0.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.

View File

@ -2318,7 +2318,7 @@ public final class DBCassandraAstyanaxImpl implements DatabookStore {
//if there are no settings for this user create an entry and put all of them at true //if there are no settings for this user create an entry and put all of them at true
List<Row> results = new ArrayList<>(); List<Row> results = new ArrayList<>();
if(result!=null) results = result.all(); if(result!=null) results = result.all();
_log.info("Result set empty? " + results.isEmpty()); //_log.info("Result set empty? " + results.isEmpty());
if (results.isEmpty()) { if (results.isEmpty()) {
_log.info("Userid " + userid + " settings not found, initiating its preferences..."); _log.info("Userid " + userid + " settings not found, initiating its preferences...");
HashMap<NotificationType, NotificationChannelType[]> toCreate = new HashMap<NotificationType, NotificationChannelType[]>(); HashMap<NotificationType, NotificationChannelType[]> toCreate = new HashMap<NotificationType, NotificationChannelType[]>();
@ -2341,9 +2341,9 @@ public final class DBCassandraAstyanaxImpl implements DatabookStore {
_log.info("Notification preferences Found for " + userid + " : " + results.size()) ; _log.info("Notification preferences Found for " + userid + " : " + results.size()) ;
for (Row row: results){ for (Row row: results){
String[] channels = row.getString(PREFERENCE).split(","); String[] channels = row.getString(PREFERENCE).split(",");
_log.info("Row : " + row.getString(PREFERENCE)); //_log.info("Row : " + row.getString(PREFERENCE));
if (channels != null && channels.length == 1 && channels[0].toString().equals("") ) { //it is empty, preference is set to no notification at all if (channels != null && channels.length == 1 && channels[0].toString().equals("") ) { //it is empty, preference is set to no notification at all
_log.info("adding CHANNELS NULL: " + getNotificationType(row.getString(TYPE)) + ", " + new NotificationChannelType[0]); //_log.info("adding CHANNELS NULL: " + getNotificationType(row.getString(TYPE)) + ", " + new NotificationChannelType[0]);
toReturn.put(getNotificationType(row.getString(TYPE)), new NotificationChannelType[0]); toReturn.put(getNotificationType(row.getString(TYPE)), new NotificationChannelType[0]);
} else { } else {
NotificationChannelType[] toAdd = new NotificationChannelType[channels.length]; NotificationChannelType[] toAdd = new NotificationChannelType[channels.length];
@ -2352,7 +2352,7 @@ public final class DBCassandraAstyanaxImpl implements DatabookStore {
toAdd[i] = (getChannelType(channels[i])); toAdd[i] = (getChannelType(channels[i]));
} }
} }
_log.info("adding channels not null: " + getNotificationType(row.getString(TYPE)) + ", " + toAdd.toString()); //_log.info("adding channels not null: " + getNotificationType(row.getString(TYPE)) + ", " + toAdd.toString());
toReturn.put(getNotificationType(row.getString(TYPE)), toAdd); toReturn.put(getNotificationType(row.getString(TYPE)), toAdd);
} }
} }