Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

694 module notification jakarta update #696

Merged
7 changes: 7 additions & 0 deletions coffee-bom/coffee-bom-all/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
<version.commons-codec>1.15</version.commons-codec>
<version.commons-collections>3.2.2</version.commons-collections>
<version.commons-io>2.11.0</version.commons-io>
<version.commons-email2-jakarta>2.0.0-M1</version.commons-email2-jakarta>
speter555 marked this conversation as resolved.
Show resolved Hide resolved
<version.org.jboss.resteasy>6.2.1.Final</version.org.jboss.resteasy>
<version.org.hibernate>6.2.13.Final</version.org.hibernate>
<version.org.apache.httpcomponents.httpclient>4.5.13</version.org.apache.httpcomponents.httpclient>
Expand Down Expand Up @@ -173,6 +174,12 @@
<version>${version.commons-io}</version>
</dependency>

<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-email2-jakarta</artifactId>
<version>${version.commons-email2-jakarta}</version>
</dependency>

<!-- Resteasy 4+: the resteasy-jaxrs set is split into core, core-spi, and others -->
<dependency>
<groupId>org.jboss.resteasy</groupId>
Expand Down
10 changes: 5 additions & 5 deletions coffee-bom/coffee-bom-project/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -158,11 +158,11 @@
<artifactId>coffee-module-document-action</artifactId>
<version>${project.version}</version>
</dependency>
<!-- <dependency>-->
<!-- <groupId>hu.icellmobilsoft.coffee</groupId>-->
<!-- <artifactId>coffee-module-notification</artifactId>-->
<!-- <version>${project.version}</version>-->
<!-- </dependency>-->
<dependency>
<groupId>hu.icellmobilsoft.coffee</groupId>
<artifactId>coffee-module-notification</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>hu.icellmobilsoft.coffee</groupId>
<artifactId>coffee-module-notification-dto</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion coffee-dto/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -84,4 +84,4 @@
<module>coffee-dto-xsd2proto</module>
<module>coffee-dto-stub-gen</module>
</modules>
</project>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<parent>
<groupId>hu.icellmobilsoft.coffee</groupId>
<artifactId>coffee-module-notification</artifactId>
<version>2.3.0-SNAPSHOT</version>
<version>2.9.0-SNAPSHOT</version>
</parent>

<artifactId>coffee-module-notification-action</artifactId>
Expand Down Expand Up @@ -33,22 +33,9 @@
<groupId>hu.icellmobilsoft.coffee</groupId>
<artifactId>coffee-rest</artifactId>
</dependency>

<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-email</artifactId>
<version>1.5</version>
<exclusions>
<exclusion>
<groupId>com.sun.mail</groupId>
<artifactId>javax.mail</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>com.sun.mail</groupId>
<artifactId>jakarta.mail</artifactId>
<version>2.0.1</version>
<artifactId>commons-email2-jakarta</artifactId>
</dependency>
</dependencies>
</project>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@
import hu.icellmobilsoft.coffee.cdi.logger.ThisLogger;
import hu.icellmobilsoft.coffee.dto.common.common.KeyValueBasicType;
import hu.icellmobilsoft.coffee.dto.document.document.TemplateFullType;
import hu.icellmobilsoft.coffee.dto.exception.BaseException;
import hu.icellmobilsoft.coffee.dto.notification.notification.EmailPlainTextType;
import hu.icellmobilsoft.coffee.se.api.exception.BaseException;

/**
* AbstractEmailPlainTextAction class.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@
import hu.icellmobilsoft.coffee.cdi.logger.ThisLogger;
import hu.icellmobilsoft.coffee.dto.common.common.KeyValueBasicType;
import hu.icellmobilsoft.coffee.dto.document.document.TemplateFullType;
import hu.icellmobilsoft.coffee.dto.exception.BaseException;
import hu.icellmobilsoft.coffee.dto.notification.notification.EmailTemplateType;
import hu.icellmobilsoft.coffee.se.api.exception.BaseException;

/**
* AbstractEmailTemplateAction class.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,16 +34,16 @@
import jakarta.mail.util.ByteArrayDataSource;

import org.apache.commons.lang3.StringUtils;
import org.apache.commons.mail.Email;
import org.apache.commons.mail.EmailException;
import org.apache.commons.mail.MultiPartEmail;
import org.apache.commons.mail2.core.EmailException;
import org.apache.commons.mail2.jakarta.Email;
import org.apache.commons.mail2.jakarta.MultiPartEmail;

import hu.icellmobilsoft.coffee.cdi.logger.AppLogger;
import hu.icellmobilsoft.coffee.cdi.logger.ThisLogger;
import hu.icellmobilsoft.coffee.dto.exception.BaseException;
import hu.icellmobilsoft.coffee.dto.exception.TechnicalException;
import hu.icellmobilsoft.coffee.dto.exception.enums.CoffeeFaultType;
import hu.icellmobilsoft.coffee.module.notification.action.email.annotation.EmailOnly;
import hu.icellmobilsoft.coffee.se.api.exception.BaseException;
import hu.icellmobilsoft.coffee.se.api.exception.TechnicalException;

/**
* Handles basic e-mail sending, based on Apache commons-email
Expand Down Expand Up @@ -104,6 +104,13 @@ public class EmailBase {
private Object content;
private String to;

/**
* Default constructor, constructs a new object.
*/
public EmailBase() {
super();
}

/**
* Setter for {@code mailSession} field of {@link Email}.
*
Expand Down Expand Up @@ -416,7 +423,7 @@ public String emailString(Email email) throws BaseException {
}

/**
* Getter for the field {@code email}. If it's not initialized yet, creates an {@link org.apache.commons.mail.MultiPartEmail} instance. For a
* Getter for the field {@code email}. If it's not initialized yet, creates an {@link MultiPartEmail} instance. For a
* different {@link Email} class, use {@link #setEmail(Email)}.
*
* @return {@code email}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@

import hu.icellmobilsoft.coffee.cdi.logger.AppLogger;
import hu.icellmobilsoft.coffee.cdi.logger.ThisLogger;
import hu.icellmobilsoft.coffee.dto.exception.BaseException;
import hu.icellmobilsoft.coffee.module.notification.model.Email;
import hu.icellmobilsoft.coffee.se.api.exception.BaseException;

/**
* Extends the functionality of {@link EmailBase} with database save. Operates with OUTPUT_JOB table.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
import org.apache.commons.lang3.StringUtils;

import hu.icellmobilsoft.coffee.dto.exception.BONotFoundException;
import hu.icellmobilsoft.coffee.dto.exception.BaseException;
import hu.icellmobilsoft.coffee.jpa.annotation.Transactional;
import hu.icellmobilsoft.coffee.module.notification.model.Email;
import hu.icellmobilsoft.coffee.module.notification.model.EmailRecipient;
Expand All @@ -38,6 +37,7 @@
import hu.icellmobilsoft.coffee.module.notification.service.EmailRecipientService;
import hu.icellmobilsoft.coffee.module.notification.service.EmailService;
import hu.icellmobilsoft.coffee.module.notification.service.RecipientService;
import hu.icellmobilsoft.coffee.se.api.exception.BaseException;

/**
* CDI helper class for email handling
Expand Down Expand Up @@ -68,6 +68,14 @@ public class EmailHelper implements Serializable {
@Inject
private EmailService emailService;


/**
* Default constructor, constructs a new object.
*/
public EmailHelper() {
super();
}

/**
* Inserts {@link EmailDataBase} into DB.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,15 +32,15 @@
import hu.icellmobilsoft.coffee.cdi.logger.ThisLogger;
import hu.icellmobilsoft.coffee.dto.common.common.KeyValueBasicType;
import hu.icellmobilsoft.coffee.dto.document.document.TemplateFullType;
import hu.icellmobilsoft.coffee.dto.exception.BaseException;
import hu.icellmobilsoft.coffee.dto.exception.TechnicalException;
import hu.icellmobilsoft.coffee.dto.exception.enums.CoffeeFaultType;
import hu.icellmobilsoft.coffee.dto.notification.notification.DeviceOSType;
import hu.icellmobilsoft.coffee.dto.notification.notification.DeviceType;
import hu.icellmobilsoft.coffee.dto.notification.notification.PushType;
import hu.icellmobilsoft.coffee.module.notification.exception.PushClientException;
import hu.icellmobilsoft.coffee.module.notification.exception.PushServerException;
import hu.icellmobilsoft.coffee.module.notification.model.Push;
import hu.icellmobilsoft.coffee.se.api.exception.BaseException;
import hu.icellmobilsoft.coffee.se.api.exception.TechnicalException;

/**
* Push notification business logic class
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,13 @@
import org.apache.commons.lang3.StringUtils;

import hu.icellmobilsoft.coffee.dto.common.common.KeyValueBasicType;
import hu.icellmobilsoft.coffee.dto.exception.BaseException;
import hu.icellmobilsoft.coffee.dto.notification.notification.DeviceType;
import hu.icellmobilsoft.coffee.jpa.annotation.Transactional;
import hu.icellmobilsoft.coffee.module.notification.model.Push;
import hu.icellmobilsoft.coffee.module.notification.model.PushDevice;
import hu.icellmobilsoft.coffee.module.notification.service.PushDeviceService;
import hu.icellmobilsoft.coffee.module.notification.service.PushService;
import hu.icellmobilsoft.coffee.se.api.exception.BaseException;
import hu.icellmobilsoft.coffee.tool.gson.JsonUtil;
import hu.icellmobilsoft.coffee.tool.utils.enums.EnumUtil;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
*/
package hu.icellmobilsoft.coffee.module.notification.exception;

import hu.icellmobilsoft.coffee.dto.exception.TechnicalException;
import hu.icellmobilsoft.coffee.dto.exception.enums.CoffeeFaultType;
import hu.icellmobilsoft.coffee.se.api.exception.TechnicalException;

/**
* PushClientException class.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
*/
package hu.icellmobilsoft.coffee.module.notification.exception;

import hu.icellmobilsoft.coffee.dto.exception.TechnicalException;
import hu.icellmobilsoft.coffee.dto.exception.enums.CoffeeFaultType;
import hu.icellmobilsoft.coffee.se.api.exception.TechnicalException;

/**
* PushServerException class.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@
import hu.icellmobilsoft.coffee.cdi.logger.AppLogger;
import hu.icellmobilsoft.coffee.cdi.logger.ThisLogger;
import hu.icellmobilsoft.coffee.dto.exception.BONotFoundException;
import hu.icellmobilsoft.coffee.dto.exception.BaseException;
import hu.icellmobilsoft.coffee.dto.exception.TechnicalException;
import hu.icellmobilsoft.coffee.dto.exception.enums.CoffeeFaultType;
import hu.icellmobilsoft.coffee.jpa.service.BaseService;
import hu.icellmobilsoft.coffee.module.notification.model.Recipient;
import hu.icellmobilsoft.coffee.module.notification.repository.RecipientRepository;
import hu.icellmobilsoft.coffee.se.api.exception.BaseException;
import hu.icellmobilsoft.coffee.se.api.exception.TechnicalException;

/**
* Service for {@link Recipient} functionality. Represents only DB operations
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<parent>
<groupId>hu.icellmobilsoft.coffee</groupId>
<artifactId>coffee-module-notification</artifactId>
<version>2.3.0-SNAPSHOT</version>
<version>2.9.0-SNAPSHOT</version>
</parent>

<artifactId>coffee-module-notification-dto</artifactId>
Expand Down Expand Up @@ -92,4 +92,4 @@
</plugin>
</plugins>
</build>
</project>
</project>
2 changes: 1 addition & 1 deletion coffee-module/coffee-module-notification/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<parent>
<groupId>hu.icellmobilsoft.coffee</groupId>
<artifactId>coffee-module</artifactId>
<version>2.3.0-SNAPSHOT</version>
<version>2.9.0-SNAPSHOT</version>
</parent>

<artifactId>coffee-module-notification</artifactId>
Expand Down
2 changes: 0 additions & 2 deletions coffee-module/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,7 @@
<module>coffee-module-redis</module>
<module>coffee-module-redisstream</module>
<module>coffee-module-document</module>
<!-- waiting for commons-email 2.0 or refact module without it...>
<module>coffee-module-notification</module>
-->
<module>coffee-module-csv</module>
<module>coffee-module-ruleng</module>
<module>coffee-module-mp</module>
Expand Down
6 changes: 6 additions & 0 deletions docs/en/migration/migration280to290.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
= v2.8.0 → v2.9.0

coff:ee v2.8.0 -> v2.9.0 migration description, news, changes

=== coffee-module-notification
The commons-email was updated to a Jakarta-compatible release, and the module has been re-enabled.
1 change: 1 addition & 0 deletions docs/hu/migration.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ include::migration/migration240to250.adoc[leveloffset=+1]
include::migration/migration250to260.adoc[leveloffset=+1]
include::migration/migration260to270.adoc[leveloffset=+1]
include::migration/migration270to280.adoc[leveloffset=+1]
include::migration/migration280to290.adoc[leveloffset=+1]
6 changes: 6 additions & 0 deletions docs/hu/migration/migration280to290.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
= v2.8.0 → v2.9.0

coff:ee v2.8.0 -> v2.9.0 migrációs leírás, újdonságok, változások leírása

=== coffee-module-notification
Frissítésre került a commons-email jakarta kompatibilis release, így ez a modul visszakcsolásra került.
rombow marked this conversation as resolved.
Show resolved Hide resolved