Skip to content

OAK-11491 clear system property in tearDown method#2086

Merged
smiroslav merged 3 commits intoapache:trunkfrom
smiroslav:issue/OAK-11491
Feb 17, 2025
Merged

OAK-11491 clear system property in tearDown method#2086
smiroslav merged 3 commits intoapache:trunkfrom
smiroslav:issue/OAK-11491

Conversation

@smiroslav
Copy link
Copy Markdown
Contributor

READ_WRITE.setAddPermission(true);
System.setProperty("segment.azure.v12.enabled", "true");

System.setProperty(AzureSegmentStoreService.SEGMENT_AZURE_V_12_ENABLED, "true");
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggested change
System.setProperty(AzureSegmentStoreService.SEGMENT_AZURE_V_12_ENABLED, "true");
oldPropertyValue = System.getProperty(AzureSegmentStoreService.SEGMENT_AZURE_V_12_ENABLED);
System.setProperty(AzureSegmentStoreService.SEGMENT_AZURE_V_12_ENABLED, "true");


@AfterClass
public static void tearDown() {
System.clearProperty(AzureSegmentStoreService.SEGMENT_AZURE_V_12_ENABLED);
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggested change
System.clearProperty(AzureSegmentStoreService.SEGMENT_AZURE_V_12_ENABLED);
System.setProperty(AzureSegmentStoreService.SEGMENT_AZURE_V_12_ENABLED, oldPropertyValue);

@smiroslav
Copy link
Copy Markdown
Contributor Author

The build failed for oak-store-document
https://ci-builds.apache.org/job/Jackrabbit/job/oak-trunk-pr/job/PR-2086/3/cloudbees-pipeline-explorer/?filter=187

Since oak-store-document is unaffected by the changes made here, I will merge PR.

@smiroslav smiroslav merged commit 91321a0 into apache:trunk Feb 17, 2025
andreeastroe96 pushed a commit to andreeastroe96/jackrabbit-oak that referenced this pull request Feb 25, 2025
* OAK-11491 clear system property in tearDown method

* OAK-11491 remember the old value of the system property

* OAK-11491 rename property

---------

Co-authored-by: Miroslav Smiljanic <miroslav@apache.com>
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.

2 participants