From c515c91af1de53bd8fdee8aa04342c2696c26bda Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Tue, 27 Jun 2017 00:17:58 +0200 Subject: [PATCH] Don't cherry-pick: - need to provide email queues for these EJBs as they will attempt to call sendEmail() which would then throw a NPE: MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit ---------------------------- Caused by: java.lang.NullPointerException at org.mxchange.jfinancials.database.BaseFinancialsDatabaseBean.sendEmail(BaseFinancialsDatabaseBean.java:555) at org.mxchange.jusercore.model.user.register.FinancialsUserRegistrationSessionBean.registerUser(FinancialsUserRegistrationSessionBean.java:208) ---------------------------- However, I will expand sendEmail() a bit to verify that the field session is really there and not run in such ugly NPE. Signed-off-by: Roland Häder --- .../model/delivery/FinancialsEmailDeliveryMessageBean.java | 2 +- .../jusercore/model/user/FinancialsAdminUserSessionBean.java | 2 +- .../jusercore/model/user/FinancialsUserSessionBean.java | 2 +- .../email_address/FinancialsUserEmailChangeSessionBean.java | 2 +- .../user/register/FinancialsUserRegistrationSessionBean.java | 2 +- .../model/user/resendlink/FinancialsResendLinkSessionBean.java | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/java/org/mxchange/jfinancials/mailer/model/delivery/FinancialsEmailDeliveryMessageBean.java b/src/java/org/mxchange/jfinancials/mailer/model/delivery/FinancialsEmailDeliveryMessageBean.java index 51f5ba3..12913db 100644 --- a/src/java/org/mxchange/jfinancials/mailer/model/delivery/FinancialsEmailDeliveryMessageBean.java +++ b/src/java/org/mxchange/jfinancials/mailer/model/delivery/FinancialsEmailDeliveryMessageBean.java @@ -65,7 +65,7 @@ public class FinancialsEmailDeliveryMessageBean extends BaseFinancialsDatabaseBe */ public FinancialsEmailDeliveryMessageBean () { // Call super constructor - super("jms/jfinancials-queue-factory", "jms/jfinancials-email-queue"); //NOI18N + super(); // Init mailer instance this.mailer = new FinancialsMailer(); diff --git a/src/java/org/mxchange/jusercore/model/user/FinancialsAdminUserSessionBean.java b/src/java/org/mxchange/jusercore/model/user/FinancialsAdminUserSessionBean.java index 5ec021e..48d5157 100644 --- a/src/java/org/mxchange/jusercore/model/user/FinancialsAdminUserSessionBean.java +++ b/src/java/org/mxchange/jusercore/model/user/FinancialsAdminUserSessionBean.java @@ -65,7 +65,7 @@ public class FinancialsAdminUserSessionBean extends BaseFinancialsDatabaseBean i */ public FinancialsAdminUserSessionBean () { // Call super constructor - super(); + super("jms/jfinancials-queue-factory", "jms/jfinancials-email-queue"); //NOI18N } @Override diff --git a/src/java/org/mxchange/jusercore/model/user/FinancialsUserSessionBean.java b/src/java/org/mxchange/jusercore/model/user/FinancialsUserSessionBean.java index 2e3d3c4..a90fd6c 100644 --- a/src/java/org/mxchange/jusercore/model/user/FinancialsUserSessionBean.java +++ b/src/java/org/mxchange/jusercore/model/user/FinancialsUserSessionBean.java @@ -71,7 +71,7 @@ public class FinancialsUserSessionBean extends BaseFinancialsDatabaseBean implem */ public FinancialsUserSessionBean () { // Call super constructor - super(); + super("jms/jfinancials-queue-factory", "jms/jfinancials-email-queue"); //NOI18N } @Override diff --git a/src/java/org/mxchange/jusercore/model/user/email_address/FinancialsUserEmailChangeSessionBean.java b/src/java/org/mxchange/jusercore/model/user/email_address/FinancialsUserEmailChangeSessionBean.java index 9f98d1a..3fc67d4 100644 --- a/src/java/org/mxchange/jusercore/model/user/email_address/FinancialsUserEmailChangeSessionBean.java +++ b/src/java/org/mxchange/jusercore/model/user/email_address/FinancialsUserEmailChangeSessionBean.java @@ -57,7 +57,7 @@ public class FinancialsUserEmailChangeSessionBean extends BaseFinancialsDatabase */ public FinancialsUserEmailChangeSessionBean () { // Call super constructor - super(); + super("jms/jfinancials-queue-factory", "jms/jfinancials-email-queue"); //NOI18N } @Override diff --git a/src/java/org/mxchange/jusercore/model/user/register/FinancialsUserRegistrationSessionBean.java b/src/java/org/mxchange/jusercore/model/user/register/FinancialsUserRegistrationSessionBean.java index aa20d2f..7a52540 100644 --- a/src/java/org/mxchange/jusercore/model/user/register/FinancialsUserRegistrationSessionBean.java +++ b/src/java/org/mxchange/jusercore/model/user/register/FinancialsUserRegistrationSessionBean.java @@ -66,7 +66,7 @@ public class FinancialsUserRegistrationSessionBean extends BaseFinancialsDatabas */ public FinancialsUserRegistrationSessionBean () { // Call super constructor - super(); + super("jms/jfinancials-queue-factory", "jms/jfinancials-email-queue"); //NOI18N } @Override diff --git a/src/java/org/mxchange/jusercore/model/user/resendlink/FinancialsResendLinkSessionBean.java b/src/java/org/mxchange/jusercore/model/user/resendlink/FinancialsResendLinkSessionBean.java index 187abcd..fa9a07d 100644 --- a/src/java/org/mxchange/jusercore/model/user/resendlink/FinancialsResendLinkSessionBean.java +++ b/src/java/org/mxchange/jusercore/model/user/resendlink/FinancialsResendLinkSessionBean.java @@ -63,7 +63,7 @@ public class FinancialsResendLinkSessionBean extends BaseFinancialsDatabaseBean */ public FinancialsResendLinkSessionBean () { // Call super constructor - super(); + super("jms/jfinancials-queue-factory", "jms/jfinancials-email-queue"); //NOI18N } @Override -- 2.39.5