Skip to content

Commit e9e97f5

Browse files
committed
Preparing for release.
1 parent 6142f68 commit e9e97f5

File tree

7 files changed

+18
-10
lines changed

7 files changed

+18
-10
lines changed

norconex-committer-sql/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<modelVersion>4.0.0</modelVersion>
2020
<groupId>com.norconex.collectors</groupId>
2121
<artifactId>norconex-committer-sql</artifactId>
22-
<version>1.0.0-SNAPSHOT</version>
22+
<version>1.0.0</version>
2323
<name>Norconex Committer SQL</name>
2424
<description>SQL database implementation of Norconex Committer.</description>
2525

norconex-committer-sql/src/changes/changes.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
</properties>
88
<body>
99

10-
<release version="1.0.0-SNAPSHOT" date="2017-??-??" description="Initial release">
10+
<release version="1.0.0" date="2017-05-25" description="Initial release">
1111
<action dev="essiembre" type="add">
1212
Initial release.
1313
</action>

norconex-committer-sql/src/main/assembly/dist.xml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,6 @@
4040
</fileSet>
4141
<fileSet>
4242
<directory>${project.build.directory}/shared-resources</directory>
43-
<excludes>
44-
<exclude>scripts/decrypt*</exclude>
45-
<exclude>scripts/encrypt*</exclude>
46-
</excludes>
4743
<outputDirectory>/</outputDirectory>
4844
</fileSet>
4945
<fileSet>

norconex-committer-sql/src/main/java/com/norconex/committer/sql/SQLCommitter.java

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,10 @@
145145
* (Optional SQL for creating missing table if not found.
146146
* Default uses a predefined SQL.)
147147
* &lt;/createTableSQL&gt;
148+
* &lt;multiValuesJoiner&gt;
149+
* (One or more characters to join multi-value fields.
150+
* Default is "|".)
151+
* &lt;/multiValuesJoiner&gt;
148152
*
149153
* &lt;!-- Use the following if authentication is required. --&gt;
150154
* &lt;username&gt;(Optional user name)&lt;/username&gt;
@@ -193,10 +197,16 @@
193197
*
194198
* <h4>Usage example:</h4>
195199
* <p>
196-
* The following example uses the minimum required settings:.
200+
* The following example uses an H2 database and creates fields as
201+
* they are encountered.
197202
* </p>
198203
* <pre>
199204
* &lt;committer class="com.norconex.committer.sql.SQLCommitter"&gt;
205+
* &lt;driverPath&gt;/path/to/driver/h2.jar&lt;/driverPath&gt;
206+
* &lt;driverClass&gt;org.h2.Driver&lt;/driverClass&gt;
207+
* &lt;connectionUrl&gt;jdbc:h2:file:///path/to/db/h2&lt;/connectionUrl&gt;
208+
* &lt;tableName&gt;test_table&lt;/tableName&gt;
209+
* &lt;createMissing&gt;true&lt;/createMissing&gt;
200210
* &lt;/committer&gt;
201211
* </pre>
202212
*
@@ -214,8 +224,7 @@ public class SQLCommitter extends AbstractMappedCommitter {
214224
public static final String DEFAULT_MULTI_VALUES_JOINER = "|";
215225

216226
private static final String[] NO_REFLECT_FIELDS = new String[] {
217-
"existingFields", "tableVerified", "tableExists",
218-
"multiValuesJoiner", "datasource"
227+
"existingFields", "tableVerified", "tableExists", "datasource"
219228
};
220229

221230
private String driverPath;
@@ -664,5 +673,5 @@ public String toString() {
664673
return new ReflectionToStringBuilder(this,
665674
ToStringStyle.SHORT_PREFIX_STYLE).setExcludeFieldNames(
666675
NO_REFLECT_FIELDS).toString();
667-
}
676+
}
668677
}

norconex-committer-sql/src/main/java/com/norconex/committer/sql/SQLCommitter.xsd

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@
2929
<xs:element name="driverPath" type="nonEmptyString" minOccurs="0" maxOccurs="1" />
3030
<xs:element ref="properties" minOccurs="0" maxOccurs="1" />
3131
<xs:element name="createTableSQL" type="nonEmptyString" minOccurs="0" maxOccurs="1" />
32+
<xs:element name="multiValuesJoiner" type="xs:string" minOccurs="0" maxOccurs="1" />
3233
<xs:element name="username" type="nonEmptyString" minOccurs="0" maxOccurs="1" />
3334
<xs:element name="password" type="nonEmptyString" minOccurs="0" maxOccurs="1" />
3435
<xs:element name="passwordKey" type="nonEmptyString" minOccurs="0" maxOccurs="1" />

norconex-committer-sql/src/test/java/com/norconex/committer/sql/SQLCommitterConfigTest.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ public void testWriteRead() throws Exception {
4646
committer.setCreateMissing(true);
4747
committer.setToUppercase(true);
4848
committer.setCreateTableSQL("createTableSQL");
49+
committer.setMultiValuesJoiner("^");
4950

5051
committer.setQueueDir("my-queue-dir");
5152
committer.setSourceContentField("sourceContentField");

norconex-committer-sql/src/test/java/com/norconex/committer/sql/SQLCommitterConfigTest.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
<toUppercase>true</toUppercase>
2828
<createMissing>true</createMissing>
2929
<createTableSQL>CREATE TABLE blah</createTableSQL>
30+
<multiValuesJoiner>^^</multiValuesJoiner>
3031
<username>joe</username>
3132
<password>password</password>
3233
<passwordKey>/some/file</passwordKey>

0 commit comments

Comments
 (0)