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

[Transaction][buffer] Add basic operation of transaction #4738

Merged
merged 18 commits into from
Aug 2, 2019

Conversation

zymap
Copy link
Member

@zymap zymap commented Jul 16, 2019


Modifications

Add primary operation of transaction. Keep all actions persistently. (except the index persistent, the persistent logic will add in next pull request)

Describe the modifications you've done.

  • add commit operation
  • add abort operation
  • add open-reader operation
  • add purge transaction operation
  • add tests

@zymap
Copy link
Member Author

zymap commented Jul 16, 2019

@sijie PTAL

import org.apache.bookkeeper.mledger.Position;
import org.apache.pulsar.transaction.impl.common.TxnID;

public interface TransactionCursor {
Copy link
Member

Choose a reason for hiding this comment

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

add comment for this interface.

also please add comments for the @param in following methods.

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks for your reminder. I will add later.


@Override
public CompletableFuture<SortedMap<Long, Position>> readEntries(int num, long startSequenceId) {
return null;
Copy link
Member

Choose a reason for hiding this comment

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

return CompletableFuture.failedFuture(new UnsupportedOperationException());

Copy link
Member Author

Choose a reason for hiding this comment

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

Got it.

@@ -99,6 +99,8 @@
long committedAtLedgerId,
long committedAtEntryId);

CompletableFuture<Void> commitTxn(TxnID txnID, long committedAtLedgerId, long committedAtEntryId, ByteBuf marker);
Copy link
Member

Choose a reason for hiding this comment

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

I am not sure why do you need marker in commitTxn and abortTxn. The caller of this interface doesn't provide the marker. The marker should be part of the implementation not the interface.

Copy link
Member Author

Choose a reason for hiding this comment

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

So the marker in data ledgers is different from the transaction log?


@Override
public CompletableFuture<TransactionMeta> getTransactionMeta(TxnID txnID) {
CompletableFuture<TransactionMeta> getFuture = new CompletableFuture<>();
Copy link
Member

Choose a reason for hiding this comment

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

I don't think you need additional getFuture here.

it should just be :

return txnCursor.getTxnMeta(txnID, false);

Copy link
Member Author

Choose a reason for hiding this comment

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

Yep

}

@Override
public CompletableFuture<Void> appendBufferToTxn(TxnID txnId, long sequenceId, ByteBuf buffer) {
Copy link
Member

Choose a reason for hiding this comment

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

It seems that sequenceId is not used in publishMessage. sequenceId should be used for de-duplication.

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. I should add it to TxnCtx.

ByteBuf marker) {
CompletableFuture<Void> commitFuture = new CompletableFuture<>();

publishMessage(marker, new TxnCtx() {
Copy link
Member

Choose a reason for hiding this comment

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

The marker should be generated within this implementation.


CompletableFuture<Void> abortFuture = new CompletableFuture<>();

publishMessage(marker, new TxnCtx() {
Copy link
Member

Choose a reason for hiding this comment

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

marker should be prepared in this implementation.

import org.apache.pulsar.transaction.buffer.exceptions.TransactionNotFoundException;
import org.apache.pulsar.transaction.impl.common.TxnID;

public class TransactionCursorImpl implements TransactionCursor {
Copy link
Member

Choose a reason for hiding this comment

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

the transaction cursor is used for persistent transaction buffer. but you are using an in-memory implementation of transaction metadata. this doesn't seem to be right.

@sijie sijie added this to the 2.5.0 milestone Jul 17, 2019
@zymap zymap changed the title [WIP][Transaction][buffer] Add basic operation of transaction [Transaction][buffer] Add basic operation of transaction Jul 22, 2019
@Override
void close();

CompletableFuture<Void> closeBuffer();
Copy link
Member

Choose a reason for hiding this comment

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

closeAsync()?

@@ -125,7 +123,5 @@
/**
* {@inheritDoc}
Copy link
Member

Choose a reason for hiding this comment

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

change the comment. since it doesn't inherit from AutoCloseable anymore.

* @param ledgerId the transaction committed ledger id
* @return
*/
CompletableFuture<Set<TxnID>> getRemoveTxns(long ledgerId);
Copy link
Member

Choose a reason for hiding this comment

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

getAllTxnsCommitedAtLedger ?

* @param ledgerId the remove transaction id
* @return
*/
CompletableFuture<Void> removeCommittedLedger(long ledgerId);
Copy link
Member

Choose a reason for hiding this comment

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

removeTxnsCommittedAtLedger

CompletableFuture<Set<TxnID>> getRemoveTxns(long ledgerId);

/**
* Remove transaction from index.
Copy link
Member

Choose a reason for hiding this comment

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

Update the comments please

}


dataLedgers.forEach(dataLedger -> {
Copy link
Member

Choose a reason for hiding this comment

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

purgeFuture need to wait all dataLedgers are deleted. but the implementation here doesn't guarantee it.

private CompletableFuture<Void> deleteTxn(TxnID txnID) {
CompletableFuture<Void> deleteFuture = new CompletableFuture<>();

txnCursor.getTxnMeta(txnID, false).thenCompose(meta -> {
Copy link
Member

Choose a reason for hiding this comment

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

return txnCursor.getTxnMeta(txnID, false)
    .thenCompose(meta -> meta.readEntries(...))
    .thenCompose(positions -> {
    ...
    });

Marker commitMarker = Marker.builder().txnID(txnID).status(TxnStatus.COMMITTED).build();
ByteBuf marker = Unpooled.wrappedBuffer(commitMarker.serialize());

txnCursor.getTxnMeta(txnID, false).thenCompose(meta -> {
Copy link
Member

Choose a reason for hiding this comment

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

return txnCursor.getTxnMeta(txnID, false)
     .thenCompose(meta -> publishMarker())
     .thenCompose(position -> txnCursor.commitTxn(...));


txnCursor.getTxnMeta(txnID, false).thenCompose(meta -> {
meta.readEntries(meta.numEntries(), -1L).thenCompose(longPositionSortedMap -> {
longPositionSortedMap.values().forEach(position -> {
Copy link
Member

Choose a reason for hiding this comment

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

CompletableFuture<Void> asyncMarkDelete(position);

List<CompletableFuture<Void>> deleteFutures = longPositionSortedMap.values()
     .stream()
     .map(position -> asyncMarkDelete())
     .collect(Collectors.toList());

return CompletableFuture.allOf(deleteFutures).thenApply(ignored -> null);

public CompletableFuture<List<TransactionEntry>> readNext(int numEntries) {
CompletableFuture<List<TransactionEntry>> readFuture = new CompletableFuture<>();

meta.readEntries(numEntries, currentSeuquenceId).thenCompose(entries -> {
Copy link
Member

Choose a reason for hiding this comment

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

return meta.readEntries(numEntries, currentSequenceId)
    .thenCompose(entries -> readEntry(entries);
meta.readEntries(...).whenComplete((entries, cause) -> {
    if (null != cause) {
       ///
    } else {
       ....
    }
});

@@ -123,9 +121,9 @@
CompletableFuture<Void> purgeTxns(List<Long> dataLedgers);

/**
* {@inheritDoc}
* Close the buffer asynchronous.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
* Close the buffer asynchronous.
* Close the buffer asynchronously.

import org.apache.pulsar.transaction.impl.common.TxnID;

/**
* The transaction Cursor maintained the index of all transaction.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
* The transaction Cursor maintained the index of all transaction.
* The transaction Cursor maintains the index of all transactions.

package org.apache.pulsar.transaction.buffer.exceptions;

/**
* Exception when get a non exist committed ledger.
Copy link
Member

Choose a reason for hiding this comment

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

Exception is thrown when no transactions found committed at a given ledger.



@Override
public String getProducerName() {
Copy link
Member

Choose a reason for hiding this comment

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

The producer name should be transaction id. Because pulsar is using producer name for de-duplications. You need to guarantee the messages produced by a transaction is not duplicated when we produce them to the transaction buffer.

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. yes.

return FutureUtil.waitForAll(removeFutures);
}

private CompletableFuture<Void> deleteLedger(long dataledger) {
Copy link
Member

Choose a reason for hiding this comment

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

I don't think we should call it deleteLedger

Copy link
Member Author

Choose a reason for hiding this comment

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

How about cleanTxnsOnLedger() ?

public CompletableFuture<Void> removeTxnsCommittedAtLedger(long ledgerId) {

synchronized (committedTxnIndex) {
Set<TxnID> txnIDS = committedTxnIndex.remove(ledgerId);
Copy link
Member

Choose a reason for hiding this comment

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

txnIDs can be null

if (startSequenceId != -1L) {
readEntries = entries.tailMap(startSequenceId);
}
if (startSequenceId == -2L) {
Copy link
Member

Choose a reason for hiding this comment

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

define constants for -1L and -2L

}

if (num != 0) {
result.put(-2L, PositionImpl.earliest);
Copy link
Member

Choose a reason for hiding this comment

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

what is this used for?

}

@Override
public CompletableFuture<TransactionMeta> commitTxn(long committedAtLedgerId, long committedAtEntryId) {
Copy link
Member

Choose a reason for hiding this comment

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

You need to synchronize the method when you modifying the txnStatus

return abortFuture;
}

this.txnStatus = TxnStatus.ABORTED;
Copy link
Member

Choose a reason for hiding this comment

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

synchronize accessing txnStatus

@zymap
Copy link
Member Author

zymap commented Jul 26, 2019

@sijie This pr is ready for review. Please take a look when you have time. Thanks.

@zymap
Copy link
Member Author

zymap commented Jul 28, 2019

run java8 tests

@sijie
Copy link
Member

sijie commented Jul 31, 2019

@zymap can you rebase this pull request since #4826 is merged?

zymap added 17 commits July 31, 2019 10:18
---

*Modifications*

Add primary operation of transaction. Keep all actions persistently.

Describe the modifications you've done.

- add commit operation
- add abort operation
- add openreader operation

*TODO*

- add purge txn operation
- add tests
---

(If this PR fixes a github issue, please add `Fixes #<xyz>`)

Fixes #<xyz>

(or if this PR is one task of a github issue, please add `Master Issue: #<xyz>`
to link to the master issue)

Master Issue: #<xyz>

*Motivation*

Describe here the context, and why you're making that change.
What is the problem you're trying to solve.

*Modifications*

Describe the modifications you've done.

*Verify this change*

Please pick either of following options.

- This change is a trivial rework / code cleanup without any test coverage.
- This change is already covered by existing tests, such as *(please describe tests)*.
- This change added tests and can be verified as follows:
  *(example:)*
  - *Added integration tests for end-to-end deployment*
  - *Extended integration test for recovery after broker failure*
@zymap
Copy link
Member Author

zymap commented Jul 31, 2019

run java8 tests
run cpp tests
run integration tests

@zymap
Copy link
Member Author

zymap commented Aug 1, 2019

run integration tests

@zymap
Copy link
Member Author

zymap commented Aug 1, 2019

run java8 tests

3 similar comments
@zymap
Copy link
Member Author

zymap commented Aug 1, 2019

run java8 tests

@zymap
Copy link
Member Author

zymap commented Aug 1, 2019

run java8 tests

@zymap
Copy link
Member Author

zymap commented Aug 1, 2019

run java8 tests

@zymap
Copy link
Member Author

zymap commented Aug 1, 2019

run cpp tests
run integration tests

@sijie
Copy link
Member

sijie commented Aug 1, 2019

run java8 tests

4 similar comments
@zymap
Copy link
Member Author

zymap commented Aug 1, 2019

run java8 tests

@zymap
Copy link
Member Author

zymap commented Aug 1, 2019

run java8 tests

@zymap
Copy link
Member Author

zymap commented Aug 2, 2019

run java8 tests

@zymap
Copy link
Member Author

zymap commented Aug 2, 2019

run java8 tests

@zymap
Copy link
Member Author

zymap commented Aug 2, 2019

ci error

[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 12.145 s - in org.apache.pulsar.stats.client.PulsarBrokerStatsClientTest
[INFO] 
[INFO] Results:
[INFO] 
[ERROR] Failures: 
[ERROR]   PulsarFunctionStateTest.shutdown:223 » PulsarServer org.apache.pulsar.broker.P...
[ERROR] org.apache.pulsar.functions.worker.PulsarFunctionStateTest.testPulsarFunctionState(org.apache.pulsar.functions.worker.PulsarFunctionStateTest)
[INFO]   Run 1: PASS
[ERROR]   Run 2: PulsarFunctionStateTest.testPulsarFunctionState » ThreadTimeout Method org.apa...
[INFO] 
[INFO] 
[ERROR] Tests run: 1230, Failures: 2, Errors: 0, Skipped: 0
[INFO] 
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO] 
[INFO] Pulsar Build Tools ................................. SUCCESS [  5.992 s]
[INFO] Pulsar ............................................. SUCCESS [  4.792 s]
[INFO] Pulsar Client :: API ............................... SUCCESS [  4.697 s]
[INFO] Pulsar Common ...................................... SUCCESS [01:45 min]
[INFO] Managed Ledger ..................................... SUCCESS [03:02 min]
[INFO] Managed Ledger ..................................... SUCCESS [ 28.815 s]
[INFO] Apache Pulsar :: Jclouds shaded .................... SUCCESS [  4.034 s]
[INFO] Apache Pulsar :: Tiered Storage :: Parent .......... SUCCESS [  0.058 s]
[INFO] Apache Pulsar :: Tiered Storage :: JCloud .......... SUCCESS [ 35.804 s]
[INFO] Apache Pulsar :: Tiered Storage :: File System ..... SUCCESS [ 25.186 s]
[INFO] Pulsar ZooKeeper Utils ............................. SUCCESS [ 53.140 s]
[INFO] pulsar-broker-common ............................... SUCCESS [  9.908 s]
[INFO] Pulsar Functions :: Parent ......................... SUCCESS [  0.170 s]
[INFO] Pulsar Functions :: Proto .......................... SUCCESS [  5.942 s]
[INFO] Pulsar Client Java ................................. SUCCESS [02:12 min]
[INFO] Pulsar Discovery Service WAR ....................... SUCCESS [ 22.868 s]
[INFO] Pulsar WebSocket ................................... SUCCESS [ 11.438 s]
[INFO] Pulsar Client Admin Original ....................... SUCCESS [  4.105 s]
[INFO] Pulsar Transaction :: Parent ....................... SUCCESS [  1.516 s]
[INFO] Pulsar Transaction :: Common ....................... SUCCESS [  3.317 s]
[INFO] Pulsar Functions :: API ............................ SUCCESS [  3.233 s]
[INFO] Pulsar IO :: Parent ................................ SUCCESS [  0.202 s]
[INFO] Pulsar IO :: IO .................................... SUCCESS [  4.754 s]
[INFO] Pulsar Functions :: Utils .......................... SUCCESS [ 17.975 s]
[INFO] Pulsar Functions :: Secrets ........................ SUCCESS [  6.201 s]
[INFO] Pulsar Functions :: Instance ....................... SUCCESS [ 32.211 s]
[INFO] Pulsar Functions :: Runtime ........................ SUCCESS [ 19.675 s]
[INFO] Pulsar IO :: Cassandra ............................. SUCCESS [  2.773 s]
[INFO] Pulsar IO :: IO Common ............................. SUCCESS [  3.483 s]
[INFO] Pulsar IO :: Twitter ............................... SUCCESS [  4.189 s]
[INFO] Pulsar Functions :: Worker ......................... SUCCESS [01:36 min]
[INFO] Pulsar Functions :: Local Runner original .......... SUCCESS [  2.528 s]
[INFO] Pulsar Functions :: API Examples ................... SUCCESS [  2.252 s]
[INFO] Pulsar IO :: Data Generator ........................ SUCCESS [  2.314 s]
[INFO] Pulsar Broker ...................................... FAILURE [  01:27 h]
[INFO] Pulsar Shaded Broker ............................... SKIPPED
[INFO] Pulsar Client Java ................................. SKIPPED
[INFO] Pulsar Client 1.x Compatibility Base ............... SKIPPED
[INFO] Pulsar Client 2.x Shaded API ....................... SKIPPED
[INFO] Pulsar Client 1.x Compatibility API ................ SKIPPED
[INFO] Pulsar Client Admin ................................ SKIPPED
[INFO] Pulsar Client Tools ................................ SKIPPED
[INFO] Pulsar Client Tools Test ........................... SKIPPED
[INFO] Pulsar Client All .................................. SKIPPED
[INFO] Pulsar Proxy ....................................... SKIPPED
[INFO] Pulsar Storm adapter ............................... SKIPPED
[INFO] Pulsar Flink Connectors ............................ SKIPPED
[INFO] Spark Streaming Pulsar Receivers ................... SKIPPED
[INFO] Pulsar Test Client ................................. SKIPPED
[INFO] pulsar-broker-auth-athenz .......................... SKIPPED
[INFO] pulsar-client-auth-athenz .......................... SKIPPED
[INFO] Pulsar Kafka compatibility ......................... SKIPPED
[INFO] Pulsar Kafka compatibility :: API (original) ....... SKIPPED
[INFO] Pulsar Kafka compatibility :: API .................. SKIPPED
[INFO] Pulsar Kafka compatibility :: Tests ................ SKIPPED
[INFO] pulsar-zookeeper ................................... SKIPPED
[INFO] Pulsar Log4j2 Appender ............................. SKIPPED
[INFO] Pulsar SQL :: Parent ............................... SKIPPED
[INFO] Pulsar SQL :: Pulsar Presto Connector Packaging .... SKIPPED
[INFO] Pulsar SQL :: Pulsar Presto Connector .............. SKIPPED
[INFO] Pulsar SQL :: Pulsar Presto Distribution ........... SKIPPED
[INFO] Apache Pulsar :: Docker Images ..................... SKIPPED
[INFO] Apache Pulsar :: Docker Images :: Pulsar Dashboard . SKIPPED
[INFO] pulsar-client-auth-sasl ............................ SKIPPED
[INFO] pulsar-broker-auth-sasl ............................ SKIPPED
[INFO] Pulsar Transaction :: Buffer ....................... SKIPPED
[INFO] Pulsar Transaction :: Coordinator .................. SKIPPED
[INFO] Pulsar Functions :: Runtime All .................... SKIPPED
[INFO] Pulsar Functions :: Local Runner Shaded ............ SKIPPED
[INFO] Pulsar IO :: Canal ................................. SKIPPED
[INFO] Pulsar IO :: ElasticSearch ......................... SKIPPED
[INFO] Pulsar IO :: Hdfs2 ................................. SKIPPED
[INFO] Pulsar IO :: Hdfs3 ................................. SKIPPED
[INFO] Pulsar IO :: Jdbc .................................. SKIPPED
[INFO] Pulsar IO :: Kafka ................................. SKIPPED
[INFO] Pulsar IO :: Kinesis ............................... SKIPPED
[INFO] Pulsar IO :: RabbitMQ .............................. SKIPPED
[INFO] Pulsar IO :: Docs .................................. SKIPPED
[INFO] Pulsar IO :: Aerospike ............................. SKIPPED
[INFO] Pulsar IO :: Kafka Connect Adaptor ................. SKIPPED
[INFO] Pulsar IO :: Debezium .............................. SKIPPED
[INFO] Pulsar IO :: Debezium :: Core ...................... SKIPPED
[INFO] Pulsar IO :: Debezium :: mysql ..................... SKIPPED
[INFO] Pulsar IO :: Debezium :: postgres .................. SKIPPED
[INFO] Pulsar IO :: File .................................. SKIPPED
[INFO] Pulsar IO :: Netty ................................. SKIPPED
[INFO] Pulsar IO :: Hbase ................................. SKIPPED
[INFO] Pulsar IO :: MongoDB ............................... SKIPPED
[INFO] Pulsar IO :: Flume ................................. SKIPPED
[INFO] Pulsar IO :: Redis ................................. SKIPPED
[INFO] Pulsar IO :: Solr .................................. SKIPPED
[INFO] Pulsar IO :: InfluxDB .............................. SKIPPED
[INFO] Pulsar Examples :: Parent .......................... SKIPPED
[INFO] Pulsar Examples :: Flink ........................... SKIPPED
[INFO] Pulsar Examples :: Spark ........................... SKIPPED
[INFO] Pulsar :: Distribution ............................. SKIPPED
[INFO] Pulsar :: Distribution :: Server ................... SKIPPED
[INFO] Pulsar :: Distribution :: IO ....................... SKIPPED
[INFO] Pulsar :: Distribution :: Offloader ................ SKIPPED
[INFO] Apache Pulsar :: Docker Images :: Pulsar Latest Version SKIPPED
[INFO] Apache Pulsar :: Docker Images :: Grafana .......... SKIPPED
[INFO] Apache Pulsar :: Docker Images :: Pulsar Latest Version (Include All Components) SKIPPED
[INFO] Apache Pulsar :: Docker Images :: Pulsar Standalone  SKIPPED
[INFO] Apache Pulsar :: Tests ............................. SKIPPED
[INFO] Apache Pulsar :: Tests :: Docker Images ............ SKIPPED
[INFO] Apache Pulsar :: Tests :: Docker Images :: Java Test Functions SKIPPED
[INFO] Apache Pulsar :: Tests :: Docker Images :: Latest Version Testing SKIPPED
[INFO] Apache Pulsar :: Tests :: Integration .............. SKIPPED
[INFO] Apache Pulsar :: Tests :: Pulsar Kafka Compat Client Tests SKIPPED
[INFO] Pulsar Storm adapter Tests ......................... SKIPPED
[INFO] Spark Streaming Pulsar Receivers Tests ............. SKIPPED
[INFO] Apache Pulsar :: Tests :: Backwards Client Compatibility 2.0.0-rc1-incubating SKIPPED
[INFO] Apache Pulsar :: Tests :: Backwards Client Compatibility 2.0.1-incubating SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:41 h
[INFO] Finished at: 2019-08-02T05:07:19Z
[INFO] Final Memory: 140M/828M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M3:test (default-test) on project pulsar-broker: There are test failures.
[ERROR] 
[ERROR] Please refer to /home/jenkins/jenkins-slave/workspace/pulsar_precommit_java8/pulsar-broker/target/surefire-reports for the individual test results.
[ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream.
[ERROR] ExecutionException The forked VM terminated without properly saying goodbye. VM crash or System.exit called?
[ERROR] Command was /bin/sh -c cd /home/jenkins/jenkins-slave/workspace/pulsar_precommit_java8/pulsar-broker && /usr/local/asfpackages/java/jdk1.8.0_191/jre/bin/java -Xmx2G -Dpulsar.allocator.pooled=false -Dpulsar.allocator.leak_detection=Advanced -Dlog4j.configurationFile=log4j2.xml -jar /home/jenkins/jenkins-slave/workspace/pulsar_precommit_java8/pulsar-broker/target/surefire/surefirebooter630013254843664538.jar /home/jenkins/jenkins-slave/workspace/pulsar_precommit_java8/pulsar-broker/target/surefire 2019-08-02T03-25-50_052-jvmRun1 surefire8731022403484129561tmp surefire_2691044522144839903405tmp
[ERROR] Error occurred in starting fork, check output in log
[ERROR] Process Exit Code: 255
[ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: ExecutionException The forked VM terminated without properly saying goodbye. VM crash or System.exit called?
[ERROR] Command was /bin/sh -c cd /home/jenkins/jenkins-slave/workspace/pulsar_precommit_java8/pulsar-broker && /usr/local/asfpackages/java/jdk1.8.0_191/jre/bin/java -Xmx2G -Dpulsar.allocator.pooled=false -Dpulsar.allocator.leak_detection=Advanced -Dlog4j.configurationFile=log4j2.xml -jar /home/jenkins/jenkins-slave/workspace/pulsar_precommit_java8/pulsar-broker/target/surefire/surefirebooter630013254843664538.jar /home/jenkins/jenkins-slave/workspace/pulsar_precommit_java8/pulsar-broker/target/surefire 2019-08-02T03-25-50_052-jvmRun1 surefire8731022403484129561tmp surefire_2691044522144839903405tmp
[ERROR] Error occurred in starting fork, check output in log
[ERROR] Process Exit Code: 255
[ERROR] 	at org.apache.maven.plugin.surefire.booterclient.ForkStarter.awaitResultsDone(ForkStarter.java:511)
[ERROR] 	at org.apache.maven.plugin.surefire.booterclient.ForkStarter.runSuitesForkPerTestSet(ForkStarter.java:458)
[ERROR] 	at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:299)
[ERROR] 	at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:247)
[ERROR] 	at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1161)
[ERROR] 	at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(AbstractSurefireMojo.java:1002)
[ERROR] 	at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(AbstractSurefireMojo.java:848)
[ERROR] 	at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
[ERROR] 	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
[ERROR] 	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:154)
[ERROR] 	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:146)
[ERROR] 	at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:117)
[ERROR] 	at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:81)
[ERROR] 	at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
[ERROR] 	at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
[ERROR] 	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:309)
[ERROR] 	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:194)
[ERROR] 	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:107)
[ERROR] 	at org.apache.maven.cli.MavenCli.execute(MavenCli.java:993)
[ERROR] 	at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:345)
[ERROR] 	at org.apache.maven.cli.MavenCli.main(MavenCli.java:191)
[ERROR] 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[ERROR] 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[ERROR] 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[ERROR] 	at java.lang.reflect.Method.invoke(Method.java:498)
[ERROR] 	at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
[ERROR] 	at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
[ERROR] 	at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
[ERROR] 	at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
[ERROR] Caused by: org.apache.maven.surefire.booter.SurefireBooterForkException: The forked VM terminated without properly saying goodbye. VM crash or System.exit called?
[ERROR] Command was /bin/sh -c cd /home/jenkins/jenkins-slave/workspace/pulsar_precommit_java8/pulsar-broker && /usr/local/asfpackages/java/jdk1.8.0_191/jre/bin/java -Xmx2G -Dpulsar.allocator.pooled=false -Dpulsar.allocator.leak_detection=Advanced -Dlog4j.configurationFile=log4j2.xml -jar /home/jenkins/jenkins-slave/workspace/pulsar_precommit_java8/pulsar-broker/target/surefire/surefirebooter630013254843664538.jar /home/jenkins/jenkins-slave/workspace/pulsar_precommit_java8/pulsar-broker/target/surefire 2019-08-02T03-25-50_052-jvmRun1 surefire8731022403484129561tmp surefire_2691044522144839903405tmp
[ERROR] Error occurred in starting fork, check output in log
[ERROR] Process Exit Code: 255
[ERROR] 	at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:670)
[ERROR] 	at org.apache.maven.plugin.surefire.booterclient.ForkStarter.access$600(ForkStarter.java:116)
[ERROR] 	at org.apache.maven.plugin.surefire.booterclient.ForkStarter$2.call(ForkStarter.java:445)
[ERROR] 	at org.apache.maven.plugin.surefire.booterclient.ForkStarter$2.call(ForkStarter.java:421)
[ERROR] 	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[ERROR] 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[ERROR] 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[ERROR] 	at java.lang.Thread.run(Thread.java:748)
[ERROR] -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
[ERROR] 
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <goals> -rf :pulsar-broker
Build step 'Invoke top-level Maven targets' marked build as failure
Archiving artifacts
Recording test results
Setting status of c94da65b7fbd2140817244fefcaddf89ec679542 to FAILURE with url https://builds.apache.org/job/pulsar_precommit_java8/10574/ and message: 'FAILURE
 '
Using context: Jenkins: Java 8 - Unit Tests
Finished: FAILURE

@zymap
Copy link
Member Author

zymap commented Aug 2, 2019

run java8 tests

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants