Skip to content

Commit

Permalink
Prepare release 4.9.0
Browse files Browse the repository at this point in the history
- Add package-info.java for each package
- Improve Javadoc in optionset package
- Bump version
  • Loading branch information
maximevw committed Apr 15, 2023
1 parent be8e146 commit 2202725
Show file tree
Hide file tree
Showing 10 changed files with 96 additions and 18 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) and this project adheres to
[Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## Unreleased
## [4.9.0] - 2023-04-15
### Added
- Add non-JDBC standard [JSON support](https://cassandra.apache.org/doc/latest/cassandra/cql/json.html) with the
methods `getObjectFromJson(int | String, Class)` and `getObjectFromJson(Class)` in `CassandraResultSet` and
Expand Down Expand Up @@ -121,6 +121,7 @@ For this version, the changelog lists the main changes comparatively to the late
- Fix logs in `CassandraConnection` constructor.

[original project]: https://github.com/adejanovski/cassandra-jdbc-wrapper/
[4.9.0]: https://github.com/ing-bank/cassandra-jdbc-wrapper/compare/v4.8.0...v4.9.0
[4.8.0]: https://github.com/ing-bank/cassandra-jdbc-wrapper/compare/v4.7.0...v4.8.0
[4.7.0]: https://github.com/ing-bank/cassandra-jdbc-wrapper/compare/v4.6.0...v4.7.0
[4.6.0]: https://github.com/ing-bank/cassandra-jdbc-wrapper/compare/v4.5.0...v4.6.0
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

<groupId>com.ing.data</groupId>
<artifactId>cassandra-jdbc-wrapper</artifactId>
<version>4.8.0</version>
<version>4.9.0</version>
<packaging>jar</packaging>

<name>Cassandra JDBC Wrapper</name>
Expand Down
19 changes: 19 additions & 0 deletions src/main/java/com/ing/data/cassandra/jdbc/codec/package-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

/**
* This package contains the codec classes to handle conversions between CQL types and Java types.
*/
package com.ing.data.cassandra.jdbc.codec;
19 changes: 19 additions & 0 deletions src/main/java/com/ing/data/cassandra/jdbc/json/package-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

/**
* This package contains the classes used to manage serialization and deserialization for JSON support.
*/
package com.ing.data.cassandra.jdbc.json;
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public abstract class AbstractOptionSet implements OptionSet {

@Override
public CassandraConnection getConnection() {
return connection;
return this.connection;
}

public void setConnection(final CassandraConnection connection) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,8 @@
import java.sql.Statement;

/**
* Default Option set.
* Default option set implementing the methods of {@code OptionSet} accordingly to the JDBC API standard.
*/

public class Default extends AbstractOptionSet {
private static final Logger LOG = LoggerFactory.getLogger(AbstractOptionSet.class);

Expand All @@ -50,4 +49,5 @@ public String getCatalog() {
public int getSQLUpdateResponse() {
return 0;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,10 @@
package com.ing.data.cassandra.jdbc.optionset;

/**
* Option Set for liquibase compatibility and flavour of JDBC.
* Option set implementation for Liquibase compatibility and flavour of JDBC.
*/
public class Liquibase extends AbstractOptionSet {


@Override
public String getCatalog() {
return null;
Expand All @@ -30,4 +29,5 @@ public String getCatalog() {
public int getSQLUpdateResponse() {
return -1;
}

}
22 changes: 11 additions & 11 deletions src/main/java/com/ing/data/cassandra/jdbc/optionset/OptionSet.java
Original file line number Diff line number Diff line change
Expand Up @@ -18,36 +18,36 @@
import com.ing.data.cassandra.jdbc.CassandraConnection;

/**
* Option Set for compliance mode.
* Option set for compliance mode.
* Different use cases require one or more adjustments to the wrapper, to be compatible.
* Thus, OptionSet would provide convenience to set for different flavours.
*
* Thus, {@code OptionSet} would provide convenience to set for different flavours (for example Liquibase expect some
* methods return values different of the JDBC standard implementation).
*/
public interface OptionSet {
/**
* There is no Catalog concept in cassandra. Different flavour requires different response.
* There is no catalog concept in Cassandra. Different flavour requires different response.
*
* @return Catalog
* @return The current catalog name or {@code null} if there is none.
*/
String getCatalog();

/**
* There is no updateCount available in Datastax Java driver, different flavour requires different response.
* There is no {@code updateCount} available in Datastax Java driver, different flavour requires different response.
*
* @return Predefined update response
* @return A predefined update response.
*/
int getSQLUpdateResponse();

/**
* Set referenced connection. See @{@link AbstractOptionSet}
* @param connection Connection to set
* Set referenced connection. See @{@link AbstractOptionSet}.
* @param connection Connection to set.
*/
void setConnection(CassandraConnection connection);

/**
* Get referenced connection. See @{@link AbstractOptionSet}
* Get referenced connection. See @{@link AbstractOptionSet}.
*
* @return referenced connection
* @return the referenced connection.
*/
CassandraConnection getConnection();
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

/**
* This package contains the classes relative to the compliance modes used to adapt some behaviours of the wrapper
* to different needs (standard JDBC API, Liquibase, ...).
*/
package com.ing.data.cassandra.jdbc.optionset;
19 changes: 19 additions & 0 deletions src/main/java/com/ing/data/cassandra/jdbc/package-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

/**
* Implementation of JDBC API for Cassandra databases by wrapping the DataStax Java Driver for Apache Cassandra.
*/
package com.ing.data.cassandra.jdbc;

0 comments on commit 2202725

Please sign in to comment.