Skip to content

Commit

Permalink
X.26 (#1554)
Browse files Browse the repository at this point in the history
* Initial branch of x.26

* Review deprecated methods, change build to error on deprecation (#1551)

* Review deprecated methods, change build to error on deprecation

* <release>8</release>

* Fix compilation on Java 21

* Don't use OS.getUsrDir() yet

* Use release 8 only for Java 11+

* Turn off implicit annotation processing

* Turn off implicit annotation processing

* Add expected exception

* Add ignored error

* Use a common configuration for the compiler-plugin where deprecation … (#1553)

* Use a common configuration for the compiler-plugin where deprecation warnings cause the build to fail

* Use a common configuration for the compiler-plugin where deprecation warnings cause the build to fail

* Deprecate RollCycles legacy code.

* Deprecate due x.26.

* Tidy up compiler setting and some warnings

* Reduce the number of raw types

* remove deprecated MultiQueue classes

* Remove deprecated methods (#1557)

* Remove deprecated methods

* remove deprecated SuppressWarnings

* resolve Javadoc issues

* Added fail on warning lint for Javadoc, and rawtypes fixes for Bytes (#1558)

* import net.openhft.chronicle.wire.Sequence

* serializable warning suppressed

* Fix warnings following rebase with develop

* Add methods for clear() and emptyHistory() to reduce direct references to VanillaMessageHistory

* Fix warnings following rebase with develop

* PretouchUtil deprecated

* PretouchUtil deprecated

* Fix deprecation issues in Java 17+

* Fix newlines

* redundant newline

* redundant spaces

* </p> tag in javadoc not allowed

* Javadoc fixes

* Javadoc fixes

* TimeoutPauser -> YieldingPauser

* ChronicleQueue#createPretoucherEventHandler

* ChronicleReader suppress empty message. Closes #1579

* TimeoutPauser -> YieldingPauser

* parent poms -> x.26.0

* Where marked for removal, also mark for deprecation

---------

Co-authored-by: Peter Lawrey <peter.lawrey@chronicle.software>
Co-authored-by: Jerry Shea <jerry.shea@chronicle.software>
  • Loading branch information
3 people committed May 28, 2024
1 parent 91bc0e9 commit 89cde94
Show file tree
Hide file tree
Showing 142 changed files with 370 additions and 1,141 deletions.
1 change: 1 addition & 0 deletions README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -1182,6 +1182,7 @@ If you want to write to the below "doit" method
public interface MyInterface {
void doit(DTO dto);
}

public class DTO extends SelfDescribingMarshallable {
private int age;
private String name;
Expand Down
27 changes: 4 additions & 23 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,12 @@
<parent>
<groupId>net.openhft</groupId>
<artifactId>java-parent-pom</artifactId>
<version>1.25.4</version>
<version>1.26.0</version>
<relativePath />
</parent>

<artifactId>chronicle-queue</artifactId>

<version>5.25ea18-SNAPSHOT</version>
<version>5.26ea0-SNAPSHOT</version>
<packaging>bundle</packaging>
<name>OpenHFT/Chronicle Queue</name>
<description>Java library for persisted low latency messaging (Java 8+)</description>
Expand All @@ -43,14 +42,14 @@
<dependency>
<groupId>net.openhft</groupId>
<artifactId>third-party-bom</artifactId>
<version>3.24.0</version>
<version>3.26.0</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>net.openhft</groupId>
<artifactId>chronicle-bom</artifactId>
<version>2.25ea-SNAPSHOT</version>
<version>2.26ea-SNAPSHOT</version>
<type>pom</type>
<scope>import</scope>
</dependency>
Expand Down Expand Up @@ -282,16 +281,6 @@
</executions>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.8</source>
<target>1.8</target>
<encoding>UTF-8</encoding>
</configuration>
</plugin>

<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
Expand Down Expand Up @@ -435,14 +424,6 @@
</execution>
</executions>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<configuration>
<source>8</source>
</configuration>
</plugin>
</plugins>
<resources>
<resource>
Expand Down
8 changes: 4 additions & 4 deletions src/main/java/net/openhft/chronicle/queue/ChronicleQueue.java
Original file line number Diff line number Diff line change
Expand Up @@ -58,13 +58,13 @@
* <p>{@link ChronicleQueue} (now in the specific sense) is the main interface for management and
* can be seen as the "Collection class" of the <em>Chronicle</em> environment. You will reserve a
* portion of memory and then put/fetch/update records using the {@link ChronicleQueue}
* interface.</p>
* interface.
* <p>{@link ExcerptCommon} is the main data container in a {@link ChronicleQueue}, each Chronicle
* is composed of Excerpts. Putting data to a queue means starting a new Excerpt, writing data into
* it and finishing the Excerpt at the upper.</p>
* it and finishing the Excerpt at the upper.
* <p>While {@link ExcerptCommon} is a generic purpose container allowing for remote access, it also
* has more specialized counterparts for sequential operations. See {@link ExcerptTailer} and {@link
* ExcerptAppender}</p>
* ExcerptAppender}
*
* @author peter.lawrey
*/
Expand Down Expand Up @@ -346,7 +346,7 @@ default void dump(@NotNull OutputStream stream, long fromIndex, long toIndex) {
* @throws NullPointerException if any of the provided parameters are {@code null}.
*/
@NotNull
default <T> T methodWriter(@NotNull final Class<T> tClass, Class... additional) {
default <T> T methodWriter(@NotNull final Class<T> tClass, Class<?>... additional) {
VanillaMethodWriterBuilder<T> builder = methodWriterBuilder(tClass);
Stream.of(additional).forEach(builder::addInterface);
return builder.build();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
import org.jetbrains.annotations.Nullable;

/**
* <p>The component that facilitates sequentially writing data to a {@link ChronicleQueue}.</p>
* <p><b>NOTE:</b> Appenders are NOT thread-safe, sharing the Appender between threads will lead to errors and unpredictable behaviour.</p>
* <p>The component that facilitates sequentially writing data to a {@link ChronicleQueue}.
* <p><b>NOTE:</b> Appenders are NOT thread-safe, sharing the Appender between threads will lead to errors and unpredictable behaviour.
*/
@SingleThreaded
public interface ExcerptAppender extends ExcerptCommon<ExcerptAppender>, MarshallableOut {
Expand All @@ -40,7 +40,7 @@ public interface ExcerptAppender extends ExcerptCommon<ExcerptAppender>, Marshal
* @param bytes to write to excerpt.
* @throws UnrecoverableTimeoutException if the operation times out.
*/
void writeBytes(@NotNull BytesStore bytes);
void writeBytes(@NotNull BytesStore<?,?> bytes);

/**
* Writes (i.e. appends) the provided {@code bytes} to the queue.
Expand Down Expand Up @@ -109,7 +109,7 @@ default void pretouch() {
*/
@NotNull
@Override
default <T> T methodWriter(@NotNull Class<T> tClass, Class... additional) {
default <T> T methodWriter(@NotNull Class<T> tClass, Class<?>... additional) {
return queue().methodWriter(tClass, additional);
}

Expand Down
3 changes: 1 addition & 2 deletions src/main/java/net/openhft/chronicle/queue/ExcerptTailer.java
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
/**
* The component that facilitates sequentially reading data from a {@link ChronicleQueue}.
*
* <p><b>NOTE:</b> Tailers are NOT thread-safe, sharing a Tailer between threads will lead to errors and unpredictable behaviour.</p>
* <p><b>NOTE:</b> Tailers are NOT thread-safe, sharing a Tailer between threads will lead to errors and unpredictable behaviour.
*/
@SingleThreaded
public interface ExcerptTailer extends ExcerptCommon<ExcerptTailer>, MarshallableIn, SourceContext {
Expand Down Expand Up @@ -214,7 +214,6 @@ default void readAfterReplicaAcknowledged(boolean readAfterReplicaAcknowledged)
/**
* Allows you to control the number of in flight messages that are allowed when setting {@code acknowledgedIndexReplicatedCheck}, By default, this is set to:
* <p>
* <p>
* By providing a custom implementation of {@code acknowledgedIndexReplicatedCheck} you can control the number of in-flight messages that are allowed before the message is available to be read by the tailer.
* And in addition, then acknowledgedIndexReplicatedCheck will be set to true.
* <p>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,10 @@
*/
package net.openhft.chronicle.queue;

import net.openhft.chronicle.wire.MessageHistory;
import net.openhft.chronicle.wire.*;

// Is this being used?
@SuppressWarnings("deprecation")
public enum NoMessageHistory implements MessageHistory {
INSTANCE;

Expand Down
Loading

0 comments on commit 89cde94

Please sign in to comment.