couchbase.php
INI entries:
-
couchbase.log_level
(string), default:"WARN"
controls amount of information, the module will send to PHP error log. Accepts the following values in order of increasing verbosity:
"FATAL"
,"ERROR"
,"WARN"
,"INFO"
,"DEBUG"
,"TRACE"
. -
couchbase.encoder.format
(string), default:"json"
selects serialization format for default encoder (\Couchbase\defaultEncoder). Accepts the following values:
-
"json"
- encodes objects and arrays as JSON object (usingjson_encode()
), primitives written in stringified form, which is allowed for most of the JSON parsers as valid values. For empty arrays JSON array preferred, if it is necessary, usenew stdClass()
to persist empty JSON object. Note, that only JSON format considered supported by all Couchbase SDKs, everything else is private implementation (i.e."php"
format won't be readable by .NET SDK). -
"php"
- uses PHP serialize() method to encode the document.
-
-
couchbase.encoder.compression
(string), default:"none"
selects compression algorithm. Also see related compression options below. Accepts the following values:
-
"fastlz"
- uses FastLZ algorithm. The module might be configured to use system fastlz library during build, othewise vendored version will be used. This algorithm is always available. -
"zlib"
- uses compression implemented by libz. Might not be available, if the system didn't have libz headers during build phase. In this case \Couchbase\HAVE_ZLIB will be false. -
"off"
or"none"
- compression will be disabled, but the library will still read compressed values.
-
-
couchbase.encoder.compression_threshold
(int), default:0
controls minimum size of the document value in bytes to use compression. For example, if threshold 100 bytes, and the document size is 50, compression will be disabled for this particular document.
-
couchbase.encoder.compression_factor
(float), default:0.0
controls the minimum ratio of the result value and original document value to proceed with persisting compressed bytes. For example, the original document consists of 100 bytes. In this case factor 1.0 will require compressor to yield values not larger than 100 bytes (100/1.0), and 1.5 -- not larger than 66 bytes (100/1.5).
-
couchbase.decoder.json_arrays
(boolean), default:true
controls the form of the documents, returned by the server if they were in JSON format. When true, it will generate arrays of arrays, otherwise instances of stdClass.
-
couchbase.pool.max_idle_time_sec
(int), default:60
controls the maximum interval the underlying connection object could be idle, i.e. without any data/query operations. All connections which idle more than this interval will be closed automatically. Cleanup function executed after each request using RSHUTDOWN hook.
-
couchbase.allow_fallback_to_bucket_connection
(boolean), default:false
allows the library to switch to bucket connection when the connection string includes bucket name. It is useful when the application connects to older Couchbase Server, that does not have G3CP feature.
Interfaces, Classes and Traits
- MutationToken
- An object which contains meta information of the document needed to enforce query consistency.
- QueryMetaData
- Interface for retrieving metadata such as errors and metrics generated during N1QL queries.
- SearchMetaData
- Interface for retrieving metadata such as error counts and metrics generated during search queries.
- ViewMetaData
- Interface for retrieving metadata generated during view queries.
- Result
- Base interface for all results generated by KV operations.
- GetResult
- Interface for results created by the get operation.
- GetReplicaResult
- Interface for results created by the getReplica operation.
- ExistsResult
- Interface for results created by the exists operation.
- MutationResult
- Interface for results created by operations that perform mutations.
- CounterResult
- Interface for results created by the counter operation.
- LookupInResult
- Interface for results created by the lookupIn operation.
- MutateInResult
- Interface for results created by the mutateIn operation.
- QueryResult
- Interface for retrieving results from N1QL queries.
- AnalyticsResult
- Interface for retrieving results from analytics queries.
- TermFacetResult
- A range (or bucket) for a term search facet result.
- NumericRangeFacetResult
- A range (or bucket) for a numeric range facet result. Counts the number of matches that fall into the named range (which can overlap with other user-defined ranges).
- DateRangeFacetResult
- A range (or bucket) for a date range facet result. Counts the number of matches that fall into the named range (which can overlap with other user-defined ranges).
- SearchFacetResult
- Interface representing facet results.
- SearchResult
- Interface for retrieving results from search queries.
- ViewResult
- Interface for retrieving results from view queries.
- AnalyticsLinkType
- AnalyticsEncryptionLevel
- AnalyticsLink
- EvictionPolicy
- StorageBackend
- LookupInSpec
- LookupInSpec is an interface for providing subdocument lookup operations.
- MutateInSpec
- MutateInSpec is an interface for providing subdocument mutation operations.
- SearchHighlightMode
- SearchQuery
- Common interface for all classes, which could be used as a body of SearchQuery
- SearchFacet
- Common interface for all search facets
- SearchSort
- Base interface for all FTS sort options in querying.
- SearchSortType
- SearchSortMode
- SearchSortMissing
- DurabilityLevel
- An object which contains levels of durability that can be enforced when using mutation operations.
- StoreSemantics
- An object which contains how to define the document level action to take during a MutateIn operation.
- ViewConsistency
- ViewOrdering
- QueryScanConsistency
- Set of values for the scan consistency level of a query.
- QueryProfile
- Set of values for setting the profile mode of a query.
- ValueRecorder
- Provides an interface for recording values.
- Meter
- Providers an interface to create value recorders for recording metrics.
- RequestSpan
- Represents a span of time an event occurs over.
- RequestTracer
- Represents a tracer capable of creating trace spans.
- ViewRow
- Object for accessing a row returned as a part of the results from a viery query.
- BaseException
- Base exception for exceptions that are thrown originating from Couchbase operations.
- RequestCanceledException
- Base exception for exceptions that are thrown originating from Couchbase operations.
- RateLimitedException
- Base exception for exceptions that are thrown originating from Couchbase operations.
- QuotaLimitedException
- Base exception for exceptions that are thrown originating from Couchbase operations.
- HttpException
- Thrown for exceptions that originate from underlying Http operations.
- ParsingFailureException
- Thrown for exceptions that originate from underlying Http operations.
- IndexNotFoundException
- Thrown for exceptions that originate from underlying Http operations.
- PlanningFailureException
- Thrown for exceptions that originate from underlying Http operations.
- IndexFailureException
- Thrown for exceptions that originate from underlying Http operations.
- KeyspaceNotFoundException
- Thrown for exceptions that originate from underlying Http operations.
- QueryException
- Thrown for exceptions that originate from query operations.
- QueryErrorException
- Thrown for exceptions that originate from query operations.
- DmlFailureException
- Thrown for exceptions that originate from query operations.
- PreparedStatementException
- Thrown for exceptions that originate from query operations.
- QueryServiceException
- Thrown for exceptions that originate from query operations.
- SearchException
- Thrown for exceptions that originate from search operations.
- AnalyticsException
- Thrown for exceptions that originate from analytics operations.
- ViewException
- Thrown for exceptions that originate from view operations.
- PartialViewException
- Thrown for exceptions that originate from underlying Http operations.
- BindingsException
- Base exception for exceptions that are thrown originating from Couchbase operations.
- InvalidStateException
- Base exception for exceptions that are thrown originating from Couchbase operations.
- KeyValueException
- Base for exceptions that originate from key value operations
- DocumentNotFoundException
- Occurs when the requested document could not be found.
- KeyExistsException
- Occurs when an attempt is made to insert a document but a document with that key already exists.
- ValueTooBigException
- Occurs when a document has gone over the maximum size allowed by the server.
- KeyLockedException
- Occurs when a mutation operation is attempted against a document that is locked.
- TempFailException
- Occurs when an operation has failed for a reason that is temporary.
- PathNotFoundException
- Occurs when a sub-document operation targets a path which does not exist in the specified document.
- PathExistsException
- Occurs when a sub-document operation expects a path not to exists, but the path was found in the document.
- InvalidRangeException
- Occurs when a sub-document counter operation is performed and the specified delta is not valid.
- KeyDeletedException
- Occurs when a multi-operation sub-document operation is performed on a soft-deleted document.
- CasMismatchException
- Occurs when an operation has been performed with a cas value that does not the value on the server.
- InvalidConfigurationException
- Occurs when an invalid configuration has been specified for an operation.
- ServiceMissingException
- Occurs when the requested service is not available.
- NetworkException
- Occurs when various generic network errors occur.
- TimeoutException
- Occurs when an operation does not receive a response in a timely manner.
- BucketMissingException
- Occurs when the specified bucket does not exist.
- ScopeMissingException
- Occurs when the specified scope does not exist.
- CollectionMissingException
- Occurs when the specified collection does not exist.
- AuthenticationException
- Occurs when authentication has failed.
- BadInputException
- Occurs when an operation is attempted with bad input.
- DurabilityException
- Occurs when the specified durability could not be met for a mutation operation.
- SubdocumentException
- Occurs when a subdocument operation could not be completed.
- QueryIndex
- CreateQueryIndexOptions
- CreateQueryPrimaryIndexOptions
- DropQueryIndexOptions
- DropQueryPrimaryIndexOptions
- WatchQueryIndexesOptions
- QueryIndexManager
- CreateAnalyticsDataverseOptions
- DropAnalyticsDataverseOptions
- CreateAnalyticsDatasetOptions
- DropAnalyticsDatasetOptions
- CreateAnalyticsIndexOptions
- DropAnalyticsIndexOptions
- ConnectAnalyticsLinkOptions
- DisconnectAnalyticsLinkOptions
- CreateAnalyticsLinkOptions
- ReplaceAnalyticsLinkOptions
- DropAnalyticsLinkOptions
- GetAnalyticsLinksOptions
- EncryptionSettings
- CouchbaseRemoteAnalyticsLink
- AzureBlobExternalAnalyticsLink
- S3ExternalAnalyticsLink
- AnalyticsIndexManager
- SearchIndex
- SearchIndexManager
- Cluster
- Cluster is an object containing functionality for performing cluster level operations against a cluster and for access to buckets.
- BucketSettings
- BucketManager
- Role
- RoleAndDescription
- Origin
- RoleAndOrigin
- User
- Group
- UserAndMetadata
- GetAllUsersOptions
- GetUserOptions
- DropUserOptions
- UpsertUserOptions
- UserManager
- BinaryCollection
- BinaryCollection is an object containing functionality for performing KeyValue operations against the server with binary documents.
- Collection
- Collection is an object containing functionality for performing KeyValue operations against the server.
- Scope
- Scope is an object for providing access to collections.
- ScopeSpec
- CollectionSpec
- CollectionManager
- Bucket
- Bucket is an object containing functionality for performing bucket level operations against a cluster and for access to scopes and collections.
- View
- DesignDocument
- ViewIndexManager
- MutationState
- MutationState is an object which holds and aggregates mutation tokens across operations.
- AnalyticsOptions
- LookupGetSpec
- Indicates a path for a value to be retrieved from a document.
- LookupCountSpec
- Indicates to retrieve the count of array items or dictionary keys within a path in a document.
- LookupExistsSpec
- Indicates to check if a path exists in a document.
- LookupGetFullSpec
- Indicates to retreive a whole document.
- MutateInsertSpec
- Indicates to insert a value at a path in a document.
- MutateUpsertSpec
- Indicates to replace a value at a path if it doesn't exist, otherwise create the path, in a document.
- MutateReplaceSpec
- Indicates to replace a value at a path if it doesn't exist in a document.
- MutateRemoveSpec
- Indicates to remove a value at a path in a document.
- MutateArrayAppendSpec
- Indicates to append a value to an array at a path in a document.
- MutateArrayPrependSpec
- Indicates to prepend a value to an array at a path in a document.
- MutateArrayInsertSpec
- Indicates to insert a value into an array at a path in a document.
- MutateArrayAddUniqueSpec
- Indicates to add a value into an array at a path in a document so long as that value does not already exist in the array.
- MutateCounterSpec
- Indicates to increment or decrement a counter value at a path in a document.
- SearchOptions
- BooleanFieldSearchQuery
- A FTS query that queries fields explicitly indexed as boolean.
- BooleanSearchQuery
- A compound FTS query that allows various combinations of sub-queries.
- ConjunctionSearchQuery
- A compound FTS query that performs a logical AND between all its sub-queries (conjunction).
- DateRangeSearchQuery
- A FTS query that matches documents on a range of values. At least one bound is required, and the inclusiveness of each bound can be configured.
- DisjunctionSearchQuery
- A compound FTS query that performs a logical OR between all its sub-queries (disjunction). It requires that a minimum of the queries match. The minimum is configurable (default 1).
- DocIdSearchQuery
- A FTS query that matches on Couchbase document IDs. Useful to restrict the search space to a list of keys (by using this in a compound query).
- GeoBoundingBoxSearchQuery
- A FTS query which allows to match geo bounding boxes.
- GeoDistanceSearchQuery
- A FTS query that finds all matches from a given location (point) within the given distance.
- Coordinate
- GeoPolygonQuery
- A FTS query that finds all matches within the given polygon area.
- MatchAllSearchQuery
- A FTS query that matches all indexed documents (usually for debugging purposes).
- MatchNoneSearchQuery
- A FTS query that matches 0 document (usually for debugging purposes).
- MatchPhraseSearchQuery
- A FTS query that matches several given terms (a "phrase"), applying further processing like analyzers to them.
- MatchSearchQuery
- A FTS query that matches a given term, applying further processing to it like analyzers, stemming and even #fuzziness(int).
- NumericRangeSearchQuery
- A FTS query that matches documents on a range of values. At least one bound is required, and the inclusiveness of each bound can be configured.
- PhraseSearchQuery
- A FTS query that matches several terms (a "phrase") as is. The order of the terms mater and no further processing is applied to them, so they must appear in the index exactly as provided. Usually for debugging purposes, prefer MatchPhraseQuery.
- PrefixSearchQuery
- A FTS query that allows for simple matching on a given prefix.
- QueryStringSearchQuery
- A FTS query that performs a search according to the "string query" syntax.
- RegexpSearchQuery
- A FTS query that allows for simple matching of regular expressions.
- TermSearchQuery
- A facet that gives the number of occurrences of the most recurring terms in all hits.
- TermRangeSearchQuery
- A FTS query that matches documents on a range of values. At least one bound is required, and the inclusiveness of each bound can be configured.
- WildcardSearchQuery
- A FTS query that allows for simple matching using wildcard characters (* and ?).
- TermSearchFacet
- A facet that gives the number of occurrences of the most recurring terms in all hits.
- NumericRangeSearchFacet
- A facet that categorizes hits into numerical ranges (or buckets) provided by the user.
- DateRangeSearchFacet
- A facet that categorizes hits inside date ranges (or buckets) provided by the user.
- SearchSortField
- Sort by a field in the hits.
- SearchSortGeoDistance
- Sort by a location and unit in the hits.
- SearchSortId
- Sort by the document identifier.
- SearchSortScore
- Sort by the hit score.
- GetOptions
- GetAndTouchOptions
- GetAndLockOptions
- GetAllReplicasOptions
- GetAnyReplicaOptions
- ExistsOptions
- UnlockOptions
- InsertOptions
- UpsertOptions
- ReplaceOptions
- AppendOptions
- PrependOptions
- TouchOptions
- IncrementOptions
- DecrementOptions
- RemoveOptions
- LookupInOptions
- MutateInOptions
- ViewOptions
- QueryOptions
- ClusterOptions
- NoopMeter
- Implements a no-op meter which performs no metrics instrumentation. Note that to reduce the performance impact of using this meter, this class is not actually used by the SDK, and simply acts as a placeholder which triggers a native implementation to be used instead.
- LoggingMeter
- Implements a default meter which logs metrics on a regular basis. Note that to reduce the performance impact of using this meter, this class is not actually used by the SDK, and simply acts as a placeholder which triggers a native implementation to be used instead.
- ThresholdLoggingTracer
- This implements a basic default tracer which keeps track of operations which falls outside a specified threshold. Note that to reduce the performance impact of using this tracer, this class is not actually used by the SDK, and simply acts as a placeholder which triggers a native implementation to be used instead.
- NoopTracer
- Implements a no-op tracer which performs no work. Note that to reduce the performance impact of using this tracer, this class is not actually used by the SDK, and simply acts as a placeholder which triggers a native implementation to be used instead.