2828import java .util .List ;
2929import java .util .Map .Entry ;
3030import java .util .Set ;
31+ import java .util .UUID ;
3132import java .util .concurrent .ExecutorService ;
3233import java .util .concurrent .Executors ;
3334import java .util .function .BiConsumer ;
@@ -250,7 +251,7 @@ public List<Proxy> getProxiesOfCurrentUser(Predicate<Proxy> filter) {
250251 * @throws ContainerProxyException If the proxy fails to start for any reason.
251252 */
252253 public Proxy startProxy (ProxySpec spec , boolean ignoreAccessControl ) throws ContainerProxyException {
253- return startProxy (spec , ignoreAccessControl , null );
254+ return startProxy (spec , ignoreAccessControl , null , UUID . randomUUID (). toString () );
254255 }
255256
256257 /**
@@ -262,12 +263,13 @@ public Proxy startProxy(ProxySpec spec, boolean ignoreAccessControl) throws Cont
262263 * @return The newly launched proxy.
263264 * @throws ContainerProxyException If the proxy fails to start for any reason.
264265 */
265- public Proxy startProxy (ProxySpec spec , boolean ignoreAccessControl , List <RuntimeValue > runtimeValues ) throws ContainerProxyException {
266+ public Proxy startProxy (ProxySpec spec , boolean ignoreAccessControl , List <RuntimeValue > runtimeValues , String proxyId ) throws ContainerProxyException {
266267 if (!ignoreAccessControl && !userService .canAccess (spec )) {
267268 throw new AccessDeniedException (String .format ("Cannot start proxy %s: access denied" , spec .getId ()));
268269 }
269270
270271 Proxy proxy = new Proxy ();
272+ proxy .setId (proxyId );
271273 proxy .setStatus (ProxyStatus .New );
272274 proxy .setUserId (userService .getCurrentUserId ());
273275 proxy .setSpec (spec );
0 commit comments