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

PAYARA-4219 Problem when trying to override System Properties of an instance #4321

Merged
merged 3 commits into from
Nov 20, 2019

Conversation

AlanRoth
Copy link
Contributor

Description

This is a bug fix

Overriding system properties in {Instance Name}-config -> System Properties -> Instance Values failed stating "An error has occured"

Testing

On a new Instance running/stopped e.g Elegant-Archerfish

  • Go to Instances -> Elegant-Archerfish -> Properties -> System Properties changing an Override value should change Current Value
  • Go to Configurations -> Elegant-Archerfish-config -> System Properties -> Instance Values changing the Override Value should save successfully.

Note: Default Value will remain the same unless changed in the configuration

Check the override value has been applied by going back to Instances -> Elegant-Archerfish -> Properties -> System Properties you should see the new override value. The instance may need to be restarted.

Testing Performed

Build tests
Testing against acceptance criteria

Testing Environment

Manjaro 18.0.4
Maven 3.6.1
Zulu JDK 1.8.0_222

@AlanRoth
Copy link
Contributor Author

jenkins test please

@cubastanley
Copy link
Contributor

I tested this locally and it does make a difference but an error is still given - just has a specified error message

@AlanRoth
Copy link
Contributor Author

AlanRoth commented Nov 13, 2019

I tested this locally and it does make a difference but an error is still given - just has a specified error message

What does the error say? And is it in Instance values?

@cubastanley
Copy link
Contributor

I tested this locally and it does make a difference but an error is still given - just has a specified error message

What does the error say?

An error occurred during replication Failure: Command delete-system-property failed on server instance Dark-Minnow: javax.net.ssl.SSLHandshakeException: PKIX path validation failed: java.security.cert.CertPathValidatorException: signature check failed Failure: Command delete-system-property failed on server instance Dark-Minnow: javax.net.ssl.SSLHandshakeException: PKIX path validation failed: java.security.cert.CertPathValidatorException: signature check failed - don't know if this is expected or not

@AlanRoth
Copy link
Contributor Author

I tested this locally and it does make a difference but an error is still given - just has a specified error message

What does the error say?

An error occurred during replication Failure: Command delete-system-property failed on server instance Dark-Minnow: javax.net.ssl.SSLHandshakeException: PKIX path validation failed: java.security.cert.CertPathValidatorException: signature check failed Failure: Command delete-system-property failed on server instance Dark-Minnow: javax.net.ssl.SSLHandshakeException: PKIX path validation failed: java.security.cert.CertPathValidatorException: signature check failed - don't know if this is expected or not

Not expected at all usually, which system property did you override? As that might bork things up, http listener port is a safe one to try

@Pandrex247 Pandrex247 added this to the 5.194 milestone Nov 13, 2019
@@ -885,7 +885,7 @@ public static RestResponse post(String address, Object payload, String contentTy
}
Response cr = target.request(RESPONSE_TYPE).header("Content-Type", contentType)
.cookie(new Cookie(REST_TOKEN_COOKIE, getRestToken()))
// .header("Content-type", MediaType.APPLICATION_FORM_URLENCODED)
.header("Content-type", MediaType.APPLICATION_FORM_URLENCODED)
Copy link
Member

Choose a reason for hiding this comment

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

Danger Will Robinson!
I'm very wary of this change - I need to give this a thorough bashing to ensure it doesn't blow something up.
Lots of things use this method, sending all kinds of gubbins through it e.g. Rest Management Interface sending Json

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I see, I think it can be safe to revert, the jsf specifies the content type when it calls the rest request

Copy link
Member

@Pandrex247 Pandrex247 left a comment

Choose a reason for hiding this comment

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

The change fixes the problem described, but I need to get out my baseball bat and give this a thwacking to see if any bugs fall out.

@Pandrex247
Copy link
Member

I didn't get any PKIX errors @cubastanley, that's an odd error to get - normally something to do with, well, certificates.

@AlanRoth
Copy link
Contributor Author

I didn't get any PKIX errors @cubastanley, that's an odd error to get - normally something to do with, well, certificates.

I reproduced it once using some unorthodox values (not 100% of the time)

Copy link
Contributor

@cubastanley cubastanley left a comment

Choose a reason for hiding this comment

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

Assuming I caused my issue, does stop the problem stated in ticket so - aproooved

Unnecessary change
@AlanRoth
Copy link
Contributor Author

jenkins test please

@AlanRoth AlanRoth merged commit 11830c3 into payara:master Nov 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants