Skip to content

Commit b3a658e

Browse files
author
Greg Meyer
authored
Merge pull request #4 from DirectProjectJavaRI/develop
Releasing 8.0.0
2 parents b5285a1 + 8ec591d commit b3a658e

13 files changed

+109
-112
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,4 @@
2323
hs_err_pid*
2424
/.classpath
2525
/.project
26+
/target/

pom.xml

Lines changed: 55 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<modelVersion>4.0.0</modelVersion>
55
<artifactId>direct-msg-monitor-model</artifactId>
66
<name>Direct Project Message Monitor Data Model Objects</name>
7-
<version>6.0</version>
7+
<version>8.0.0</version>
88
<description>Direct Project Message Monitor Data Model Objects</description>
99
<inceptionYear>2018</inceptionYear>
1010
<url>https://github.com/DirectProjectJavaRI/direct-msg-monitor-model</url>
@@ -23,38 +23,48 @@
2323
<url>http://nhindirect.org</url>
2424
</organization>
2525
<prerequisites>
26-
<maven>3.0.0</maven>
26+
<maven>3.5.0</maven>
2727
</prerequisites>
2828
<parent>
2929
<groupId>org.springframework.boot</groupId>
3030
<artifactId>spring-boot-dependencies</artifactId>
31-
<version>2.1.2.RELEASE</version>
32-
</parent>
33-
<scm>
34-
<url>scm:git:https://github.com/DirectProjectJavaRI/direct-msg-monitor-model.git</url>
35-
<connection>scm:git:https://github.com/DirectProjectJavaRI/direct-msg-monitor-model.git</connection>
36-
</scm>
37-
<licenses>
38-
<license>
31+
<version>2.5.2</version>
32+
<relativePath />
33+
</parent>
34+
<scm>
35+
<url>scm:git:https://github.com/DirectProjectJavaRI/direct-msg-monitor-model.git</url>
36+
<connection>scm:git:https://github.com/DirectProjectJavaRI/direct-msg-monitor-model.git</connection>
37+
</scm>
38+
<licenses>
39+
<license>
3940
<name>New BSD License</name>
4041
<url>http://nhindirect.org/BSDLicense</url>
41-
</license>
42-
</licenses>
42+
</license>
43+
</licenses>
44+
<properties>
45+
<javax-mail.version>1.6.2</javax-mail.version>
46+
<dsn.version>1.6.7</dsn.version>
47+
<commons-io.version>2.8.0</commons-io.version>
48+
</properties>
4349
<dependencies>
4450
<dependency>
4551
<groupId>org.nhind</groupId>
4652
<artifactId>direct-common</artifactId>
47-
<version>6.0</version>
53+
<version>8.0.0</version>
4854
</dependency>
4955
<dependency>
50-
<groupId>javax.mail</groupId>
51-
<artifactId>mail</artifactId>
52-
<version>1.4.3</version>
53-
</dependency>
56+
<groupId>org.projectlombok</groupId>
57+
<artifactId>lombok</artifactId>
58+
</dependency>
59+
<dependency>
60+
<groupId>com.sun.mail</groupId>
61+
<artifactId>javax.mail</artifactId>
62+
<version>${javax-mail.version}</version>
63+
</dependency>
5464
<dependency>
5565
<groupId>com.sun.mail</groupId>
5666
<artifactId>dsn</artifactId>
57-
<version>1.4.3</version>
67+
<version>${dsn.version}</version>
5868
</dependency>
5969
<dependency>
6070
<groupId>org.apache.commons</groupId>
@@ -63,34 +73,31 @@
6373
<dependency>
6474
<groupId>commons-io</groupId>
6575
<artifactId>commons-io</artifactId>
66-
<version>2.6</version>
76+
<version>${commons-io.version}</version>
6777
</dependency>
6878
<dependency>
6979
<groupId>com.fasterxml.jackson.core</groupId>
7080
<artifactId>jackson-annotations</artifactId>
7181
</dependency>
72-
<dependency>
73-
<groupId>junit</groupId>
74-
<artifactId>junit</artifactId>
75-
<scope>test</scope>
76-
</dependency>
82+
<dependency>
83+
<groupId>org.junit.jupiter</groupId>
84+
<artifactId>junit-jupiter-engine</artifactId>
85+
<scope>test</scope>
86+
</dependency>
7787
</dependencies>
7888
<build>
7989
<extensions>
8090
<extension>
8191
<groupId>org.apache.maven.wagon</groupId>
8292
<artifactId>wagon-webdav-jackrabbit</artifactId>
83-
<version>3.1.0</version>
8493
</extension>
8594
<extension>
8695
<groupId>org.apache.maven.wagon</groupId>
8796
<artifactId>wagon-ssh-external</artifactId>
88-
<version>3.1.0</version>
8997
</extension>
9098
<extension>
9199
<groupId>org.apache.maven.wagon</groupId>
92100
<artifactId>wagon-ssh</artifactId>
93-
<version>3.1.0</version>
94101
</extension>
95102
</extensions>
96103
<resources>
@@ -119,6 +126,7 @@
119126
<plugin>
120127
<groupId>org.apache.maven.plugins</groupId>
121128
<artifactId>maven-jxr-plugin</artifactId>
129+
<version>3.1.1</version>
122130
</plugin>
123131
<plugin>
124132
<groupId>org.apache.maven.plugins</groupId>
@@ -151,32 +159,27 @@
151159
</execution>
152160
</executions>
153161
</plugin>
154-
<plugin>
155-
<groupId>org.apache.maven.plugins</groupId>
156-
<artifactId>maven-jar-plugin</artifactId>
157-
<configuration>
158-
<archive>
159-
<index>true</index>
160-
</archive>
161-
</configuration>
162-
</plugin>
163-
<plugin>
164-
<groupId>org.apache.maven.plugins</groupId>
165-
<artifactId>maven-jar-plugin</artifactId>
166-
<executions>
167-
<execution>
168-
<goals>
169-
<goal>test-jar</goal>
170-
</goals>
171-
</execution>
172-
</executions>
173-
</plugin>
162+
<plugin>
163+
<groupId>org.apache.maven.plugins</groupId>
164+
<artifactId>maven-jar-plugin</artifactId>
165+
<configuration>
166+
<archive>
167+
<index>true</index>
168+
</archive>
169+
</configuration>
170+
<executions>
171+
<execution>
172+
<goals>
173+
<goal>test-jar</goal>
174+
</goals>
175+
</execution>
176+
</executions>
177+
</plugin>
174178
<plugin>
175179
<groupId>org.apache.maven.plugins</groupId>
176180
<artifactId>maven-javadoc-plugin</artifactId>
177-
<version>2.6.1</version>
178181
<configuration>
179-
<additionalparam>-Xdoclint:none</additionalparam>
182+
<additionalJOption>-Xdoclint:none</additionalJOption>
180183
<charset>UTF-8</charset>
181184
<docencoding>UTF-8</docencoding>
182185
<docfilessubdirs>true</docfilessubdirs>
@@ -211,6 +214,7 @@
211214
</goals>
212215
</execution>
213216
</executions>
217+
<version>3.0.1</version>
214218
</plugin>
215219
-->
216220
</plugins>
@@ -220,14 +224,12 @@
220224
<plugin>
221225
<groupId>org.apache.maven.plugins</groupId>
222226
<artifactId>maven-project-info-reports-plugin</artifactId>
223-
<version>2.9</version>
224227
</plugin>
225228
<plugin>
226229
<groupId>org.apache.maven.plugins</groupId>
227230
<artifactId>maven-javadoc-plugin</artifactId>
228-
<version>2.6.1</version>
229231
<configuration>
230-
<additionalparam>-Xdoclint:none</additionalparam>
232+
<additionalJOption>-Xdoclint:none</additionalJOption>
231233
<charset>UTF-8</charset>
232234
<docencoding>UTF-8</docencoding>
233235
<docfilessubdirs>true</docfilessubdirs>
@@ -254,6 +256,7 @@
254256
<plugin>
255257
<groupId>org.apache.maven.plugins</groupId>
256258
<artifactId>maven-jxr-plugin</artifactId>
259+
<version>3.1.1</version>
257260
</plugin>
258261
<plugin>
259262
<groupId>org.codehaus.mojo</groupId>

src/main/java/org/nhindirect/common/tx/TxUtil.java

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,6 @@ STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
2929
import javax.mail.internet.MimeMessage;
3030
import javax.mail.internet.ParseException;
3131

32-
import org.apache.commons.logging.Log;
33-
import org.apache.commons.logging.LogFactory;
3432
import org.nhindirect.common.mail.MDNStandard;
3533
import org.nhindirect.common.mail.SMIMEStandard;
3634
import org.nhindirect.common.mail.dsn.DSNStandard;
@@ -40,18 +38,17 @@ STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
4038
import org.nhindirect.common.tx.model.TxDetailType;
4139
import org.nhindirect.common.tx.model.TxMessageType;
4240

41+
import lombok.extern.slf4j.Slf4j;
42+
4343

4444
/**
4545
* Utility class for message monitoring
4646
* @author Greg Meyer
4747
* @since 1.1
4848
*/
49+
@Slf4j
4950
public class TxUtil
5051
{
51-
@SuppressWarnings("deprecation")
52-
private static final Log LOGGER = LogFactory.getFactory().getInstance(TxUtil.class);
53-
54-
5552
/**
5653
* Gets the message type based on the content type headers.
5754
* @param msg The message to extract the type from.
@@ -87,11 +84,11 @@ else if (contentType.match(SMIMEStandard.EncryptedContentMediaType) ||
8784
///CLOVER:OFF
8885
catch (ParseException e)
8986
{
90-
LOGGER.warn("Failed to discern message type.", e);
87+
log.warn("Failed to discern message type.", e);
9188
}
9289
catch (MessagingException e)
9390
{
94-
LOGGER.warn("Failed to discern message type.", e);
91+
log.warn("Failed to discern message type.", e);
9592
}
9693
return TxMessageType.UNKNOWN;
9794
///CLOVER:ON

src/main/java/org/nhindirect/common/tx/impl/DefaultTxDetailParser.java

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,6 @@ STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
3535
import javax.mail.internet.InternetHeaders;
3636
import javax.mail.internet.MimeMessage;
3737

38-
import org.apache.commons.logging.Log;
39-
import org.apache.commons.logging.LogFactory;
4038
import org.nhindirect.common.mail.MDNStandard;
4139
import org.nhindirect.common.mail.MailStandard;
4240
import org.nhindirect.common.mail.MailUtil;
@@ -49,15 +47,14 @@ STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
4947

5048
import com.sun.mail.dsn.DeliveryStatus;
5149

50+
import lombok.extern.slf4j.Slf4j;
51+
52+
@Slf4j
5253
public class DefaultTxDetailParser implements TxDetailParser
53-
{
54-
@SuppressWarnings("deprecation")
55-
private static final Log LOGGER = LogFactory.getFactory().getInstance(DefaultTxDetailParser.class);
56-
54+
{
5755
/**
5856
* {@inheritDoc}
5957
*/
60-
@SuppressWarnings("unchecked")
6158
@Override
6259
public Map<String, TxDetail> getMessageDetails(InternetHeaders headers)
6360
{
@@ -78,7 +75,7 @@ public Map<String, TxDetail> getMessageDetails(InternetHeaders headers)
7875
catch (MessagingException e)
7976
{
8077

81-
LOGGER.warn("Failed to translate headers to MimeMessage.", e);
78+
log.warn("Failed to translate headers to MimeMessage.", e);
8279

8380
}
8481
///CLOVER:ON
@@ -104,7 +101,7 @@ public Map<String, TxDetail> getMessageDetails(InputStream stream)
104101
catch (MessagingException e)
105102
{
106103

107-
LOGGER.warn("Failed to translate input stream into MimeMessage.", e);
104+
log.warn("Failed to translate input stream into MimeMessage.", e);
108105

109106
}
110107
///CLOVER:ON
@@ -158,7 +155,7 @@ public Map<String, TxDetail> getMessageDetails(MimeMessage msg)
158155
/// CLOVER:OFF
159156
catch (MessagingException e)
160157
{
161-
LOGGER.warn("Failed to retrieve message sender list.", e);
158+
log.warn("Failed to retrieve message sender list.", e);
162159
}
163160
/// CLOVER:ON
164161

@@ -173,7 +170,7 @@ public Map<String, TxDetail> getMessageDetails(MimeMessage msg)
173170
/// CLOVER:OFF
174171
catch (MessagingException e)
175172
{
176-
LOGGER.warn("Failed to retrieve message sender", e);
173+
log.warn("Failed to retrieve message sender", e);
177174
}
178175
/// CLOVER:ON
179176

@@ -204,7 +201,7 @@ public Map<String, TxDetail> getMessageDetails(MimeMessage msg)
204201
/// CLOVER:OFF
205202
catch (MessagingException e)
206203
{
207-
LOGGER.warn("Failed to retrieve message recipient list.", e);
204+
log.warn("Failed to retrieve message recipient list.", e);
208205
}
209206
/// CLOVER:ON
210207

@@ -253,7 +250,7 @@ public Map<String, TxDetail> getMessageDetails(MimeMessage msg)
253250
// CLOVER:OFF
254251
catch (Exception e)
255252
{
256-
LOGGER.warn("Failed to retrieve MDN headers from message. Message may not be an MDN message.", e);
253+
log.warn("Failed to retrieve MDN headers from message. Message may not be an MDN message.", e);
257254
}
258255
// CLOVER:ON
259256
break;
@@ -300,7 +297,7 @@ public Map<String, TxDetail> getMessageDetails(MimeMessage msg)
300297
///CLOVER:OFF
301298
catch (Exception e)
302299
{
303-
LOGGER.warn("Could not get a requested field from the DSN message", e);
300+
log.warn("Could not get a requested field from the DSN message", e);
304301
}
305302
///CLOVER:ON
306303
break;
@@ -322,7 +319,6 @@ protected String getHeadersAsStringInternal(MimeMessage msg)
322319
return getHeadersAsString(msg);
323320
}
324321

325-
@SuppressWarnings("unchecked")
326322
public static String getHeadersAsString(MimeMessage msg)
327323
{
328324
StringBuilder builder = new StringBuilder();
@@ -338,7 +334,7 @@ public static String getHeadersAsString(MimeMessage msg)
338334
{
339335
// According to most SE runtimes, getAllHeaderLines will never thrown a MessagingException
340336

341-
LOGGER.warn("Failed to builder message summary.", e);
337+
log.warn("Failed to builder message summary.", e);
342338

343339
}
344340
///CLOVER:ON

0 commit comments

Comments
 (0)