Skip to content

Commit ea1d116

Browse files
authored
Merge branch 'trunk' into feature/OAK-11498-expose-bound-principals-via-jrsession
2 parents fc756c5 + 63eb1ba commit ea1d116

File tree

1,072 files changed

+31950
-6942
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,072 files changed

+31950
-6942
lines changed

RELEASE-NOTES.txt

Lines changed: 93 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Release Notes -- Apache Jackrabbit Oak -- Version 1.76.0
1+
Release Notes -- Apache Jackrabbit Oak -- Version 1.80.0
22

33
Introduction
44
------------
@@ -7,92 +7,119 @@ Jackrabbit Oak is a scalable, high-performance hierarchical content
77
repository designed for use as the foundation of modern world-class
88
web sites and other demanding content applications.
99

10-
Apache Jackrabbit Oak 1.76.0 is an incremental feature release based
10+
Apache Jackrabbit Oak 1.80.0 is an incremental feature release based
1111
on and compatible with earlier stable Jackrabbit Oak 1.x
1212
releases. This release is considered stable and targeted for
1313
production use.
1414

15-
While Oak 1.76.0 compiles and tests successfully on Java 17, Javadocs
16-
generation fails on Java 17 (but works as expected on Java 11).
15+
While Oak 1.80.0 compiles and tests successfully on Java 24.
1716

1817
The Oak effort is a part of the Apache Jackrabbit project.
1918
Apache Jackrabbit is a project of the Apache Software Foundation.
2019

21-
Changes in Oak 1.76.0
20+
Changes in Oak 1.80.0
2221
---------------------
2322

23+
Sub-task
24+
25+
[OAK-11696] - remove (shaded) Guava common.io package
26+
2427
Technical task
2528

26-
[OAK-11357] - Extract StreamUtils from CollectionUtils
27-
[OAK-11380] - Remove usage of Guava Files.asByteSource
28-
[OAK-11384] - Remove usage of Guava Maps
29-
[OAK-11385] - Remove usage of Guava Files.asByteSink
30-
[OAK-11387] - Extract ListUtils from CollectionUtils
31-
[OAK-11388] - Extract MapUtils from CollectionUtils
32-
[OAK-11395] - Extract SetUtils from CollectionUtils
33-
[OAK-11396] - Remove usage of Guava Preconditions.checkElementIndex
34-
[OAK-11398] - Remove usage of Guava Preconditions.checkPositionIndexes
35-
[OAK-11399] - Remove usage of Guava io.BaseEncoding
36-
[OAK-11400] - Remove usage of Guava ArrayListMultimap
37-
[OAK-11402] - Remove usage of Guava Strings.isNullOrEmpty
38-
[OAK-11406] - Remove usage of Guava io.ByteSource
39-
[OAK-11407] - Remove usage of Guava Strings.EMPTY_STRING
40-
[OAK-11408] - Extract IteratorUtils from CollectionUtils
41-
[OAK-11411] - Remove usage of Guava Strings.emptyToNull
42-
[OAK-11413] - Extract DequeUtils from CollectionUtils
43-
[OAK-11414] - make collectionutils package private
44-
[OAK-11417] - Remove usage of Guava ByteStreams
45-
[OAK-11420] - Remove usage of Guava Files.move()
46-
[OAK-11422] - Remove usage of Guava Strings
47-
[OAK-11424] - Remove usage of Guava ObjectArrays.concat
48-
[OAK-11427] - Remove usage of Guava Iterables.isEmpty
49-
[OAK-11428] - Remove usage of Guava Files.copy()
50-
[OAK-11430] - Remove usage of Guava Iterables.all
51-
[OAK-11431] - Remove usage of Guava Files.createTempDir()
52-
[OAK-11432] - Remove usage of Guava Iterables.size
53-
[OAK-11440] - Remove usage of Guava Files.touch()
54-
[OAK-11441] - Remove usage of Guava Iterables.addAll
55-
[OAK-11442] - Remove usage of Guava Iterables.contains
56-
[OAK-11445] - Remove usage of Guava Files.toString()
57-
[OAK-11446] - Remove usage of Guava Files.equal()
58-
[OAK-11448] - Remove usage of Guava Files.readLines()
59-
[OAK-11449] - Remove usage of Guava Iterables.concat() [test cases only]
29+
[OAK-11473] - Remove usage of Guava ImmutableSet (again)
30+
[OAK-11585] - Add Iterators.contains replacement in IteratorUtils
31+
[OAK-11587] - Add Iterators.asEnumeration replacement in IteratorUtils
32+
[OAK-11588] - Add Iterators.toArray replacement in IteratorUtils
33+
[OAK-11590] - Remove usage of Iterators.getLast()
34+
[OAK-11591] - Remove usage of Iterators.contains()
35+
[OAK-11592] - Remove usage of Iterators.asEnumeration()
36+
[OAK-11593] - Remove usage of Iterators.toArray()
37+
[OAK-11612] - Remove usage of Sets.union [2]
38+
[OAK-11618] - Remove usage of Guava Stopwatch
39+
[OAK-11620] - Create replacement for Guava Stopwatch
40+
[OAK-11621] - Reduce usage of Guava Ticker
41+
[OAK-11640] - Remove usage of Guava ImmutableSet.Builder
42+
[OAK-11646] - Remove usage of Guava ImmutableSet.of
43+
[OAK-11652] - Remove usage of Guava Iterators.forArray
44+
[OAK-11654] - Remove usage of Guava Suppliers.ofInstance
45+
[OAK-11663] - Remove usage of Guava Iterators.filter()
46+
[OAK-11664] - Remove usage of Guava Iterators.transform()
47+
[OAK-11665] - Remove usage of Guava Iterators.singletonIterator()
48+
[OAK-11666] - Remove usage of Guava Iterators.concat()
49+
[OAK-11668] - Remove usage of Guava Iterators.mergeSorted()
50+
[OAK-11669] - Add Iterators.concat() replacement in IteratorUtils
51+
[OAK-11674] - Add Iterators.filter() replacement in IteratorUtils
52+
[OAK-11676] - Add Iterators.transform() replacement in IteratorUtils
53+
[OAK-11677] - Remove usage of Guava Iterators.elementsEqual()
54+
[OAK-11678] - Remove usage of Guava Iterators.cycle()
55+
[OAK-11680] - Add Iterators.cycle() replacement in IteratorUtils
56+
[OAK-11688] - Remove usage of Guava Iterators.getOnlyElement()
57+
[OAK-11689] - Remove usage of Guava Iterators.addAll()
58+
[OAK-11690] - Remove usage of Guava Iterators.partition()
59+
[OAK-11691] - Add Iterators.partition() replacement in IteratorUtils
60+
[OAK-11705] - Remove usage of Guava Iterators.asEnumeration()
61+
[OAK-11706] - Add Iterators.limit() replacement in IteratorUtils
62+
[OAK-11707] - Remove usage of Guava Iterators.limit()
6063

6164
Bug
6265

63-
[OAK-11287] - Cleanup May Delete Referenced Segments
64-
[OAK-11401] - Increase Log levels for FullGC deletion logs to INFO
65-
[OAK-11409] - Membership cache fails to update changes on cached properties
66-
[OAK-11423] - Jdbc driver dependencies need to have scope compile in order to be included in oak-run.
67-
[OAK-11425] - MarkSweepGarbageColllector.iterateNodeTree() passes open file to FileIOUtils.sort()
68-
[OAK-11433] - Create separate config variable for fullGC max revision age millis and apply it in VersionGarbageCollector
69-
[OAK-11434] - oak-run: DataStoreCheckCommand tries to move open files
70-
[OAK-11439] - Provide support to set remaining full gc modes
71-
[OAK-11450] - GlobalNameMapper.isExpandedName() does sometimes return incorrect results
72-
[OAK-11453] - Provide support to set fullGC max revision age millis from oak-run
66+
[OAK-9584] - JCR methods only support qualified names but not expanded names for namespace prefix "rep:".
67+
[OAK-11452] - Expose FullGC OSGi config via metrics
68+
[OAK-11634] - Add Osgi config for FullGC generation value
69+
[OAK-11639] - oak-run-commons: IncrementalFlatFileStoreStrategy uses com.google.common classes (instead of shaded ones)
70+
[OAK-11673] - Oak-segment-azure v12 CPU increase caused by refreshLease
71+
[OAK-11685] - Reduce log level for MongoFullGcNodeBin class
72+
[OAK-11695] - Elasticsearch queries might produce inconsistent results
73+
[OAK-11704] - Update Mockito dependency to 5.17.0
74+
[OAK-11719] - vector query should not break normal query
75+
76+
Epic
77+
78+
[OAK-11703] - Oak should compile & test on Java 24
79+
80+
Story
81+
82+
[OAK-11671] - [full-gc] Persist the avg object size and avg size of props per document in Mongo settings
83+
84+
New Feature
85+
86+
[OAK-11720] - Put the usage of exclusive merge lock for large transactions behind a FeatureToggle/OSGI config
7387

7488
Improvement
7589

76-
[OAK-9500] - Automatically deploy snapshot artifacts to Maven repo through GHA
77-
[OAK-11312] - Refactor CollectionUtils
78-
[OAK-11364] - For oak-jcr tests, support automatic starting/stopping of docker containers used as RDB servers for RDBDocumentStore
79-
[OAK-11365] - Incremental index store: ability to set a timeout
80-
[OAK-11383] - Improve performance of DefaultStatisticsProvider
81-
[OAK-11389] - Disable Checkstyle
82-
[OAK-11416] - Docker support for oak-jcr tests with RdbDocumentStore needs a way to specify environment variables for the container
83-
[OAK-11418] - RdbConnectionUtils should use SystemPropertySupplier
84-
[OAK-11421] - Update MySql JDBC driver version to com.mysql:mysql-connector-j:9.0.1 in profile rdb-mysql
90+
[OAK-11545] - oak-search-elastic: implement bulk processor pool to optimize indexing
91+
[OAK-11607] - Node.getNodes() not lazy for orderable nodetypes
92+
[OAK-11638] - Elastic: ignore standard token filter configurations
93+
[OAK-11655] - Do not create redundant instances of ElasticBulkProcessorHandler
94+
[OAK-11658] - Indexing job: fix "jcr:uuid" issue
95+
[OAK-11687] - DataStore FileCache Memory Usage
96+
[OAK-11692] - Add inference config in oak.
97+
[OAK-11693] - Parse inference query and extract out inference config and text query
98+
[OAK-11694] - Implement inference in oak-search-elastic
99+
[OAK-11709] - Merging index definitions: merge "tags" and override "type", "async"
100+
[OAK-11721] - experimental and inferenceConfig implementation should be backward compatible
101+
[OAK-11722] - Donot read compatibility system property in VectorQuery for each query
85102

86103
Task
87104

88-
[OAK-11027] - flaky IncrementalStoreTest
89-
[OAK-11264] - CacheWarming tests seems flaky
90-
[OAK-11286] - blob-cloud, segment: update netty version to 4.1.115
91-
[OAK-11394] - Avoid creation of iterator object when creating a CompositeEditor
92-
[OAK-11412] - indexing job: delay creation of index writers backend until the start of the indexing phase
93-
[OAK-11415] - TypeEditor: constraint exception for node type violations should contain that node's effective type
94-
[OAK-11419] - oak-store-document - persistent cache: remove unused UDP/TCP broadcasters
95-
[OAK-11470] - Undo changes to remove usage of Guava ImmutableSet
105+
[OAK-11572] - Add api(s) in IteratorUtils to remove guava Iterators usage
106+
[OAK-11609] - Add Prometheus metrics export via pushgateway to RevisionsCommand (oak-run)
107+
[OAK-11622] - Clock improvements
108+
[OAK-11625] - Move o.a.j.o.plugins.bundlor.BundlingConfigInitializer to a suitable API package and export that package.
109+
[OAK-11642] - oak-segment-tar uses unmaintained concurrentlinkedhashmap-lru
110+
[OAK-11643] - Update (shaded) Guava to 33.4.7
111+
[OAK-11650] - Fix Javadoc errors
112+
[OAK-11675] - Clean oak-segment-azure lib exporting
113+
[OAK-11681] - Clean oak-segment-azure lib exporting
114+
[OAK-11684] - Send fullGC metrics to Prometheus pushgateway on each garbage collection iteration
115+
[OAK-11698] - webapp: update Tomcat dependency to 9.0.104
116+
[OAK-11699] - Update commons-collections4 to 4.5.0
117+
[OAK-11700] - Update (shaded) Guava to 33.4.8
118+
[OAK-11701] - Upgrade jackson-databind dependency to 2.17.3
119+
[OAK-11708] - Update Easymock dependency to 5.5
120+
[OAK-11710] - Update jacoco plugin to 0.8.13
121+
[OAK-11714] - Add jmx to expose inferenceConfig
122+
[OAK-11716] - Capture inference service stats
96123

97124

98125
In addition to the above-mentioned changes, this release contains all

oak-api/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<parent>
2020
<groupId>org.apache.jackrabbit</groupId>
2121
<artifactId>oak-parent</artifactId>
22-
<version>1.77-SNAPSHOT</version>
22+
<version>1.81-SNAPSHOT</version>
2323
<relativePath>../oak-parent/pom.xml</relativePath>
2424
</parent>
2525
<modelVersion>4.0.0</modelVersion>

oak-run-commons/src/test/java/org/apache/jackrabbit/oak/index/indexer/document/flatfile/analysis/stream/VarIntTest.java renamed to oak-api/src/main/java/org/apache/jackrabbit/oak/api/jmx/InferenceMBean.java

Lines changed: 16 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -16,30 +16,25 @@
1616
* specific language governing permissions and limitations
1717
* under the License.
1818
*/
19-
package org.apache.jackrabbit.oak.index.indexer.document.flatfile.analysis.stream;
19+
package org.apache.jackrabbit.oak.api.jmx;
2020

21-
import static org.junit.Assert.assertEquals;
22-
23-
import java.io.ByteArrayInputStream;
24-
import java.io.ByteArrayOutputStream;
25-
import java.io.IOException;
26-
27-
import org.junit.Test;
21+
import org.osgi.annotation.versioning.ProviderType;
2822

2923
/**
30-
* Tests for variable size integer streaming.
24+
* An MBean that provides the inference configuration.
3125
*/
32-
public class VarIntTest {
26+
@ProviderType
27+
public interface InferenceMBean {
28+
29+
String TYPE = "Inference";
30+
31+
/**
32+
* Get the inference configuration as a Json string.
33+
*/
34+
String getConfigJson();
3335

34-
@Test
35-
public void test() throws IOException {
36-
for (int i = 1; i > 0; i *= 2) {
37-
ByteArrayOutputStream out = new ByteArrayOutputStream();
38-
NodeStreamConverter.writeVarInt(out, i);
39-
ByteArrayInputStream in = new ByteArrayInputStream(out.toByteArray());
40-
int test = NodeStreamReader.readVarInt(in);
41-
assertEquals(test, i);
42-
assertEquals(-1, in.read());
43-
}
44-
}
36+
/**
37+
* Get the inference configuration as a Json string.
38+
*/
39+
String getConfigNodeStateJson();
4540
}

oak-api/src/main/java/org/apache/jackrabbit/oak/api/jmx/QueryEngineSettingsMBean.java

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,20 @@ public interface QueryEngineSettingsMBean {
107107
*/
108108
void setFailTraversal(boolean failTraversal);
109109

110+
/**
111+
* Get whether the query engine will parse the query and infers inference config
112+
*
113+
* @return true if inference is enabled
114+
*/
115+
boolean isInferenceEnabled();
116+
117+
/**
118+
* Set whether to parse for inference index config to use from query.
119+
*
120+
* @param isInferenceEnabled the new value for this setting
121+
*/
122+
void setInferenceEnabled(boolean isInferenceEnabled);
123+
110124
/**
111125
* Whether the query result size should return an estimation for large queries.
112126
*

oak-api/src/main/java/org/apache/jackrabbit/oak/api/jmx/RepositoryManagementMBean.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -49,23 +49,23 @@
4949
* system is in a state where it does not allow the operation to
5050
* be carried out (e.g. the operation is already running). The
5151
* {@code message} should give further indication of the exact
52-
* reason.</li>
52+
* reason.
5353
* <li>{@code 1}: <em>Status not available</em>. Usually because
5454
* there was no prior attempt to start the operation. The
5555
* {@code message} should give further indication of the exact
56-
* reason.</li>
56+
* reason.
5757
* <li>{@code 2}: <em>Operation initiated</em>. The {@code message}
5858
* should give further information of when the operation was
5959
* initiated. This status mean that the operation will be performed
6060
* some time in the future without impacting overall system behaviour
6161
* and that no further status updates will be available until this
62-
* operation is performed next time.</li>
63-
* <li>{@code 3}: <em>Operation running</em>.</li>
62+
* operation is performed next time.
63+
* <li>{@code 3}: <em>Operation running</em>.
6464
* <li>{@code 4}: <em>Operation succeeded</em>. The {@code message} should
6565
* give further information on how long the operation took to
66-
* complete.</li>
66+
* complete.
6767
* <li>{@code 5}: Operation failed. The {@code message} should give
68-
* further information on the reason for the failure.</li>
68+
* further information on the reason for the failure.
6969
* </ul>
7070
* <p>
7171
* In all cases the {@code message} may provide additional information

oak-api/src/main/java/org/apache/jackrabbit/oak/api/jmx/package-info.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
* limitations under the License.
1616
*/
1717

18-
@Version("4.13.0")
18+
@Version("4.14.0")
1919
package org.apache.jackrabbit.oak.api.jmx;
2020

2121
import org.osgi.annotation.versioning.Version;

oak-auth-external/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
<parent>
2424
<groupId>org.apache.jackrabbit</groupId>
2525
<artifactId>oak-parent</artifactId>
26-
<version>1.77-SNAPSHOT</version>
26+
<version>1.81-SNAPSHOT</version>
2727
<relativePath>../oak-parent/pom.xml</relativePath>
2828
</parent>
2929

oak-auth-external/src/main/java/org/apache/jackrabbit/oak/spi/security/authentication/external/basic/DefaultSyncConfig.java

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,12 @@
1818

1919
import java.util.Collections;
2020
import java.util.HashSet;
21+
import java.util.LinkedHashSet;
2122
import java.util.Map;
2223
import java.util.Set;
24+
import java.util.stream.Collectors;
25+
import java.util.stream.Stream;
2326

24-
import org.apache.jackrabbit.guava.common.collect.ImmutableSet;
2527
import org.jetbrains.annotations.NotNull;
2628

2729
/**
@@ -203,9 +205,9 @@ public Authorizable setAutoMembershipConfig(@NotNull AutoMembershipConfig autoMe
203205
*/
204206
@NotNull
205207
public Set<String> getAutoMembership(@NotNull org.apache.jackrabbit.api.security.user.Authorizable authorizable) {
206-
return ImmutableSet.<String>builder().
207-
addAll(autoMembershipConfig.getAutoMembership(authorizable)).
208-
addAll(getAutoMembership()).build();
208+
return Collections.unmodifiableSet((Set<String>)
209+
Stream.concat(autoMembershipConfig.getAutoMembership(authorizable).stream(), getAutoMembership().stream())
210+
.collect(Collectors.toCollection(LinkedHashSet::new)));
209211
}
210212

211213
/**
@@ -413,12 +415,12 @@ public static class Group extends Authorizable {
413415
/**
414416
* <p>Returns {@code true} if external group identities are being synchronized into the repository as dynamic groups.
415417
* In this case a dedicated {@link org.apache.jackrabbit.oak.spi.security.user.DynamicMembershipProvider} must be
416-
* present in order to have group membership reflected through User Management API.</p>
418+
* present in order to have group membership reflected through User Management API.
417419
*
418420
* <p>Note, that currently this option only takes effect if it is enabled together with dynamic membership
419421
* (i.e. {@link User#getDynamicMembership()} returns true). In this case a dedicated
420422
* {@link org.apache.jackrabbit.oak.spi.security.user.DynamicMembershipProvider} based on the
421-
* {@code ExternalGroupPrincipalProvider} will be registered.</p>
423+
* {@code ExternalGroupPrincipalProvider} will be registered.
422424
*
423425
* @return {@code true} if external groups should be synchronized as dynamic groups (i.e. without having their
424426
* members added); {@code false} otherwise. Note, that this option currently only takes effect if {@link User#getDynamicMembership()} is enabled.

oak-auth-external/src/main/java/org/apache/jackrabbit/oak/spi/security/authentication/external/impl/DefaultSyncHandler.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
package org.apache.jackrabbit.oak.spi.security.authentication.external.impl;
1818

1919
import org.apache.jackrabbit.guava.common.collect.Iterators;
20+
import org.apache.jackrabbit.oak.commons.collections.IteratorUtils;
2021
import org.osgi.service.component.annotations.Component;
2122
import org.osgi.service.component.annotations.Activate;
2223
import org.osgi.service.component.annotations.Deactivate;
@@ -226,7 +227,7 @@ public String getName() {
226227

227228
@Override
228229
public Iterator<Authorizable> getAutoMembers(@NotNull UserManager userManager, @NotNull Group group) {
229-
return Iterators.concat(getServices().stream().map(autoMembershipConfig -> autoMembershipConfig.getAutoMembers(userManager, group)).iterator());
230+
return IteratorUtils.chainedIterator(getServices().stream().map(autoMembershipConfig -> autoMembershipConfig.getAutoMembers(userManager, group)).iterator());
230231
}
231232
}
232233
}

oak-auth-external/src/main/java/org/apache/jackrabbit/oak/spi/security/authentication/external/impl/DynamicSyncContext.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@
1616
*/
1717
package org.apache.jackrabbit.oak.spi.security.authentication.external.impl;
1818

19-
import org.apache.jackrabbit.guava.common.collect.Iterables;
2019
import org.apache.jackrabbit.api.security.user.Authorizable;
2120
import org.apache.jackrabbit.api.security.user.Group;
2221
import org.apache.jackrabbit.api.security.user.UserManager;
22+
import org.apache.jackrabbit.oak.commons.collections.IterableUtils;
2323
import org.apache.jackrabbit.oak.spi.security.authentication.external.ExternalGroup;
2424
import org.apache.jackrabbit.oak.spi.security.authentication.external.ExternalIdentity;
2525
import org.apache.jackrabbit.oak.spi.security.authentication.external.ExternalIdentityException;
@@ -234,7 +234,7 @@ private Map<ExternalIdentityRef, SyncEntry> collectSyncEntries(@NotNull Iterable
234234
*/
235235
private void collectSyncEntries(@NotNull Iterable<ExternalIdentityRef> declaredGroupRefs, long depth, @NotNull Map<ExternalIdentityRef, SyncEntry> map) throws ExternalIdentityException, RepositoryException {
236236
boolean shortcut = shortcut(depth);
237-
for (ExternalIdentityRef ref : Iterables.filter(declaredGroupRefs, this::isSameIDP)) {
237+
for (ExternalIdentityRef ref : IterableUtils.filter(declaredGroupRefs, this::isSameIDP)) {
238238
String principalName = null;
239239
Authorizable a = null;
240240
ExternalGroup externalGroup = null;

0 commit comments

Comments
 (0)