Appendix A. Configuration Properties

Note that the property names below are defined as constants in org.apache.cayenne.configuration.Constants interface.

Table A.1. Configuration Properties Recognized by ServerRuntime and/or ClientRuntime
Property Possible Values Default Value
cayenne.jdbc.driver[.domain_name.node_name] - defines a JDBC driver class to use when creating a DataSource. If domain name and optionally - node name are specified, the setting overrides DataSource info just for this domain/node. Otherwise the override is applied to all domains/nodes in the system. none, project DataNode configuration is used
cayenne.jdbc.url[.domain_name.node_name] - defines a DB URL to use when creating a DataSource. If domain name and optionally - node name are specified, the setting overrides DataSource info just for this domain/node. Otherwise the override is applied to all domains/nodes in the system. none, project DataNode configuration is used
cayenne.jdbc.username[.domain_name.node_name] - defines a DB user name to use when creating a DataSource. If domain name and optionally - node name are specified, the setting overrides DataSource info just for this domain/node. Otherwise the override is applied to all domains/nodes in the system. none, project DataNode configuration is used
cayenne.jdbc.password[.domain_name.node_name] - defines a DB password to use when creating a DataSource. If domain name and optionally - node name are specified, the setting overrides DataSource info just for this domain/node. Otherwise the override is applied to all domains/nodes in the system none, project DataNode configuration is used
cayenne.jdbc.min_connections[.domain_name.node_name] - defines the DB connection pool minimal size. If domain name and optionally - node name are specified, the setting overrides DataSource info just for this domain/node. Otherwise the override is applied to all domains/nodes in the system none, project DataNode configuration is used
cayenne.jdbc.max_connections[.domain_name.node_name] - defines the DB connection pool maximum size. If domain name and optionally - node name are specified, the setting overrides DataSource info just for this domain/node. Otherwise the override is applied to all domains/nodes in the system none, project DataNode configuration is used
cayenne.querycache.size - An integer defining the maximum number of entries in the query cache. Note that not all QueryCache providers may respect this property. MapQueryCache uses it, but the rest would use alternative configuration methods. any positive int value 2000
cayenne.server.contexts_sync_strategy - defines whether peer ObjectContexts should receive snapshot events after commits from other contexts. If true (default), the contexts would automatically synchronize their state with peers. true, false true
cayenne.server.object_retain_strategy - defines fetched objects retain strategy for ObjectContexts. When weak or soft strategy is used, objects retained by ObjectContext that have no local changes can potetially get garbage collected when JVM feels like doing it. weak, soft, hard weak
cayenne.server.max_id_qualifier_size - defines a maximum number of ID qualifiers in the WHERE clause of queries that are generated for paginated queries and for DISJOINT_BY_ID prefetch processing. This is needed to avoid hitting WHERE clause size limitations and memory usage efficiency. any positive int 10000
cayenne.rop.service_url - defines the URL of the ROP server
cayenne.rop.service_username - defines the user name for an ROP client to login to an ROP server.
cayenne.rop.service_password - defines the password for an ROP client to login to an ROP server.
cayenne.rop.shared_session_name- defines the name of the shared session that an ROP client wants to join on an ROP server. If omitted, a dedicated session is created.
cayenne.rop.service.timeout - a value in milliseconds for the ROP client-server connection read operation timeout any positive long value
cayenne.rop.channel_events - defines whether client-side DataChannel should dispatch events to child ObjectContexts. If set to true, ObjectContexts will receive commit events and merge changes committed by peer contexts that passed through the common client DataChannel. true, false false
cayenne.rop.context_change_events- defines whether object property changes in the client context result in firing events. Client UI components can listen to these events and update the UI. Disabled by default. true, false false
cayenne.rop.context_lifecycle_events - defines whether object commit and rollback operations in the client context result in firing events. Client UI components can listen to these events and update the UI. Disabled by default. true,false false
cayenne.server.rop_event_bridge_factory - defines the name of the org.apache.cayenne.event.EventBridgeFactory that is passed from the ROP server to the client. I.e. server DI would provide a name of the factory, passing this name to the client via the wire. The client would instantiate it to receive events from the server. Note that this property is stored in "cayenne.server.rop_event_bridge_properties" map, not in the main "cayenne.properties".