All Downloads are FREE. Search and download functionalities are using the official Maven repository.

eu.luminis.websocket.Sample Maven / Gradle / Ivy

Go to download

JMeter add-on that defines a number of samplers for load testing WebSocket applications.

The newest version!
package eu.luminis.websocket;

import java.net.URL;

public class Sample {

    public static void main(String[] args) throws Exception {
        WebSocketClient webSocketClient = new WebSocketClient(new URL("http://echo.websocket.org:80"));
        webSocketClient.connect(5_000, 5_000);
        webSocketClient.sendTextFrame("he, hello, hier venray");
        Frame receivedFrame = webSocketClient.receiveFrame(5_000);
        System.out.println("Received frame " + receivedFrame);
        webSocketClient.close(1000, "", 5_000);
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy