Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- String tenantDomain = “mytenant.com";
- String url = "https://localhost:9443/t/"+tenantDomain+"/registry";
- String userName = “admin@mytenant.com";
- String password = “admin";
- System.setProperty("carbon.repo.write.mode", "true");
- //Get the file which needs to be added to the registry
- File file = new File(“/home/bob/Desktop/myPayload.json");
- RemoteRegistry remote_registry = new RemoteRegistry(new URL(url), userName, password);
- //Import the file to config registry
- RegistryClientUtils.importToRegistry(file ,"/_system/config" ,remote_registry);
- //Export from registry
- //RegistryClientUtils.exportFromRegistry(file ,"/_system/governance/SomePayload.json" ,remote_registry);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement