Quantcast
Channel: VMware Communities : Discussion List - vRealize Orchestrator
Viewing all articles
Browse latest Browse all 6251

How to import plug-in in VCO through REST API

$
0
0

I try to import VCO plug-in in VCO through REST client, it always through below listed error

 

Exception in thread "main" org.springframework.web.client.HttpServerErrorException: 500 Internal Server Error

    at org.springframework.web.client.DefaultResponseErrorHandler.handleError(DefaultResponseErrorHandler.java:92)

    at org.springframework.web.client.RestTemplate.handleResponseError(RestTemplate.java:494)

    at org.springframework.web.client.RestTemplate.doExecute(RestTemplate.java:451)

    at org.springframework.web.client.RestTemplate.execute(RestTemplate.java:423)

    at org.springframework.web.client.RestTemplate.postForEntity(RestTemplate.java:328)

    at com.vmware.o11n.sdk.rest.client.services.PluginService.importPlugin(PluginService.java:65)

    at com.vmware.o11n.sdk.rest.client.services.PluginService.importPluginFromFile(PluginService.java:53)

    at FileUploadAdv100.uploadVCOPluginsList(FileUploadAdv100.java:53)

    at FileUploadAdv100.main(FileUploadAdv100.java:26)

 

My code is here in

 

    File pluginFile = new File("D:\\vcoplugins\\JAVARESTSDK_Examples\\o11nplugin-powershell-1.0.1.vmoapp");
   boolean overwrite = false;
    VcoSessionFactory sessionFactory = createSessionFactory();
    Authentication auth = createAuthentication(sessionFactory);
    VcoSession session = sessionFactory.newSession(auth);  
  
  
   PluginService pluginService = new PluginService(session);
   pluginService.importPluginFromFile(pluginFile, overwrite);

 

 

Regards
AVR


Viewing all articles
Browse latest Browse all 6251

Trending Articles