diff --git a/CHANGELOG.md b/CHANGELOG.md
index 12ef7865..32a1daff 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -2,6 +2,8 @@
## [Unreleased]
+## [0.14.0] - 2024-06-26
+
### Bugfixes
- Significantly reduce memory allocation overhead and excessive GC pressure ([#401](https://github.com/tarantool/cartridge-java/issues/401))
@@ -19,6 +21,7 @@
- Add support for crud `balance` option ([#462](https://github.com/tarantool/cartridge-java/pull/472))
- Add support for crud `vshard_router` option ([#463](https://github.com/tarantool/cartridge-java/pull/473))
- Add support for crud `fetch_latest_metadata` option ([#465](https://github.com/tarantool/cartridge-java/pull/474))
+- Use toString in StringValues to map incorrect UTF-8 string
### Features
diff --git a/README.md b/README.md
index 331debcb..42cf0459 100644
--- a/README.md
+++ b/README.md
@@ -42,7 +42,7 @@ If you use this code in another project don't forget to add a `cartridge-driver`
io.tarantool
cartridge-driver
- 0.13.0
+ 0.14.0
```
## Advanced usage
diff --git a/pom.xml b/pom.xml
index 42018188..9db780c3 100644
--- a/pom.xml
+++ b/pom.xml
@@ -171,7 +171,7 @@
org.sonatype.plugins
nexus-staging-maven-plugin
- 1.6.8
+ 1.6.14
true
ossrh
diff --git a/src/main/java/io/tarantool/driver/api/space/options/crud/OperationWithYieldEveryOptions.java b/src/main/java/io/tarantool/driver/api/space/options/crud/OperationWithYieldEveryOptions.java
index 04b394a8..5efacf3f 100644
--- a/src/main/java/io/tarantool/driver/api/space/options/crud/OperationWithYieldEveryOptions.java
+++ b/src/main/java/io/tarantool/driver/api/space/options/crud/OperationWithYieldEveryOptions.java
@@ -13,7 +13,7 @@ public interface OperationWithYieldEveryOptions 0.
* @param yieldEvery number of tuples processed on storage to yield after, "yield_every" should be > 0.
* @return this option instance.
- * @throws IllegalArgumentException if yieldEvery < 0.
+ * @throws IllegalArgumentException {@code if yieldEvery < 0}.
*/
default T withYieldEvery(int yieldEvery) throws IllegalArgumentException {
if (yieldEvery <= 0) {
diff --git a/src/main/java/io/tarantool/driver/core/metadata/ArrayValueToSpaceFormatConverter.java b/src/main/java/io/tarantool/driver/core/metadata/ArrayValueToSpaceFormatConverter.java
index 22c65db8..4baaa632 100644
--- a/src/main/java/io/tarantool/driver/core/metadata/ArrayValueToSpaceFormatConverter.java
+++ b/src/main/java/io/tarantool/driver/core/metadata/ArrayValueToSpaceFormatConverter.java
@@ -43,8 +43,8 @@ public Map fromValue(ArrayValue format) {
spaceFormatMetadata.put(
fieldMap.get(FORMAT_FIELD_NAME).toString(),
new TarantoolFieldMetadataImpl(
- fieldMap.get(FORMAT_FIELD_NAME).asStringValue().asString(),
- fieldMap.get(FORMAT_FIELD_TYPE).asStringValue().asString(),
+ fieldMap.get(FORMAT_FIELD_NAME).asStringValue().toString(),
+ fieldMap.get(FORMAT_FIELD_TYPE).asStringValue().toString(),
fieldPosition,
isNullable.isPresent() && isNullable.get().asBooleanValue().getBoolean()
)
diff --git a/src/main/java/io/tarantool/driver/core/metadata/DDLTarantoolSpaceMetadataConverter.java b/src/main/java/io/tarantool/driver/core/metadata/DDLTarantoolSpaceMetadataConverter.java
index 55282c1d..a8e74404 100644
--- a/src/main/java/io/tarantool/driver/core/metadata/DDLTarantoolSpaceMetadataConverter.java
+++ b/src/main/java/io/tarantool/driver/core/metadata/DDLTarantoolSpaceMetadataConverter.java
@@ -94,7 +94,7 @@ public TarantoolMetadataContainer fromValue(Value value) {
TarantoolSpaceMetadataImpl spaceMetadata = new TarantoolSpaceMetadataImpl();
spaceMetadata.setOwnerId(ID_UNKNOWN);
- spaceMetadata.setSpaceName(nameValue.asStringValue().asString());
+ spaceMetadata.setSpaceName(nameValue.asStringValue().toString());
Value formatValue = space.get(SPACE_FORMAT_KEY);
if (formatValue == null) {
@@ -140,14 +140,14 @@ private Map parseIndexes(
throw new TarantoolClientException(
"Unsupported index metadata format: key '" + INDEX_NAME_KEY + "' must have string value");
}
- String indexName = indexNameValue.asStringValue().asString();
+ String indexName = indexNameValue.asStringValue().toString();
Value indexTypeValue = indexMap.get(INDEX_TYPE_KEY);
if (indexTypeValue == null || !indexTypeValue.isStringValue()) {
throw new TarantoolClientException(
"Unsupported index metadata format: key '" + INDEX_TYPE_KEY + "' must have string value");
}
- String indexType = indexTypeValue.asStringValue().asString();
+ String indexType = indexTypeValue.asStringValue().toString();
Value indexUniqueValue = indexMap.get(INDEX_UNIQUE_KEY);
if (indexUniqueValue == null || !indexUniqueValue.isBooleanValue()) {
@@ -196,7 +196,7 @@ private Map parseIndexes(
int fieldNumber;
Object fieldPath;
if (fieldPathValue.isStringValue()) {
- fieldPath = fieldPathValue.asStringValue().asString();
+ fieldPath = fieldPathValue.asStringValue().toString();
fieldNumber = getFieldNumberFromFieldPath(fields, (String) fieldPath);
} else {
fieldNumber = fieldPathValue.asIntegerValue().asInt();
@@ -208,7 +208,7 @@ private Map parseIndexes(
throw new TarantoolClientException("Unsupported index metadata format: key '" +
INDEX_PARTS_TYPE_KEY + "' must have string value");
}
- String fieldType = fieldTypeValue.asStringValue().asString();
+ String fieldType = fieldTypeValue.asStringValue().toString();
return new TarantoolIndexPartMetadataImpl<>(fieldNumber, fieldType, fieldPath);
})
diff --git a/src/main/java/io/tarantool/driver/core/metadata/TarantoolIndexMetadataConverter.java b/src/main/java/io/tarantool/driver/core/metadata/TarantoolIndexMetadataConverter.java
index 1d8371c1..8c52f4fb 100644
--- a/src/main/java/io/tarantool/driver/core/metadata/TarantoolIndexMetadataConverter.java
+++ b/src/main/java/io/tarantool/driver/core/metadata/TarantoolIndexMetadataConverter.java
@@ -61,13 +61,13 @@ public TarantoolIndexMetadata fromValue(ArrayValue value) {
indexParts = indexPartsValue.list().stream()
.map(partValue -> new TarantoolIndexPartMetadataImpl<>(
partValue.asArrayValue().get(0).asIntegerValue().asInt(),
- partValue.asArrayValue().get(1).asStringValue().asString()
+ partValue.asArrayValue().get(1).asStringValue().toString()
)).collect(Collectors.toList());
} else {
indexParts = indexPartsValue.list().stream()
.map(partValue -> new TarantoolIndexPartMetadataImpl<>(
partValue.asMapValue().map().get(INDEX_FIELD_KEY).asIntegerValue().asInt(),
- partValue.asMapValue().map().get(INDEX_TYPE_KEY).asStringValue().asString()
+ partValue.asMapValue().map().get(INDEX_TYPE_KEY).asStringValue().toString()
)).collect(Collectors.toList());
}
}
diff --git a/src/main/java/io/tarantool/driver/mappers/converters/value/defaults/DefaultStringValueToCharacterConverter.java b/src/main/java/io/tarantool/driver/mappers/converters/value/defaults/DefaultStringValueToCharacterConverter.java
index d98d4302..cff5d8a8 100644
--- a/src/main/java/io/tarantool/driver/mappers/converters/value/defaults/DefaultStringValueToCharacterConverter.java
+++ b/src/main/java/io/tarantool/driver/mappers/converters/value/defaults/DefaultStringValueToCharacterConverter.java
@@ -15,13 +15,13 @@ public class DefaultStringValueToCharacterConverter implements ValueConverter new CustomTuple(v.get(0).asIntegerValue().asInt(), v.get(1).asStringValue().asString()))
+ * (v) -> new CustomTuple(v.get(0).asIntegerValue().asInt(), v.get(1).asStringValue().toString()))
* .get();
*
* customTuples.forEach(