Sites

Menu
These are the docs for 14.2, an old version of SpatialOS. The docs for this version are frozen: we do not correct, update or republish them. 14.5 is the newest →

Component filters

How you set up component filters depends on whether you’re using chunk-based interest (CBI) or query-based interest (QBI).

  • If you’re using CBI, you must specify which components a worker instance can receive updates about. You do this using component filters. This is in addition to setting up read access permission.

    Deprecating CBI and component filters


    We recommend that you move towards using only QBI, because we plan to deprecate and then remove CBI (including component filters). QBI is a more precise, granular alternative to CBI, and you can use it to achieve the same results as CBI and component filters.

    We will give advance warning of the deprecation and removal of CBI, along with upgrade guides to help you move completely from CBI to QBI.

  • If you’re using only QBI, you must set up the static component filter in a specific way - see Component delivery and QBI. You can ignore the dynamic component filter.

The static component filter (all entities)

Use the component delivery field (in the bridge configuration section of the worker configuration file) to specify the components that worker instances of a particular type can receive updates about. You can either set checkoutAllInitially to true to allow all components, or you can whitelist individual components using checkout_initially.

Static component filtering acts as a whitelist, and takes precedence over CBI. By default, no components are whitelisted. This means that you need to whitelist a component (or set checkoutAllInitially to true) for CBI to work.

The dynamic component filter (specific entities)

You can set up filters on specific entities during runtime via a message to SpatialOS (see the API documentation for C++/C#/Java).

You set up dynamic component filters to override the static component filter.


————
2019-11-15 Page updated with editorial review: Clarified that this page focuses on CBI, not QBI.

Search results

Was this page helpful?

Thanks for letting us know!

Thanks for your feedback

Need more help? Ask on the forums