cisco-system-traffic-generator / trex-java-sdk Goto Github PK
View Code? Open in Web Editor NEWJava client SDK API
License: Apache License 2.0
Java client SDK API
License: Apache License 2.0
Due to this issue, #636 there was a need to change the major API version to 5.0 (STL)
I will add the commit once it will be ready.
The high level changes from client side are:
get_async_events
with session_id
as an input. Each session will have a seperate queue for events. session_id is a unique number per sessionseq
from type ```uint32``. Client could check that there is no missing events using this counter.when i use the TrexClient method stopTraffic(int portIndex) i get JSON error respons from server(v2.29):
INFO : Call stop_traffic method.
INFO : JSON Req: {"method":"stop_traffic","id":"aggogxls","jsonrpc":"2.0","params":{"api_h":"Ptr5c4Rb","port_id":1}}
INFO : JSON Resp: [{"error":{"code":-32602,"message":"Bad paramters for method","specific_err":"field 'handler' is missing"},"id":"aggogxls","jsonrpc":"2.0"}]
Have i done something wrong or have something changed in recent version of trex or sdk?
Hi,
Current trex-java-sdk can supports stateless mode only.
But, we need to use java based ASTF APIs.
Q1. Do you have plan to support ASTF APIs in trex-java-sdk?
Q2. Do you have any additional information about ASTF RPC commands?
Current ASTF RPC command manual is not enough for us and referring the existing Python based ASTF API library code is time consuming job.
Thanks
Best Regards
Gwangmoon
Hi,
Im not sure if this should be here because it is not a issue more of a question how to use the packet capture in the sdk. Maybe i should ask this in the google trex group instead?
My problem is that i can't figure out or find any info how to use trex java sdk to get captured packets and do anything with them, this is how far i got:
CapturedPackets captureStream = trex.stopCapture(rxPort, captureId);
List capturedPackets = captureStream.getPkts();
System.out.print("First captured packet origin:" + capturedPackets.get(1).getOrigin());
But i want to see the complete packet and do checks on it like if it had expected vlan header.
How do i accomplish this?
I couldn't find this library deployed to any remote repository like maven central: http://central.maven.org/maven2/
Example: https://mvnrepository.com/search?q=trex-java-sdk
while other trex libraries do exist: https://mvnrepository.com/search?q=trex
What I would like to achieve is to use this library simply by including it in my maven pom file or my gradle file and avoid building an jar myself
(Am I just stupid who are not able to find it? )
Hi @hhaim
After major version update, Java API and TRex should have exactly same version.
It's really picky issue because we have too many Java client users with various versions of TRex server and Java APIs.
Currently, with this major update, the version of all Java client and TRex server should be synchronized at the same time.
It's hard to handle for large scaled distributed users.
We need temporary coexisting period before uplifting peers.
Maybe 2 options would be possible,
Do you have any suggestion regarding this issue?
Hi,
Can you provide a simple example of how to use VM Instruction in Stream using SDK?
Thanks.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.