fixed app owner with url encoder

This commit is contained in:
rdavidek 2026-02-15 15:49:55 +01:00
parent c066535843
commit 738be0aa10
2 changed files with 5 additions and 3 deletions

View File

@ -1,6 +1,8 @@
package cz.trask.migration.impl.v32; package cz.trask.migration.impl.v32;
import java.io.ByteArrayInputStream; import java.io.ByteArrayInputStream;
import java.net.URLEncoder;
import java.nio.charset.Charset;
import java.util.Collections; import java.util.Collections;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;
@ -85,7 +87,7 @@ public class Wso2AppsToApicurio extends AbstractProcess {
HttpResponse exportedZip = makeRequest( HttpResponse exportedZip = makeRequest(
"GET", config.getSource().getAdminApiUrl() + "/export/applications?appName=" + app.getName() "GET", config.getSource().getAdminApiUrl() + "/export/applications?appName=" + app.getName()
+ "&appOwner=" + app.getOwner() + "&withKeys=true", + "&appOwner=" + URLEncoder.encode(app.getOwner(), Charset.forName("UTF-8")) + "&withKeys=true",
httpHeaders, Collections.emptyMap(), true); httpHeaders, Collections.emptyMap(), true);
List<ZipEntryData> zipEntries = ZipUtils.extractFilesFromZip(exportedZip.getResponseBytes()); List<ZipEntryData> zipEntries = ZipUtils.extractFilesFromZip(exportedZip.getResponseBytes());
@ -146,7 +148,7 @@ public class Wso2AppsToApicurio extends AbstractProcess {
ApplicationList listOfApps = null; ApplicationList listOfApps = null;
try { try {
String url = adminApiUrl.concat(String.format("/applications")); String url = adminApiUrl.concat(String.format("/applications?limit=9999"));
log.debug("Getting Applications with token: '" + tokenResponse.getAccess_token() + "' URL: " + url); log.debug("Getting Applications with token: '" + tokenResponse.getAccess_token() + "' URL: " + url);

View File

@ -28,6 +28,6 @@ apicurio:
default_api_group: api default_api_group: api
overwrite_existing_application: true overwrite_existing_application: true
max_threads: 8 max_threads: 1
store_migrated_artifacts: true store_migrated_artifacts: true