Custom port issue


I'm getting following errors when I'm trying to register my custom port as an extension.

ERROR     ModalContext PortTypeRegistry     Could not create port object serializer for 'some.package.SomePortObject' from plug-in 'some.plugin': Plug-in "some.plugin" was unable to instantiate class "some.package.SomePortObject$SomeSerializer".
ERROR     ModalContext PortTypeRegistry     CODING PROBLEM    Port object implementation 'some.package.SomePortObject' is not registered at extension point 'org.knime.core.PortType' via it's serializer, using buddy classloading as fallback. Please change your implementation and use the extension point.

The class for serializer exists.

Any ideas what could be a problem?




Have you added this to the relevent extension point?

Yes I did as follows:



Did you declare the inner class SomeSerializer public static?

Thanks qqilihq. It helped. I had it defined with default access modifier.

Then I had problems with generics. I resolved it too.

But now I have another problem. When I'm loading the workflow I got following errors:


Unable to load node with ID suffix 674 into workflow, skipping it: null

Unable to load node with ID suffix 675 into workflow, skipping it: null


When I open the workflow the node is missing. When I try to add it I get follwoing error:


Node cannot be created.

The selected node could not be created due to the following reason:

Could not initialize class some.package.SomeNodeModel.


Any idea what could cause this issue?


I enabled debug logs. I found this, but I'm still hopeless.


Caused by: java.lang.ClassCastException: sun.reflect.generics.reflectiveObjects.TypeVariableImpl cannot be cast to java.lang.Class
    at org.knime.core.node.port.PortObject$PortObjectSerializer.getObjectClass(
    at org.knime.core.node.port.PortTypeRegistry.createObjectSerializer(
    at org.knime.core.node.port.PortTypeRegistry.scanExtensionPointForObjectSerializer(
    at org.knime.core.node.port.PortTypeRegistry.getObjectClass(
    at org.knime.core.node.port.PortTypeRegistry.createPortTypes(
    at org.knime.core.node.port.PortTypeRegistry.getPortType(
    at org.knime.core.node.port.PortTypeRegistry.getPortType(


Any idea what could be a problem?