# Custom VTK objects on server-side only

**URL:** https://discourse.paraview.org/t/custom-vtk-objects-on-server-side-only/1315
**Category:** Development
**Created:** [February 18, 2019, 9:33am UTC](https://discourse.paraview.org/t/custom-vtk-objects-on-server-side-only/1315 "2019-02-18T09:33:03Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![lhofmann](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/l/9e8a1a/32.png) [@lhofmann](https://discourse.paraview.org/u/lhofmann)
#### Post date: [February 18, 2019, 9:33am UTC](https://discourse.paraview.org/t/custom-vtk-objects-on-server-side-only/1315/1 "2019-02-18T09:33:03Z")

</div>

When running a `pvserver` with external plugins, these plugins do not need to be loaded on the client, and everything will work as expected, as long as they only produce standard VTK objects.

However, if a plugin creates a custom VTK object as output, on the client-side I get the error

> vtkSMDataTypeDomain: Unable to create instance of class ‘MyCustomObject’.

In my use-case, these objects only carry some intermediate results (and are later converted to standard VTK objects by other filters), and do not need to exist on the client-side.

Is there any workaround for this, that does not involve loading the plugin on the client-side?

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [February 18, 2019, 11:42am UTC](https://discourse.paraview.org/t/custom-vtk-objects-on-server-side-only/1315/2 "2019-02-18T11:42:44Z")

</div>

No, but you may be able to work around this using a Factory on the server side.  
It allows you to replace an existing class by one of your own.  
See : `VTK/Common/Core/Testing/Cxx/TestObjectFactory.cxx`

Of course, you could always not expose the intermediate output and collapse multiples filters into one.
