75
75
import org .jboss .dmr .ModelNode ;
76
76
import org .jboss .shrinkwrap .api .exporter .ZipExporter ;
77
77
import org .jboss .shrinkwrap .api .spec .JavaArchive ;
78
- import org .jboss .threads .AsyncFuture ;
79
78
import org .junit .After ;
80
79
import org .junit .AfterClass ;
81
80
import org .junit .Assert ;
@@ -135,15 +134,15 @@ public void testInstallAndExplodeDeploymentOnDC() throws IOException, MgmtOperat
135
134
final JavaArchive archive = ServiceActivatorDeploymentUtil .createServiceActivatorDeploymentArchive ("test-deployment.jar" , properties );
136
135
ModelNode result ;
137
136
try (InputStream is = archive .as (ZipExporter .class ).exportAsInputStream ()) {
138
- AsyncFuture <ModelNode > future = primaryClient .executeAsync (addDeployment (is ), null );
137
+ Future <ModelNode > future = primaryClient .executeAsync (addDeployment (is ), null );
139
138
result = awaitSimpleOperationExecution (future );
140
139
}
141
140
assertTrue (Operations .isSuccessfulOutcome (result ));
142
141
ModelNode contentNode = readDeploymentResource (PathAddress .pathAddress (DEPLOYMENT_PATH )).require (CONTENT ).require (0 );
143
142
String initialHash = HashUtil .bytesToHexString (contentNode .get (HASH ).asBytes ());
144
143
assertTrue (contentNode .get (ARCHIVE ).asBoolean (true ));
145
144
//Let's explode it
146
- AsyncFuture <ModelNode > future = primaryClient .executeAsync (Operations .createOperation (EXPLODE , PathAddress .pathAddress (DEPLOYMENT_PATH ).toModelNode ()), null );
145
+ Future <ModelNode > future = primaryClient .executeAsync (Operations .createOperation (EXPLODE , PathAddress .pathAddress (DEPLOYMENT_PATH ).toModelNode ()), null );
147
146
result = awaitSimpleOperationExecution (future );
148
147
assertTrue (Operations .isSuccessfulOutcome (result ));
149
148
contentNode = readDeploymentResource (PathAddress .pathAddress (DEPLOYMENT_PATH )).require (CONTENT ).require (0 );
@@ -205,7 +204,7 @@ public void testInstallAndExplodeDeploymentOnDC() throws IOException, MgmtOperat
205
204
206
205
@ Test
207
206
public void testInstallAndExplodeDeploymentOnDCFromScratch () throws IOException , MgmtOperationException {
208
- AsyncFuture <ModelNode > future = primaryClient .executeAsync (addEmptyDeployment (), null ); //Add empty deployment
207
+ Future <ModelNode > future = primaryClient .executeAsync (addEmptyDeployment (), null ); //Add empty deployment
209
208
ModelNode result = awaitSimpleOperationExecution (future );
210
209
assertTrue (Operations .isSuccessfulOutcome (result ));
211
210
ModelNode contentNode = readDeploymentResource (PathAddress .pathAddress (DEPLOYMENT_PATH )).require (CONTENT ).require (0 );
@@ -305,7 +304,7 @@ public void testEmptyAndAddContentInComposite() throws Exception {
305
304
steps .add (addContent );
306
305
Operation operation = Operation .Factory .create (composite , contentAttachments );
307
306
308
- AsyncFuture <ModelNode > future = primaryClient .executeAsync (operation , null );
307
+ Future <ModelNode > future = primaryClient .executeAsync (operation , null );
309
308
ModelNode result = awaitSimpleOperationExecution (future );
310
309
assertTrue (result .toString (), Operations .isSuccessfulOutcome (result ));
311
310
ModelNode contentNode = readDeploymentResource (PathAddress .pathAddress (DEPLOYMENT_PATH )).require (CONTENT ).require (0 );
@@ -342,7 +341,7 @@ public void testEmptyAndAddContentAndDeployInComposite() throws Exception {
342
341
steps .add (deployOnServerGroup ());
343
342
Operation operation = Operation .Factory .create (composite , contentAttachments );
344
343
345
- AsyncFuture <ModelNode > future = primaryClient .executeAsync (operation , null );
344
+ Future <ModelNode > future = primaryClient .executeAsync (operation , null );
346
345
ModelNode result = awaitSimpleOperationExecution (future );
347
346
assertTrue (result .toString (), Operations .isSuccessfulOutcome (result ));
348
347
ModelNode contentNode = readDeploymentResource (PathAddress .pathAddress (DEPLOYMENT_PATH )).require (CONTENT ).require (0 );
@@ -356,7 +355,7 @@ private ModelNode readDeploymentResource(PathAddress address) {
356
355
ModelNode operation = Operations .createReadResourceOperation (address .toModelNode ());
357
356
operation .get (INCLUDE_RUNTIME ).set (true );
358
357
operation .get (INCLUDE_DEFAULTS ).set (true );
359
- AsyncFuture <ModelNode > future = primaryClient .executeAsync (operation , null );
358
+ Future <ModelNode > future = primaryClient .executeAsync (operation , null );
360
359
ModelNode result = awaitSimpleOperationExecution (future );
361
360
assertTrue (Operations .isSuccessfulOutcome (result ));
362
361
return Operations .readResult (result );
@@ -383,7 +382,7 @@ public void browseContent(String path, List<String> expectedContents) throws IOE
383
382
if (path != null && !path .isEmpty ()) {
384
383
operation .get (PATH ).set (path );
385
384
}
386
- AsyncFuture <ModelNode > future = primaryClient .executeAsync (operation , null );
385
+ Future <ModelNode > future = primaryClient .executeAsync (operation , null );
387
386
ModelNode response = awaitSimpleOperationExecution (future );
388
387
assertTrue (Operations .isSuccessfulOutcome (response ));
389
388
List <ModelNode > contents = Operations .readResult (response ).asList ();
@@ -403,7 +402,7 @@ public void browseContent(String path, List<String> expectedContents) throws IOE
403
402
public void checkNoContent (String path ) throws IOException {
404
403
ModelNode operation = Operations .createOperation (READ_CONTENT , PathAddress .pathAddress (DEPLOYMENT_PATH ).toModelNode ());
405
404
operation .get (PATH ).set (path );
406
- AsyncFuture <ModelNode > future = primaryClient .executeAsync (operation , null );
405
+ Future <ModelNode > future = primaryClient .executeAsync (operation , null );
407
406
ModelNode result = awaitSimpleOperationExecution (future );
408
407
assertFalse (Operations .isSuccessfulOutcome (result ));
409
408
}
0 commit comments