Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WFCORE-38] Add console option to target of console-handler #88

Merged
merged 2 commits into from Aug 14, 2014

Conversation

jamezp
Copy link
Member

@jamezp jamezp commented Aug 8, 2014

Adds an option to use the System.console() for the console-handler. Kept default of System.out.

@wildfly-ci
Copy link

Build 173 is now running using a merge of 04400c8

@wildfly-ci
Copy link

Build 173 outcome was SUCCESS using a merge of 04400c8
Summary: Tests passed: 2552, ignored: 57 Build time: 0:16:14

case VERSION_2_0_0: {
resourceBuilder
.getAttributeBuilder()
.setValueConverter(new DefaultAttributeConverter() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this should be a reject rather than a conversion.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Something like:
.addRejectCheck(SIMPLE_EXPRESSIONS, TARGET)
.addRejectCheck(new SimpleRejectAttributeChecker(new ModelNode("console"), TARGET)
.end();

As per the BaseAttributeTransformationDescriptionBuilder.addRejectCheck() javadoc, the reject checkers should be evaluated in the order they are added.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we really want to reject expressions? They are valid for the attribute. I assume it's in case the expression resolves to console. My thinking though, probably wrong :), is that it would be a configuration error setting the value to console on the target that does not support it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is a standard 'pattern'. Transformation happens on the DC, and for cases where the DC needs to check for a particular value during transformation, we don't know the expression will resolve to on the legacy server, so we reject expressions.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, got it. Maybe adding this attribute value isn't worth it then if it means rejecting expressions. It probably doesn't add all that much as I assume stderr and stdout will be used more often. I guess too though an expression may not be used for this value often so maybe it doesn't matter...

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is probably worth keeping it, I assume the majority of users will be running homogenous domains. And if not, then there are plenty of other cases like this they will need to set up.

@wildfly-ci
Copy link

Build 196 is now running using a merge of 5772b70

@wildfly-ci
Copy link

Build 196 outcome was SUCCESS using a merge of 5772b70
Summary: Tests passed: 2554, ignored: 57 Build time: 0:15:41

n1hility added a commit that referenced this pull request Aug 14, 2014
[WFCORE-38] Add console option to target of console-handler
@n1hility n1hility merged commit 877c360 into wildfly:master Aug 14, 2014
@jamezp jamezp deleted the WFCORE-38 branch August 19, 2014 16:27
iweiss pushed a commit to iweiss/wildfly-core that referenced this pull request Jun 6, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants