Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ProtocolException in getChildren()

Tags:

java

kurento

When I try to call getChildren() on the mediapipeline which has my custom module endpoint running in it I'm getting this exception:

org.kurento.client.internal.server.ProtocolException: Exception creating Java Class for mycustomfilter.MyCustomFilter

This is the code which triggers it:

List<MediaObject> mediaObjects = pipelines.get(i).getChildren();

Do I have to cast the List<MediaObject> to some other data type?

like image 469
Sagar Pilkhwal Avatar asked Jan 29 '17 08:01

Sagar Pilkhwal


1 Answers

When you create a custom media element for KMS, you can also create the client API for Java and JavaScript (see doc here). In your case, you need to create the Java client for your filter, as follows:

cmake .. -DGENERATE_JAVA_CLIENT_PROJECT=TRUE

The resulting Java classes (package mycustomfilter.MyCustomFilter in your example) should be in the classpath of the project which calls to getChildren() (internally it calls to Class.forName, see code here).

like image 195
Boni García Avatar answered Oct 20 '22 19:10

Boni García