@@ -103,6 +103,17 @@ public void importArtifactVersion(ArtifactVersionEntity entity) {
103
103
entity .globalId = storage .nextGlobalId ();
104
104
}
105
105
106
+ Map <String , String > artifactVersionLabels = new HashMap <>();
107
+
108
+ if (entity .labels != null ) {
109
+ artifactVersionLabels
110
+ .putAll (entity .labels .stream ().collect (Collectors .toMap (label -> label , s -> null )));
111
+ }
112
+
113
+ if (entity .properties != null ) {
114
+ artifactVersionLabels .putAll (entity .properties );
115
+ }
116
+
106
117
io .apicurio .registry .utils .impexp .v3 .ArtifactVersionEntity newEntity = io .apicurio .registry .utils .impexp .v3 .ArtifactVersionEntity
107
118
.builder ().createdOn (entity .createdOn ).description (entity .description )
108
119
.labels (entity .labels != null
@@ -118,10 +129,7 @@ public void importArtifactVersion(ArtifactVersionEntity entity) {
118
129
if (entity .versionId == 1 ) {
119
130
ArtifactEntity artifactEntity = ArtifactEntity .builder ().artifactId (entity .artifactId )
120
131
.artifactType (entity .artifactType ).createdOn (entity .createdOn )
121
- .description (entity .description ).groupId (entity .groupId )
122
- .labels (entity .labels != null
123
- ? entity .labels .stream ().collect (Collectors .toMap (label -> label , s -> null ))
124
- : Collections .emptyMap ())
132
+ .description (entity .description ).groupId (entity .groupId ).labels (artifactVersionLabels )
125
133
.modifiedBy (entity .createdBy ).modifiedOn (entity .createdOn ).name (entity .name )
126
134
.owner (entity .createdBy ).build ();
127
135
storage .importArtifact (artifactEntity );
@@ -295,6 +303,7 @@ private String determineContentType(String artifactTypeHint, TypedContent conten
295
303
return ContentTypes .APPLICATION_GRAPHQL ;
296
304
case XML :
297
305
case XSD :
306
+ case WSDL :
298
307
return ContentTypes .APPLICATION_XML ;
299
308
}
300
309
}
0 commit comments