Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
CHANGELOG_START_TAG=mstor-1.0.0
CHANGELOG_START_TAG=mstor-1.0.2
CHANGELOG_END_TAG=HEAD

GRADLE_VERSION=6.9.1
GRADLE_VERSION=7.6
17 changes: 17 additions & 0 deletions .github/workflows/publish-site.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: publish-site
on:
push:
branches:
- master
- feature/refactor
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: 3.x
- run: pip install mkdocs-material
- run: mkdocs gh-deploy --force

1 change: 1 addition & 0 deletions .github/workflows/publish-snapshots.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
push:
branches:
- 'develop'
- 'feature/refactor'

jobs:
gradle:
Expand Down
6 changes: 3 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
/target
target
/.settings
/.classpath
/.project
/build
/.gradle
build
.gradle
/bin
.idea
mstor.iml
25 changes: 0 additions & 25 deletions .travis.yml

This file was deleted.

3 changes: 2 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
SHELL:=/bin/bash
include .env

NEXT_VERSION=$(wordlist 2,$(words $(MAKECMDGOALS)),$(MAKECMDGOALS))

.PHONY: all gradlew clean build changelog currentVersion markNextVersion verify release publish

all: test
Expand All @@ -25,7 +27,6 @@ currentVersion:
./gradlew -q currentVersion

markNextVersion:
NEXT_VERSION=$(wordlist 2,$(words $(MAKECMDGOALS)),$(MAKECMDGOALS))
./gradlew markNextVersion -Prelease.version=$(NEXT_VERSION)

verify:
Expand Down
50 changes: 23 additions & 27 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ buildscript {
}

plugins {
id 'java'
id 'java-library'
id 'pl.allegro.tech.build.axion-release' version '1.13.3'
id "nebula.provided-base" version "3.0.3"
id "nebula.provided-base" version "7.0.0"
id "biz.aQute.bnd.builder" version "$bndVersion"
}

apply plugin: 'java'
apply plugin: 'java-library'
apply plugin: 'eclipse'
apply plugin: 'groovy'
//apply plugin: 'checkstyle'
Expand Down Expand Up @@ -46,7 +46,7 @@ repositories {
}

dependencies {
api "com.sun.mail:jakarta.mail:$jakartaMailVersion",
api "jakarta.mail:jakarta.mail-api:$jakartaMailVersion",
"org.slf4j:slf4j-api:$slf4jVersion"

implementation "org.apache.commons:commons-lang3:$commonsLangVersion",
Expand All @@ -62,13 +62,13 @@ dependencies {
"cglib:cglib:$cglibVersion",
"org.slf4j:jul-to-slf4j:$slf4jVersion", "org.slf4j:jcl-over-slf4j:$slf4jVersion",
"org.apache.jackrabbit:jackrabbit-jcr-rmi:$jackrabbitVersion"

implementation "org.jparsec:jparsec:$jparsecVersion", optional

// used in javadoc generation..
compileOnly 'biz.aQute.bnd:bndlib:2.4.0'

runtime "commons-logging:commons-logging:$commonsLoggingVersion"
runtimeOnly "commons-logging:commons-logging:$commonsLoggingVersion"

testImplementation "org.apache.jackrabbit:jackrabbit-core:$jackrabbitVersion",
"junit:junit:$junitVersion",
Expand All @@ -80,6 +80,15 @@ dependencies {
// spock
testImplementation platform("org.spockframework:spock-bom:2.0-M4-groovy-3.0"),
"org.spockframework:spock-core"

// testcontainers
testImplementation "org.testcontainers:testcontainers:$testcontainersVersion",
"org.testcontainers:spock:$testcontainersVersion"
}

java {
withJavadocJar()
withSourcesJar()
}

jacocoTestReport {
Expand All @@ -98,35 +107,22 @@ javadoc {
}
}

task javadocJar(type: Jar, dependsOn: javadoc) {
archiveClassifier.set('javadoc')
from 'build/docs/javadoc'
}

task sourcesJar(type: Jar) {
from sourceSets.main.allSource
archiveClassifier.set('sources')
}

artifacts {
archives jar
archives javadocJar
archives sourcesJar
}

scmVersion {
tag {
prefix = 'mstor-'
}
versionCreator 'versionWithBranch'
branchVersionCreator = ['master': 'simple']
branchVersionCreator = [
'master': 'simple',
'feature/refactor': 'simple'
]
nextVersion {
suffix = 'pre'
separator = '-'
}
}

group = 'org.mnode.mstor'
group = 'org.mstor'
description = '''
An mbox provider for JavaMail
'''
Expand All @@ -137,6 +133,8 @@ ext {
}

test {
useJUnitPlatform()

include '**/*Test.class'
include '**/*Spec.class'

Expand All @@ -159,8 +157,6 @@ publishing {
publications {
mstor(MavenPublication) {
from components.java
artifact javadocJar
artifact sourcesJar
pom.withXml {
asNode().appendNode('name', project.name)
asNode().appendNode('description', project.description)
Expand All @@ -186,7 +182,7 @@ publishing {
repositories {
maven {
name = "OSSRH"
url = !isReleaseVersion ? "https://oss.sonatype.org/content/repositories/snapshots/" : "https://oss.sonatype.org/service/local/staging/deploy/maven2/"
url = !isReleaseVersion ? "https://s01.oss.sonatype.org/content/repositories/snapshots/" : "https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/"
credentials {
username = System.getenv("MAVEN_USERNAME")
password = System.getenv("MAVEN_PASSWORD")
Expand Down
1 change: 1 addition & 0 deletions docs/CNAME
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
www.mstor.org
Binary file added docs/images/cherry.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/mnode_logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
31 changes: 31 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# mStor - Universal message archival and storage

mStor is a Java library that supports persistence of various forms of digital communications, such as Email
and Instant Messaging.

## Overview

Messaging specifications typically define encoding and metadata, but are relatively agnostic to the content.
So too is mStor, which focuses on supporting persistence of metadata and a suitably encoded message body.

## JavaMail

The origins of mStor are as a JavaMail provider for the unofficial mbox specification. JavaMail is still
supported, however the intention is to also support storage of other communications such as Instant
Messaging via a universal API. This would theoretically allow messages to be stored and retrieved as either
Email or Instant Messaging interchangeably.

## JMAP

JMAP is a relatively new API from Fastmail, designed to support Web-based Email clients.

## Tinkerpop

Tinkerpop is an open API for interacting with graph databases. This is potentially useful for capturing
relationships between messages, senders and recipients, and can support powerful analytics and reporting
on large data sets.

## DynamoDB

DynamoDB is a highly scalable NoSQL database from AWS. It can efficiently store large amounts of metadata
and efficiently query on a well-designed schema.
2 changes: 2 additions & 0 deletions docs/javamail.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# MStor Javamail Provider

9 changes: 0 additions & 9 deletions etc/plugin.xml

This file was deleted.

14 changes: 8 additions & 6 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,20 +1,22 @@
jakartaMailVersion = 1.6.7
slf4jVersion = 1.7.32
groovyVersion = 3.0.8
jakartaMailVersion = 2.1.1
slf4jVersion = 2.0.7
groovyVersion = 3.0.17
commonsLangVersion = 3.12.0
commonsNetVersion = 3.8.0
commonsIoVersion = 2.11.0
commonsLoggingVersion = 1.2
cglibVersion = 3.3.0
jdomVersion = 1.1
xstreamVersion = 1.4.18
xstreamVersion = 1.4.19
jyamlVersion = 1.3
jcrVersion = 2.0
jcromVersion = 2.2.0
ehcacheVersion = 2.6.11
jparsecVersion = 3.1

bndVersion = 6.1.0
jackrabbitVersion = 2.21.9
jackrabbitVersion = 2.21.10
logbackVersion = 1.2.10
junitVersion = '4.13'

testcontainersVersion = 1.16.2
bndVersion = 6.3.1
Binary file modified gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.9.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-7.6-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
2 changes: 1 addition & 1 deletion gradlew
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ fi
if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`

JAVACMD=`cygpath --unix "$JAVACMD"`

# We build the pattern for arguments to be converted via cygpath
Expand Down
21 changes: 3 additions & 18 deletions gradlew.bat
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ if defined JAVA_HOME goto findJavaFromJavaHome

set JAVA_EXE=java.exe
%JAVA_EXE% -version >NUL 2>&1
if "%ERRORLEVEL%" == "0" goto init
if "%ERRORLEVEL%" == "0" goto execute

echo.
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
Expand All @@ -54,7 +54,7 @@ goto fail
set JAVA_HOME=%JAVA_HOME:"=%
set JAVA_EXE=%JAVA_HOME%/bin/java.exe

if exist "%JAVA_EXE%" goto init
if exist "%JAVA_EXE%" goto execute

echo.
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
Expand All @@ -64,29 +64,14 @@ echo location of your Java installation.

goto fail

:init
@rem Get command-line arguments, handling Windows variants

if not "%OS%" == "Windows_NT" goto win9xME_args

:win9xME_args
@rem Slurp the command line arguments.
set CMD_LINE_ARGS=
set _SKIP=2

:win9xME_args_slurp
if "x%~1" == "x" goto execute

set CMD_LINE_ARGS=%*

:execute
@rem Setup the command line

set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar


@rem Execute Gradle
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*

:end
@rem End local scope for the variables with windows NT shell
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
package net.fortuna.mstor
package org.mstor.provider.mail

import javax.mail.Message.RecipientType
import javax.mail.internet.InternetAddress
import jakarta.mail.Message.RecipientType
import jakarta.mail.internet.InternetAddress

class InternetAddressFactory extends AbstractFactory {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
package net.fortuna.mstor
package org.mstor.provider.mail

import javax.mail.Message.RecipientType
import jakarta.mail.Message.RecipientType

class MessageBuilder extends FactoryBuilderSupport {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
package net.fortuna.mstor
package org.mstor.provider.mail

import javax.mail.Session
import javax.mail.internet.MimeMessage
import jakarta.mail.Session
import jakarta.mail.internet.MimeMessage

class MimeMessageFactory extends AbstractFactory {

Expand Down
Loading