Skip to content

Commit 50e8a52

Browse files
author
jenkins-git
committed
Updating doc for next iteration
1 parent 54c3b48 commit 50e8a52

File tree

10 files changed

+55
-114
lines changed

10 files changed

+55
-114
lines changed

component-runtime-impl/src/main/java/org/talend/sdk/component/runtime/record/MappingUtils.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,8 @@ public static <T> Object mapString(final Class<T> expected, final String value)
181181
}
182182

183183
// A timestamp can be negative if before 1/1/1970, so need to consider '-' as first character.
184-
boolean isNumeric = !value.isEmpty() && (value.charAt(0) == '-' ? value.substring(1) : value).chars().allMatch(Character::isDigit);
184+
boolean isNumeric = !value.isEmpty()
185+
&& (value.charAt(0) == '-' ? value.substring(1) : value).chars().allMatch(Character::isDigit);
185186
if (ZonedDateTime.class == expected) {
186187
if (isNumeric) {
187188
return ZonedDateTime.ofInstant(Instant.ofEpochMilli(Long.valueOf(value)), UTC);

component-runtime-impl/src/test/java/org/talend/sdk/component/runtime/record/MappingUtilsTest.java

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -111,24 +111,22 @@ void coerce() {
111111
assertThrows(IllegalArgumentException.class, () -> MappingUtils.coerce(List.class, 123, name));
112112
}
113113

114-
115114
@ParameterizedTest
116115
@MethodSource("mapStringProvider")
117116
void mapString(final Class expectedType, final String inputValue, final Object expectedResult) {
118117
Object mapped = MappingUtils.coerce(expectedType, inputValue, "::testing::mapString");
119-
if(expectedResult instanceof byte[]){
120-
Assertions.assertArrayEquals((byte[])expectedResult, (byte[])mapped);
121-
}
122-
else {
118+
if (expectedResult instanceof byte[]) {
119+
Assertions.assertArrayEquals((byte[]) expectedResult, (byte[]) mapped);
120+
} else {
123121
Assertions.assertEquals(expectedResult, mapped);
124122
}
125123
}
126124

127125
static Stream<Arguments> mapStringProvider() {
128126
final ZonedDateTime zdtAfterEpochWithNano = ZonedDateTime.of(
129-
2024, 7, 15, // Année, mois, jour
130-
14, 30, 45, // Heure, minute, seconde
131-
123_456_789, // Nanosecondes
127+
2024, 7, 15, // Année, mois, jour
128+
14, 30, 45, // Heure, minute, seconde
129+
123_456_789, // Nanosecondes
132130
ZoneId.of("Europe/Paris"));
133131

134132
final Date dateAfterEpoch = Date.from(zdtAfterEpochWithNano.toInstant());
@@ -137,17 +135,16 @@ static Stream<Arguments> mapStringProvider() {
137135
final ZonedDateTime zdtAfterEpochUTCNoNano = instant.atZone(UTC);
138136

139137
final ZonedDateTime zdtBeforeEpochWithNano = ZonedDateTime.of(
140-
1930, 7, 15, // Année, mois, jour
141-
14, 30, 45, // Heure, minute, seconde
142-
123_456_789, // Nanosecondes
138+
1930, 7, 15, // Année, mois, jour
139+
14, 30, 45, // Heure, minute, seconde
140+
123_456_789, // Nanosecondes
143141
ZoneId.of("Europe/Paris"));
144142

145143
final Date dateBeforeEpoch = Date.from(zdtBeforeEpochWithNano.toInstant());
146144

147145
instant = dateBeforeEpoch.toInstant();
148146
final ZonedDateTime zdtBeforeEpochUTCNoNano = instant.atZone(UTC);
149147

150-
151148
return Stream.of(
152149
// (expectedType, inputValue, expectedResult)
153150
Arguments.of(String.class, "A String", "A String"),
@@ -168,16 +165,15 @@ static Stream<Arguments> mapStringProvider() {
168165
zdtBeforeEpochUTCNoNano),
169166
Arguments.of(Character.class, "abcde", 'a'),
170167
Arguments.arguments(byte[].class, "Ojp0ZXN0aW5nOjptYXBTdHJpbmc=",
171-
new byte[]{58, 58, 116, 101, 115, 116, 105, 110, 103, 58,
172-
58, 109, 97, 112, 83, 116, 114, 105, 110, 103}),
168+
new byte[] { 58, 58, 116, 101, 115, 116, 105, 110, 103, 58,
169+
58, 109, 97, 112, 83, 116, 114, 105, 110, 103 }),
173170
Arguments.of(BigDecimal.class, "123456789123456789",
174171
new BigDecimal("123456789123456789")),
175172
Arguments.of(Integer.class, String.valueOf(Integer.MIN_VALUE), Integer.MIN_VALUE),
176173
Arguments.of(Long.class, String.valueOf(Long.MIN_VALUE), Long.MIN_VALUE),
177174
Arguments.of(Short.class, String.valueOf(Short.MIN_VALUE), Short.MIN_VALUE),
178175
Arguments.of(Byte.class, String.valueOf(Byte.MIN_VALUE), Byte.MIN_VALUE),
179176
Arguments.of(Float.class, String.valueOf(Float.MIN_VALUE), Float.MIN_VALUE),
180-
Arguments.of(Double.class, String.valueOf(Double.MIN_VALUE), Double.MIN_VALUE)
181-
);
177+
Arguments.of(Double.class, String.valueOf(Double.MIN_VALUE), Double.MIN_VALUE));
182178
}
183179
}

component-tools-webapp/src/main/frontend/package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

component-tools-webapp/src/main/frontend/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,4 +47,4 @@
4747
"path-to-regexp": "0.1.10",
4848
"webpack-dev-server": "5.2.1"
4949
}
50-
}
50+
}

container/container-core/src/main/java/org/talend/sdk/component/container/ContainerManager.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ public ContainerManager(final DependenciesResolutionConfiguration dependenciesRe
119119
if (PathFactory.get(System.getProperty("user.home")).resolve(".m2/repository").equals(rootRepo)) {
120120
final URL nested = classLoaderConfiguration.getParent().getResource("MAVEN-INF/repository");
121121
if (nested != null) {
122-
rootRepo = PathFactory.get(nested.getFile().replace("file:", ""));
122+
rootRepo = PathFactory.get(nested.getFile().replace("file:", ""));
123123
}
124124
}
125125
this.rootRepositoryLocation = rootRepo;

documentation/src/main/antora/antora.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@
1313
# limitations under the License.
1414
name: main
1515
title: Talend Component Kit Developer Reference Guide
16-
version: '1.85.0'
16+
version: '1.86.0'
1717
nav:
1818
- modules/ROOT/nav.adoc

documentation/src/main/antora/modules/ROOT/pages/_partials/generated_actions.adoc

Lines changed: 0 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -156,34 +156,6 @@ Mark an action as returning a discovered schema. Its parameter MUST be a dataset
156156
"valid":true
157157
}
158158
],
159-
"entriesOrdered":[
160-
{
161-
"comment":"The column 1",
162-
"errorCapable":false,
163-
"metadata":false,
164-
"name":"column1",
165-
"nullable":false,
166-
"props":{
167-
168-
},
169-
"rawName":"column 1",
170-
"type":"STRING",
171-
"valid":true
172-
},
173-
{
174-
"comment":"The int column",
175-
"errorCapable":false,
176-
"metadata":false,
177-
"name":"column2",
178-
"nullable":false,
179-
"props":{
180-
181-
},
182-
"rawName":"column 2",
183-
"type":"INT",
184-
"valid":true
185-
}
186-
],
187159
"metadata":[
188160
],
189161
"props":{
@@ -234,34 +206,6 @@ Mark a method as returning a Schema resulting from a connector configuration and
234206
"valid":true
235207
}
236208
],
237-
"entriesOrdered":[
238-
{
239-
"comment":"The column 1",
240-
"errorCapable":false,
241-
"metadata":false,
242-
"name":"column1",
243-
"nullable":false,
244-
"props":{
245-
246-
},
247-
"rawName":"column 1",
248-
"type":"STRING",
249-
"valid":true
250-
},
251-
{
252-
"comment":"The int column",
253-
"errorCapable":false,
254-
"metadata":false,
255-
"name":"column2",
256-
"nullable":false,
257-
"props":{
258-
259-
},
260-
"rawName":"column 2",
261-
"type":"INT",
262-
"valid":true
263-
}
264-
],
265209
"metadata":[
266210
],
267211
"props":{

documentation/src/main/antora/modules/ROOT/pages/_partials/generated_rest-resources.adoc

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)