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

Unexpected exception: /tmp/QuickPerf-7265351587637478002/allocation.ser (No such file or directory) #218

Open
ennishol opened this issue Mar 16, 2024 · 1 comment
Labels
🐛 bug Something isn't working

Comments

@ennishol
Copy link

Hello I've tried a simple quarkus 3.8.2 demo application and got the error:

Stack trace
java.lang.IllegalStateException: java.io.FileNotFoundException: /tmp/QuickPerf-7265351587637478002/allocation.ser (No such file or directory)
	at org.quickperf.repository.ObjectInputStreamBuilder.buildFileInputStream(ObjectInputStreamBuilder.java:46)
	at org.quickperf.repository.ObjectInputStreamBuilder.buildObjectInputStream(ObjectInputStreamBuilder.java:28)
	at org.quickperf.repository.LongFileRepository.retrieveLongValueFromFile(LongFileRepository.java:42)
	at org.quickperf.repository.LongFileRepository.find(LongFileRepository.java:37)
	at org.quickperf.jvm.allocation.AllocationRepository.findAllocation(AllocationRepository.java:32)
	at org.quickperf.jvm.allocation.bytewatcher.ByteWatcherRecorder.findRecord(ByteWatcherRecorder.java:45)
	at org.quickperf.jvm.allocation.bytewatcher.ByteWatcherRecorder.findRecord(ByteWatcherRecorder.java:19)
	at org.quickperf.issue.PerfIssuesEvaluator.findPerfRecord(PerfIssuesEvaluator.java:91)
	at org.quickperf.issue.PerfIssuesEvaluator.buildPerfRecordByAnnotation(PerfIssuesEvaluator.java:81)
	at org.quickperf.issue.PerfIssuesEvaluator.evaluatePerfIssuesIfNoJvmIssueWithPotentialUnexpectedException(PerfIssuesEvaluator.java:59)
	at org.quickperf.issue.PerfIssuesEvaluator.evaluatePerfIssuesIfNoJvmIssue(PerfIssuesEvaluator.java:38)
	at org.quickperf.junit5.QuickPerfTestExtension.processJvmOrTestIssue(QuickPerfTestExtension.java:164)
	at org.quickperf.junit5.QuickPerfTestExtension.interceptTestMethod(QuickPerfTestExtension.java:130)
	at org.junit.jupiter.engine.execution.InterceptingExecutableInvoker$ReflectiveInterceptorCall.lambda$ofVoidMethod$0(InterceptingExecutableInvoker.java:103)
	at org.junit.jupi

code

package org.acme;

import io.quarkus.test.junit.QuarkusTest;
import org.junit.jupiter.api.Test;
import org.quickperf.junit5.QuickPerfTest;
import org.quickperf.jvm.allocation.AllocationUnit;
import org.quickperf.jvm.annotations.ExpectMaxHeapAllocation;
import org.quickperf.jvm.annotations.MeasureHeapAllocation;

import static io.restassured.RestAssured.given;
import static org.hamcrest.CoreMatchers.is;

@QuickPerfTest
@QuarkusTest
class GreetingResourceTest {


    @MeasureHeapAllocation
    @ExpectMaxHeapAllocation(value = 1, unit = AllocationUnit.GIGA_BYTE)
    @Test
    void testHelloEndpoint() {
        given()
          .when().get("/hello")
          .then()
             .statusCode(200)
             .body(is("Hello s e a"));
    }

}
@ennishol ennishol added the 🐛 bug Something isn't working label Mar 16, 2024
@jeanbisutti
Copy link
Collaborator

The JVM annotations don't work with Quarkus.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants