-
Notifications
You must be signed in to change notification settings - Fork 465
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #6101 from pferraro/WFCORE-6922
WFCORE-6922 Remove usage of deprecated AbstractWriteAttributeHandler constructors in elytron subsystem
- Loading branch information
Showing
31 changed files
with
46 additions
and
115 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,11 +9,10 @@ | |
import static org.jboss.as.controller.security.CredentialReference.handleCredentialReferenceUpdate; | ||
import static org.jboss.as.controller.security.CredentialReference.rollbackCredentialStoreUpdate; | ||
|
||
import java.util.Collection; | ||
|
||
import org.jboss.as.controller.AttributeDefinition; | ||
import org.jboss.as.controller.OperationContext; | ||
import org.jboss.as.controller.OperationFailedException; | ||
import org.jboss.as.controller.OperationStepHandler; | ||
import org.jboss.as.controller.PathAddress; | ||
import org.jboss.as.controller.ReloadRequiredWriteAttributeHandler; | ||
import org.jboss.as.controller.registry.Resource; | ||
import org.jboss.as.controller.security.CredentialReference; | ||
|
@@ -23,12 +22,11 @@ | |
* @author <a href="mailto:[email protected]">Tomas Hofman</a> | ||
*/ | ||
class ElytronReloadRequiredWriteAttributeHandler extends ReloadRequiredWriteAttributeHandler implements ElytronOperationStepHandler { | ||
ElytronReloadRequiredWriteAttributeHandler(final AttributeDefinition... definitions) { | ||
super(definitions); | ||
} | ||
|
||
ElytronReloadRequiredWriteAttributeHandler(final Collection<AttributeDefinition> definitions) { | ||
super(definitions); | ||
static final OperationStepHandler INSTANCE = new ElytronReloadRequiredWriteAttributeHandler(); | ||
|
||
private ElytronReloadRequiredWriteAttributeHandler() { | ||
// Hide | ||
} | ||
|
||
@Override | ||
|
@@ -59,7 +57,7 @@ protected boolean requiresRuntime(final OperationContext context) { | |
@Override | ||
protected void revertUpdateToRuntime(OperationContext context, ModelNode operation, String attributeName, ModelNode valueToRestore, ModelNode resolvedValue, Void handback) throws OperationFailedException { | ||
if (attributeName.equals(CredentialReference.CREDENTIAL_REFERENCE)) { | ||
rollbackCredentialStoreUpdate(getAttributeDefinition(attributeName), context, resolvedValue); | ||
rollbackCredentialStoreUpdate(context.getResourceRegistration().getAttributeAccess(PathAddress.EMPTY_ADDRESS, attributeName).getAttributeDefinition(), context, resolvedValue); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,10 +5,7 @@ | |
|
||
package org.wildfly.extension.elytron; | ||
|
||
import java.util.Collection; | ||
|
||
import org.jboss.as.controller.AbstractWriteAttributeHandler; | ||
import org.jboss.as.controller.AttributeDefinition; | ||
import org.jboss.as.controller.OperationContext; | ||
|
||
/** | ||
|
@@ -17,13 +14,6 @@ | |
* @author <a href="mailto:[email protected]">James R. Perkins</a> | ||
*/ | ||
abstract class ElytronWriteAttributeHandler<V> extends AbstractWriteAttributeHandler<V> implements ElytronOperationStepHandler { | ||
protected ElytronWriteAttributeHandler(final AttributeDefinition... definitions) { | ||
super(definitions); | ||
} | ||
|
||
protected ElytronWriteAttributeHandler(final Collection<AttributeDefinition> definitions) { | ||
super(definitions); | ||
} | ||
|
||
@Override | ||
protected boolean requiresRuntime(final OperationContext context) { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.