Skip to content

Commit

Permalink
Add codec hint property
Browse files Browse the repository at this point in the history
  • Loading branch information
denis.plotnikov committed Sep 30, 2024
1 parent 10d5315 commit f5d566a
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# th2-conn-dirty-fix (1.4.1)
# th2-conn-dirty-fix (1.4.2)

This microservice allows sending and receiving messages via FIX protocol

Expand Down Expand Up @@ -333,6 +333,10 @@ spec:
memory: 100Mi
cpu: 20m
```
## 1.4.2

* Add property `encode-mode: dirty` for messages that are corrupted with transformation strategies: `TRANSFORM_MESSAGE_STRATEGY`, `INVALID_CHECKSUM` and `TRANSFORM_LOGON`

## 1.4.1

* Use keep open gRPC query to recover messages for Resend Request
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
plugins {
id "application"
id "com.exactpro.th2.gradle.component" version "0.1.1"
id "com.exactpro.th2.gradle.component" version "0.1.3"
id 'org.jetbrains.kotlin.jvm' version '1.8.22'
id "org.jetbrains.kotlin.kapt" version "1.8.22"
}
Expand Down
5 changes: 5 additions & 0 deletions src/main/java/com/exactpro/th2/FixHandler.java
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,8 @@ public class FixHandler implements AutoCloseable, IHandler {
private static final String STUBBING_VALUE = "XXX";
private static final String SPLIT_SEND_TIMESTAMPS_PROPERTY = "BufferSlicesSendingTimes";
private static final String STRATEGY_EVENT_TYPE = "StrategyState";
private static final String ENCODE_MODE_PROPERTY_NAME = "encode-mode";
private static final String DIRTY_ENCODE_MODE_NAME = "dirty";
private static final DateTimeFormatter formatter = DateTimeFormatter.ISO_INSTANT;
private static final ObjectMapper mapper = new ObjectMapper();

Expand Down Expand Up @@ -1577,6 +1579,9 @@ private Map<String, String> defaultOutgoingStrategy(ByteBuf message, Map<String,
private Map<String, String> transformOutgoingMessageStrategy(ByteBuf message, Map<String, String> metadata) {
onOutgoingUpdateTag(message, metadata);
transformProcessor(message, metadata);

metadata.put(ENCODE_MODE_PROPERTY_NAME, DIRTY_ENCODE_MODE_NAME);

return null;
}

Expand Down

0 comments on commit f5d566a

Please sign in to comment.