Repository navigation
Update dependency com.cinchapi:concourse-driver-java to v1 - #100
Open
cinchapi-agent[bot] wants to merge 1 commit into
Open
cinchapi-agent[bot] wants to merge 1 commit into
cinchapi-agent[bot] wants to merge 1 commit into
Conversation
cinchapi-agent
Bot
force-pushed
the
feature/deps-major-concourse
branch
from
November 15, 2026 22:27
0960171 to
e0f5c86
Compare
cinchapi-agent
Bot
force-pushed
the
feature/deps-major-concourse
branch
from
November 23, 2026 15:28
e0f5c86 to
870f068
Compare
cinchapi-agent
Bot
force-pushed
the
feature/deps-major-concourse
branch
from
November 25, 2026 21:27
870f068 to
2b9f855
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Note
This PR body was truncated due to platform limits.
This PR contains the following updates:
0.12.5→1.1.2Release Notes
cinchapi/concourse (com.cinchapi:concourse-driver-java)
v1.1.2(cinchapi/lib-config#8)
that caused Concourse to shorten a configuration value that contained
!whenit wrote the value to a YAML file. The value lost each
!and the text afterit, up to the next space or the end of the value. For example,
concourse config write -k init_root_password -v 'ab!cd'storedabas theinitial root password. The setters of
ConcourseClientConfigurationandConcourseServerConfigurationin the Java driver, such assetPassword,shortened a value in the same way. Now
concourse config writeand thesetters write each value exactly as given.
awaitFindAndSet,awaitSelectAndSet, orawaitGetAndSet) to keep running long past itstimeout while other writes to a record that it matched kept its own write from
committing. Such an await returns an empty result by its timeout and writes
nothing.
such as a
selectAndSetor aselectwith a condition, to try again at onceeach time a concurrent write kept it from committing. When many clients
competed for the same records, each of those operations kept a CPU core busy,
which slowed every other read and write on the server. Such an operation waits
before it tries again. While another write holds data that it needs, it waits
for that write to finish, without using the CPU. Otherwise, it waits a short
time.
v1.1.1Fixed a bug that caused CCL with a
skipclause and nolimitclause (e.g.,find age > 30 skip 5) to fail with aNullPointerExceptionwhen parsed. Thefailure happened in
Command.parse, inexecandsubmitwith a CCL string,in CaSH, and in Concourse Server when a client sent the CCL. It also happened
when parsing the CCL that
ccl()returns for aCommandpaged withPage.skiporPage.offset, because that CCL has askipclause and nolimitclause. Now, such CCL parses to aCommandthat skips the specifiednumber of results and returns all remaining results.
ConcourseCommandDriveris an abstractConcourseimplementation thatconverts each method call that has a
Commandequivalent into thatCommandand passes it to
submit(List<Command>), which a subclass implements. So aprogram can provide the full
ConcourseAPI over its own transport (e.g.,relaying each
Commandto another process that holds a Concourse Serverconnection) without implementing each
Concoursemethod. For a given list ofcommands, the subclass's
submitmust return the same results, in the sameorder, that
submitreturns on a connection fromConcourse.connect(). EachConcoursemethod that corresponds to a singleCommand(e.g.,find,add,stage,commit, a calculation, or an await) callssubmitexactlyonce. The subclass also implements
exit,getServerEnvironment,getServerVersion,invokePlugin, andcopyConnection, which have noCommandequivalent.manage()throws anUnsupportedOperationException.The
describe,browse,holds,trace,clear, andrevertcommandbuilders accept a
Collectionof records or keys as an argument. So do thesteps of the
add,set,remove, andinsertcommand builders that takerecords (e.g.,
in(records)). This lets code that holds aCollectionpassit directly instead of splitting it into a first item and the rest.
Command.to().clearAll().from(records)builds aCommandthat clears everykey in each record of
records. ACommandbuilt with aCollectionargument returns the same shape as the
Concoursemethod that takes aCollection, even if theCollectioncontains a single item. For example,Command.to().describe(records)returns aMap<Long, Set<String>>, asdescribe(records)does.Fixed a bug that caused some
Commandinputs containing single-itemcollections as arguments (e.g., the CCL
describe [1]) to return the sameshape as if the
Commandwas provided the single item directly instead ofwithin a collection. So
describe [1]returned aSet<String>of the keys inrecord 1, as
describe 1does, instead of aMap<Long, Set<String>>fromrecord 1 to its keys. This affected three kinds of input:
add,remove,insert,describe,holds, ortracecommand, whenCommand.parse,exec,submit, CaSH, or Concourse Server parsed it.ccl()returned for aselect,get,navigate,link,await, or read-and-set
Commandbuilt with a single-item collection. ThatCCL omitted the brackets (e.g.,
ccl()returnedselect name from 1forCommand.to().select("name").from(Collections.singletonList(1L))), sorunning it returned the single-item shape.
equalsalso returnedtruefor that
Commandand theCommandbuilt with the single item directly.TCommandwith a single-item collection of records or keys, whichCommandSerializer.fromThriftconverted into aCommandfor the singleitem.
Now, these inputs return the same shape as the
Concoursemethod that takes acollection, and
ccl()keeps the brackets (e.g.,select name from [1]). Theexception is CCL with a single-item collection of keys in a
select,get,navigate,browse, await, or read-and-set command, or of destinations in alinkcommand. That CCL still returns the single-item shape (e.g.,select [name] from 1returns the sameSetasselect name from 1). Codethat expects the single-item shape must provide the single item directly
(e.g.,
describe 1).Fixed a bug (GH-1575)
that caused a
CommandGroupmethod with a collection argument (e.g.,group.describe(records)) to record a separateCommandfor each item in thecollection. So
submit(group)returned one result per item instead of oneresult per method call. For example, if
recordscontained three records,submit(group)returned threeSet<String>results instead of oneMap<Long, Set<String>>. This affected theadd,set,remove,insert,clear,revert,browse,describe,holds, andtracemethods. Now,each method call records one
Command, andsubmit(group)returns one resultfor that call, with the same shape that the
Concoursemethod with the samearguments returns. Code that reads the results of
submit(group)by positionmust count one result per method call.
Fixed a bug (GH-1582)
that allowed a command builder to accept an empty collection of records or
keys and build a
Commandthat ran as if the argument were omitted, so itread or wrote more data than requested. For example,
Command.to().select(Collections.emptyList()).from(1)returned the values ofevery key in record 1, and
Command.to().calculate("sum", "age").in(Collections.emptyList())summedageacross every record. ACommandGroupmethod with an empty collectionargument recorded no
Command, sosubmit(group)returned no result for thatcall. Now, every command builder and
CommandGroupmethod with a collectionargument throws an
IllegalArgumentExceptionif the collection is empty. Codethat may pass an empty collection must check for it before the call.
Fixed a bug (GH-754) that
caused a
findCommandwith a timestamp (e.g.,Command.to().find(criteria).at(timestamp)) to fail with anInvalidArgumentExceptionwhen a client ran it withsubmitorexec. Now,it returns the records that matched its condition at the timestamp, and it
fails with a
ParseExceptionif its condition is not valid CCL.Fixed a bug (GH-1573)
that caused a
jsonifyCommandwith a timestamp (e.g.,Command.to().jsonify(records).at(timestamp)) to fail with anInvalidArgumentExceptionwhen a client ran it withsubmitorexec. Now,it returns the JSON of the records as of the timestamp.
Fixed a bug that caused
calculate(String, Object...)(e.g.,calculate("sum", "age")) to throw anIllegalArgumentExceptionon aninstance of a
Concoursesubclass that overridescalculate(), even thoughcalculate().sum("age")worked on the same instance. Now,calculate(String, Object...)invokes the named method on theCalculatorthat
calculate()returns.v1.1.0Read and Set Operations
Concourse now provides new atomic operations to look up the records that match a
condition and
seta key as a value in each of them.findAndSetreturns the records that were updated.selectAndSetreturns all the values that each updated record held for one ormore keys (or every key) right before the
set.getAndSetreturns the most recent value that each updated record held forone or more keys (or every key) right before the
set.Each of these operations supports sorting and pagination. When an
Orderisgiven, the matching records are sorted before a
Pagepicks which of them toupdate, and the results come back in that order. Without a
Page, everymatching record is updated. Both
selectAndSetandgetAndSetinclude everyupdated record in their results, even one that doesn't have any of the requested
keys.
selectAndSetandgetAndSetcan also read a single key, just likeselectand
get. Then the result maps each record straight to that key's values. Theone exception to the rule above is a
getAndSetof a single key, which leavesout a record that doesn't have the key, just like
getdoes.An invalid key, or a blank or function value, causes the operation to fail even
when no records match. The operation also fails if the value is a link from one
of the updated records to itself.
For example, this sets the
statusof the highest-priority pending job toclaimedand returns the job'spayload:The same operation can also be written as a CCL command or built as a
Command:Awaits
Concourse now provides await operations that wait for a read to return data.
Previously, a client that needed to wait for data, such as a worker waiting for
a new job, had to poll by repeating a read until something came back. An await
does the waiting on the server and returns as soon as there's a result.
There's an await version of
find,select, andgetwith a condition(
awaitFind,awaitSelect, andawaitGet), and of each new read and setoperation (
awaitFindAndSet,awaitSelectAndSet, andawaitGetAndSet). Anawait takes a timeout, followed by the same arguments as the operation it waits
on. If the result is already non-empty, the await returns it right away.
Otherwise, it waits until a write makes the result non-empty or the timeout
passes. At the timeout, it returns whatever the result is at that time, which
may be empty. The await versions of the read and set operations wait for a
non-empty result and then do the lookup and the
setatomically.InvalidArgumentExceptionif:navigation key,
max_await_timeoutsetting (60 seconds by default).max_open_awaitsawaits (1,000 by default) to beopen at once. Beyond that, a new await fails with an
AwaitLimitExceptionandcan be retried later. Both limits can be changed in
concourse.yaml:on any node.
waiting, the server may still do the
setwithout anyone getting the result.So it's best to
seta value that can recover on its own, such as a leasethat expires.
com.cinchapi.concourse:type=AwaitsMBean reports the number of openawaits, read evaluations, timeouts, and wake latency. When
monitoring.export_metricsis enabled, these are also exported asconcourse_awaits_*metrics.withinclause suchas
within "30 seconds". Awaits can also be built withCommand.to()andrecorded in a
CommandGroup.For example, this waits up to 30 seconds for a pending job and then marks it as
claimed:The same await can also be written as a CCL command or built as a
Command:Effectively Equal Values of Different Types
Concourse treats effectively equal values of different types as being the same.
Numbers are effectively equal when they have the same value, such as
18,18Land
18.0, and a Float is effectively equal to the Double with the same decimaldigits. A Tag and a
Stringare effectively equal when their text is exactlythe same, including its case. Previously, each part of Concourse Server applied
that idea in its own way. So the same write could succeed or fail, and the same
read could return different values, depending on whether the data was indexed
yet. Now, one set of rules applies everywhere.
one another. For example, if a field holds
18, adding18.0fails, and ifit holds the
Stringjeff, adding the Tagjefffails.equal to the supplied value. The field's history records the stored value, not
the supplied one, so
searchand every other read reflect the removal.value that the field holds. For example, if a field holds
18, setting it to18.0leaves it holding18.0, inside or outside of a transaction.reconcilecounts a value that a field holds as already there if it'seffectively equal to one you pass, so it leaves that value in place with the
type it was written with. For example, if a field holds
18,reconcilewith18.0leaves it holding18. To change only the type of a value, useset.select) always returnsthe types that were written, even if they diverge across records. For example,
a field that holds
18never returns18.0. The Java driver still reads aTag back as a
String. In the same way, adiffof a record reports asetfrom
18to18.0as a change, and arevertto a time before thatsetbrings back
18.(e.g.,
browse) returns one representative value and maps it to all of thoserecords. For example, if one record holds
18and another holds18.0,browsemaps one of them to both records. Adiff,minormaxof a keyworks the same way.
=and the range operators match effectively equal values of any type, andsearch,CONTAINSandNOT_CONTAINSonly considerStringvalues. ABoolean isn't equal to text, so a query for the
String"true"doesn'tmatch the Boolean
true. Previously, it did once the data was indexed.By default, the representative value has one of the types it was written with,
but the representative type that is chosen is undefined and may change across
calls depending upon the total state of the data under that key. If you enable
the new
enable_canonical_type_coercionpreference, these reads convert eachrepresentative value to its canonical type instead, which means a whole number
becomes an
Integer(or aLongif it's too big for anInteger), any othernumber becomes a
Double, and a Tag becomes aString.These rules fix several bugs.
18.0to a field that held18was refused while18was in thebuffer, but accepted once
18was indexed, so a field could hold both.18.0from a field that held18was refused once18was indexed.While
18was still in the buffer, the remove reported success andverifyagreed, but
selectstill returned18.Stringby passing a Tag with the same text left theStringinthe search index, so
searchandCONTAINSstill matched the record. Andremoving a Tag by passing a
Stringcould hide the field's other values fromsearch. For example, after the Tag
jeffwas removed from a field that alsoheld
jeffrey, a search forjeffno longer found the record.(GH-968)
Stringand a Tag with the same text could be mixed up when both wereindexed at around the same time, even under different keys or in different
records. The
Stringcould be read back as a Tag, or the Tag as aString,and a historical
CONTAINScould return too few or too many records.(GH-827)
selectthat used a key in its condition or order could return a Tag as aString, or18.0as18. This happened whenever an effectively equal valueof the other type was written first.
(GH-827)
browse, and theminormaxof a key, failed with an internal error whenone record's value was indexed and an effectively equal value of another type
in another record wasn't indexed yet.
Stringwith thesame text left the field holding the Tag, although the same
setoutside atransaction stored the
String.Upgrading to this version checks the stored data, one field at a time, for
writes that break these rules. It only rewrites the data files that contain one,
and leaves the rest as they are. An earlier version could let a field hold
effectively equal values of different types, so the upgrade keeps the one that
was added first. To do so, it drops the add of the second value and any remove
of either value while the field still held the other. If a remove named an
effectively equal value of another type, the upgrade rewrites it to name the
value that the field held, so
searchsees the removal. If the upgrade stopspart way, it finishes the same plan the next time it runs.
concourse data repairapplies the same rules to the stored data.Search and Text Matching
Search, the
CONTAINSandNOT_CONTAINSoperators, and every comparison oftext now follow one set of rules. Previously, the same query could return
different records depending on whether the data was indexed yet, whether it was
read at a past timestamp or inside a transaction, and which locale or version of
Java ran Concourse Server.
other within a single value, consistent with the
CONTAINSoperator. Forexample, a search for
foo barpreviously matched a record whosenamevalues were
foo xandy bar. Search results are ordered by how many timesthe query matches a record, and that count now includes every matching value
in a field.
searchas soon as no record can match the query. Previously, it read the index for
every word in the query, even after an earlier word had already ruled out
every record.
findquery that uses theCONTAINSoperator at a past timestamp, or theNOT_CONTAINSoperator at any time, now answers from the search index.Previously, it matched the query against the text of every distinct value that
the key held.
This release also fixes these bugs in search and text matching:
whether the matching data existed in long-term storage or the buffer. The root
cause was a discrepancy in the tokenization logic between the stores. Search
now splits text and ignores its case the same way for both. These bugs were
fixed:
letters differently. For example, with a Turkish default locale, a search
for
titledidn't find indexed values that containedTITLE.foo bardidn't find an indexed value whose words were separated by anotherwhitespace character, such as an ideographic space.
substring. So, a search query that ended with a control character didn't
find indexed values that contained it.
Basic Multilingual Plane. For example, a search for
a?found an indexedvalue of
a😀b.max_search_substring_lengthsetting could return results, although such asearch should return no results. Concourse Server indexed substrings one
character longer than the setting, so a search for a word of that length
matched indexed data. A search also matched data that was not yet indexed, no
matter how long its words were. Each word longer than the setting also took
more index space than it needed. Now, the longest indexed substring has
exactly
max_search_substring_lengthcharacters, and a search for a longerword matches no data, whether or not it is indexed. A
CONTAINSorNOT_CONTAINScondition follows the same rule, so no value contains a querywith a word longer than the setting. This also holds for data that was indexed
while the setting was higher.
the
CONTAINSandNOT_CONTAINSoperators didn't follow the matching rulesof the other operators. So the same query could return different records on
current and historical data, or inside and outside of a transaction. Now, both
operators only consider
Stringvalues, just likesearch, and a queryreturns the same records in every case.
Stringnever matcheseither operator. Previously, a historical query or a function key could fail
with an internal error when it reached such a value.
NOT_CONTAINSmatches a record when any of itsStringvalues doesn'tcontain the query, just like
!=. Previously, on current data, it matchedevery record that had no value containing the query, including records that
didn't have the key at all.
Stringis read as text. For example,address contains 5matches a record whoseaddressis"Apt 5".search, and aCONTAINScondition on current data, couldreturn the wrong records when a record had writes that weren't indexed yet, or
writes inside a transaction. If such a write removed a matching value, the
record still matched. If it added a second matching value, the record stopped
matching.
CONTAINScondition missed a match that started partwaythrough a partial match, such as
a a bina a a b, although asearchforthe same query found it.
findquery that used theNOT_CONTAINSoperatorreturned the opposite of the correct records for any data that was not yet
indexed into long-term storage. A recently written record whose value
contained the query string was returned, and one whose value did not contain
it was left out. Data that was already indexed matched correctly, so the same
query could return different records before and after indexing, and a query
whose data was split across both returned a mix of the two.
NOT_CONTAINSnowmatches only the records whose values do not contain the query string,
wherever the data resides.
Server took its case rules from the version of Java that ran it and, for some
operators, from the server's default locale. Now, the rules are based on the
Unicode Standard and ship with Concourse, so
EQUALS,NOT_EQUALS, the rangeoperators and
searchagree under every locale and version of Java.İSTANBULmatched bothcity = istanbulandcity != istanbul. On a server whose default locale was Turkish, the samewas true of any text with a capital I, such as
INFO.only in case. For example,
city > istanbulmatchedİSTANBUL, andunit >= μmissed the micro signµ.word = 𐐀missed a record that held𐐨, because comparisons didn'tignore the case of letters outside the Basic Multilingual Plane.
text in a script whose case rules changed.
Storage Format Update
Concourse Server stores data on disk in Storage Format v3, and this version
moves that format to schema iteration 2. Schema iteration 2 makes the following
changes:
value, so a search can distinguish between multiple values stored in a field.
record and key are stored together, so the record and key are written once for
the whole group instead of once for every revision. Additionally, each
revision's timestamp is stored as the difference from the one before it, so it
takes fewer bytes.
targeting a false positive probability of 0.001%, down from 3%. Previously,
bloom filters were sized from heuristic estimates, which left them either
oversaturated or needlessly sparse. Each filter also holds only the entries
that reads look up in it, so the index filter grows with the number of keys
and the search index filter grows with the number of distinct terms, instead
of with every write.
drastically reduced, so it takes a small fraction of the space it previously
occupied, both in memory and on disk. Previously, this metadata could take up
more space than the data itself and could be evicted under GC pressure, so
later reads had to load it from disk again. Now, the metadata is small enough
to load eagerly and keep in memory. Because it's never evicted, the memory it
uses grows with the amount of data you store. A read may now scan up to about
4 KB of data that it doesn't need, but that costs far less than reloading
evicted metadata from disk.
detect data that was damaged on disk.
Together, these changes reduce the disk space that the same data takes up by
roughly 40 to 60 percent. Most of that space is the search index, so the
savings grow with how often the same words appear across records. Reads are as
fast as before or faster, and the memory that reads use drops by more than
80%, because the metadata that was previously loaded, evicted, and loaded
again is now small enough to stay in memory.
Durability and Crash Safety
Every write that Concourse Server acknowledges now survives a crash, and the
server detects data that was damaged on disk instead of returning a wrong
result.
demand, run
concourse data verify. It lists each damaged file while readsand writes continue. To also check data as it's read, set
verify_data_integrity_on_readtotrue. Each read then checks every groupof revisions that it loads from disk, and a read of damaged data fails
instead of returning a wrong result, while the server log names the damaged
file. The setting is
falseby default because it adds work to each readfrom disk, and it can be changed without rewriting any data files:
damage to essential metadata. When it finds damaged files, the server
refuses to start the environment and reports each affected file, so you can
restore those files from a backup. For the default environment, that means
Concourse Server refuses to start. Previously, Concourse Server skipped any
data file that the storage engine couldn't read, which left that file's data
out of every result.
of a write can no longer leave the data in an inconsistent state
(GH-901). Previously,
Concourse Server wrote each new data file under its final name from the start.
So a crash, such as a power loss, while a data file was being written could
leave a partly written file behind, and the next start could read it as if it
were complete, which meant that some of the data in that file could go
missing. Now, a data file takes its final name only after every byte of it is
on disk and Concourse Server is ready to use it, so a crash at any point
leaves either the whole file or none of it. The data that was being written is
still in the Buffer or in the data files it was built from, and the next start
reads it from there.
Previously, a transaction that changed data stored a backup of its writes,
synced it to disk before it applied them, and then deleted it. Now, a
transaction's writes reach the disk together, so a crash leaves all of them or
none of them, and every acknowledged commit is durable without a backup. The
new
transactions.recover_interrupted_commitssetting brings the backup back,so that more interrupted commits can be recovered when Concourse Server
restarts. It has significant overhead and is generally not recommended. With
it on, recovery replays a backup only when all of it is intact, so a
transaction is either applied completely or not at all
(GH-801). That includes a
backup that a crash cut off right between two of its writes, which 1.0.5 can't
tell apart from a complete one. A backup that an earlier version left behind
is still recovered.
This release also fixes these bugs in crash safety:
abrupt machine failure could erase data that a client had already seen. Now, a
write becomes visible only after it reaches disk.
read at a timestamp or a full-text search could see them in between, because
neither waits on the locks that a commit holds. This applied to an explicit
transaction and to any operation that Concourse Server performs atomically,
such as
set,clear,insert, andreconcile.reached disk. For example, an
addwithout a record could refuse to writeto a record that did not survive the failure.
accepted, and events could arrive in a different order than the writes. Now,
events reach a plugin only after the write is durable, in the order the
writes were made.
a crash while Concourse Server was storing a write could prevent the server
from starting, or could cause a corrupted write to be stored permanently.
Additionally, if a crash interrupted an atomic operation that wrote multiple
values, the server could restart with only some of those writes. Now,
Concourse Server restarts with every write that it acknowledged and drops the
incomplete group of writes that it was storing when it crashed, so every
atomic operation remains all or nothing. If Concourse Server finds a Buffer
page that is damaged in a way a crash can't cause, it refuses to start and
names the damaged page. That includes a page whose header and writes disagree
on which page it is. A damaged page header is restored from the page's intact
writes.
backup, atomically replaced a storage file, or stored the first writes on a new
Buffer page could make the file system forget the new file or undo the
replacement. Now, Concourse Server also syncs the directory that holds such a
file before any write in it is acknowledged, so the change survives a crash.
On platforms that can't sync a directory, this protection is best effort.
Buffer to disk failed. The disk may report a later flush as complete without
the data of the failed one, so writes that clients had already read could
disappear after a restart. Now, Concourse Server refuses every write after a
failed flush until it restarts. Reads continue, and the restart loads whatever
the disk holds.
Concourse Server's inventory of records could lose information if a single run
of the server wrote more than 98,304 new records. The inventory file overwrote
part of itself, so after the next restart, operations that consult the
inventory, such as
inventoryand afindwith a negated condition, leftthose records out even though their data was intact. The upgrade rebuilds the
inventory of every environment from its stored data, so the missing records
come back. Now, the inventory file carries checksums, and Concourse Server
rebuilds it from stored data whenever it is lost or damaged.
stopping Concourse Server didn't wait for the background indexing of recent
writes to end. The indexing could keep changing the Buffer and the data files
after the server reported that it had stopped, and the process could exit in
the middle of that work, as if it had crashed. Now, a stop returns only after
all indexing has ended. Indexing that is already moving a batch of writes into
long-term storage finishes, and any other indexing stops and removes the files
it wrote.
Configurable Trash Handling
Concourse Server no longer deletes a data file as soon as it retires it.
Previously, Concourse Server deleted the original of each data file that a
repair or a reindex replaced, and only a start moved a data file to the trash,
when another data file held all of its data. Now, whenever Concourse Server
retires a data file, it moves the file to the trash, so the data isn't lost if
that decision turns out to be wrong.
A data file stays in the trash for one week, and then Concourse Server deletes
it. The new
concourse data prunecommand empties the trash of an environmentat any time, and the new
storage.trash.retentionpreference sets the number ofhours that a data file stays in the trash. A negative value keeps each data file
until
concourse data prunedeletes it. A value of0deletes each data fileright away instead, and it also empties the trash when Concourse Server starts.
Upgrading to 1.1.0
Upgrading to this version requires Concourse Server 0.11.0 or later. To upgrade
from an earlier version, first upgrade to a 0.11, 0.12 or 1.0 release, and then
upgrade to this version. Data from before 0.10.6 must be upgraded with 0.10.6
before that.
The upgrade rewrites every data file in schema iteration 2, so it's important to
allocate downtime for the upgrade to finish. Unless
storage.trash.retentionis0, the upgrade keeps a copy of each original in the trash, so it needs as muchfree disk space as the data files already take up. The upgrade checks for that
space before it rewrites anything, and it stops if the disk doesn't have room.
Along with the new storage format, the upgrade:
as described above,
keeps the previous inventory file as
inventory.bakbeside it,trash.
An upgrade that moves data to a new storage format now continues where it
stopped if it does not finish. Previously, if the upgrade failed or Concourse
Server stopped before it finished, the next start began the upgrade again from
the first data file. On a large database, an upgrade that took longer than a
startup limit, such as a Kubernetes startup probe, could never finish.
The upgrade now rewrites each data file on its own, and each data file holds
either its original data or its rewritten data, even if Concourse Server stops
part way. The next start continues with the data files that still need the
upgrade. The log reports each data file that the upgrade rewrites, such as
(23 of 56 in default). The first number counts the data files of theenvironment that the upgrade has finished, and the second counts the ones that
needed the upgrade when it started, so you can see how far the upgrade has
progressed.
The upgrade is also faster on a large database, because it rewrites several
data files at once. It starts with half as many at once as the server has
processor cores, and at least two. Whenever the heap is nearly full, it rewrites
fewer at once, so that the extra speed does not run the server out of memory.
Compaction
Compaction is now on by default, and it merges data files by size tier. Each
transport from the Buffer writes one data file, and every uncached read,
find, andsearchexamines every file. Without compaction, an environmentthat received millions of writes held tens of thousands of files and point
reads took tens of milliseconds. Compaction merges files that hold a comparable
amount of data into one larger file, which then joins the next tier. Because of
this, the number of files an environment holds grows with the logarithm of the
data it stores rather than with the number of writes, and such an environment
stays at a few dozen files.
A compaction pass offers the largest group of files first, so the first merges
happen as soon as enough files accumulate. A run of files at the end of an
environment waits until enough of them accumulate, so a newly written file does
not cause the files before it to be rewritten. Every revision is preserved,
because a merge changes how the data is arranged, never what it contains.
Compaction is safe to leave on:
for the moment it swaps the merged file in. The files it replaces go to the
trash as soon as the merged file is live.
restart. A merged file becomes visible only once it is complete, and a
restart keeps the merged file and moves the files it replaced to the trash.
when the Java heap fills up, whatever the
storage.spill.heap_usage_thresholdsetting is, so the heap never has to hold the whole result. A merge whose
result would be larger than
compaction.max_file_size(1 GB by default) orthan a quarter of the heap, or that would leave less than
compaction.disk_headroom(1 GB by default) of disk space available, is notperformed.
abandoned and reported in the compaction metrics, and compaction continues
with the next group of files.
no data file changes after the stop.
compaction.max_backlogBuffer pages (4 by default) wait for transport,scheduled merges pause until the transporter catches up, so compaction never
competes with a backlog of writes. A full compaction, including one started by
concourse data compact, runs regardless.The files that a merge replaces go to the trash, so compaction frees disk space
only once they leave it, after one week by default or when
concourse data pruneruns. Until then, an environment that compacts uses more disk space thanone that does not.
The
compactionsettings inconcourse.yamlcontrol the fan in, the largestfile a merge may produce, the disk space a merge must leave free, the backlog at
which scheduled compaction pauses, and how often compaction runs.
compaction.enableturns compaction on or off, and it overridesenable_compactionwhen both are set.concourse monitor compactionand theEngineStatsJMX bean report the mergesperformed and failed, the files retired, the bytes read and written, the average
and longest shift time, the last failure and its time, and the number of files
in each tier.
This release also fixes these bugs in compaction:
GH-1002,
GH-1049) where compaction
left the data files it merged in place, so every restart loaded the stale
files and logged a
duplicate datawarning for each one.where
concourse data compactran a single compaction shift, which usuallymerged nothing, and said nothing when the
enable_compactionsetting wasfalse. The command now runs a full compaction, so every eligible mergehappens before it returns, and it fails with a message that names the setting
when compaction is disabled.
GH-878) where compaction
never reduced the number of data files, even when the
enable_compactionsetting was
true. Three separate faults kept it from finishing any usefulwork. The built-in strategy merged two files only when their contents were
estimated to overlap heavily, which almost never happens on a real workload. A
full compaction, which runs on a weekly schedule, returned after the first
merge it attempted, however many groups of files were eligible. And a
compaction pass offered the strategy every group size, from a single file up
to every file in the environment, even though that strategy only ever merged
pairs; because each attempt takes one turn of a slow background schedule,
nearly every turn was spent on a group the strategy could not use, and a
single pass over an environment holding tens of thousands of files could take
years.
a merge failed, and reported nothing when it did. A merge can fail for an
ordinary reason, such as an administrative repair replacing one of the files
it was reading. The failure escaped the scheduled compaction task, which
caused the scheduler to cancel every later run of that task, so both the
frequent incremental schedule and the weekly full schedule went silent until
the server was restarted. The failure also left the pass pointed at the same
group of files, so a compaction started by hand, including through
concourse data compact, attempted the same failing merge again.every read and write in an environment stopped while compaction merged data
files, even though the
enable_compactiondocumentation promised thatcompaction would not disrupt them. A merge rewrites all of the data in the
files it combines and held the lock that guards the environment's data files
for that entire time, so one merge could stall the environment for seconds and
a full compaction could stall it for the length of every merge it performed.
the reconciliation of the Buffer and the data files at startup changed the
list of data files without the lock that guards it, so a compaction that ran
at the same time could leave a data file unreachable until the next restart.
The reconciliation also left the file it discarded on disk, so every restart
loaded and discarded it again. The reconciliation now holds the lock and moves
the file to the trash.
it deleted. The handle was released only when the server stopped, so the disk
space the file occupied was not reclaimed until then, and a server that
deleted many files could approach the operating system's limit on open files.
Deleting a data file now closes every handle the server holds for it, so the
space is reclaimed immediately.
Memory Use
Fixed a bug (GH-1132)
where the memory that Concourse Server used for caching could grow well beyond
the heap. Each cache in each environment was allowed to use up to half of the
heap on its own, and so was the search cache for each searched key when
enable_search_cachewas on. So the caches could claim several times theheap, and the server depended on the JVM to reclaim cached data, which it only
does after long garbage collection pauses when the heap is nearly full. Each
cache also measured cached data by the size of that data on disk, which is a
small fraction of the memory it takes in the heap. Now, every cache in every
environment shares one memory budget, which is 60% of the heap by default. The
budget counts the memory that cached data takes in the heap. When the budget
is full, Concourse Server keeps the cached data that it expects to read again,
based on how often and how recently it read that data. So a scan of many
records no longer pushes out the data that is read often.
The new
storage.cache.heap_sharepreference sets the budget as a share ofthe heap, between
0and1. It defaults to0.6, and0turns cachingoff.
Concourse Server now bounds the memory that its cache of precomputed lookup
keys uses. Previously, the cache grew without limit and retained a copy of
every distinct record, key and value that was ever written or looked up, so a
long-running server or a large import held several gigabytes that were never
released. The cache now holds a fixed number of entries and discards the ones
it has not used recently.
The record inventory has been optimized to use a consistent amount of memory
per record, no matter how record ids are distributed. Concourse typically
assigns each record id from the current timestamp and, previously, an id
assigned more than about a second after the one before it took close to 1 KB
of heap. So an application that created a million records one at a time over a
month held about 1 GB of heap for the inventory alone. Now, each of those ids
takes about 16 bytes, and ids assigned in a burst take less.
Concourse Server now writes a data file faster when there isn't room in memory
to buffer it. Previously, it spilled the file's indexed data to temporary
files and read it back to write the file. Now, it writes the file directly
from the indexed data in memory.
Concourse Shell (CaSH)
at the prompt and in a run-commands file. CaSH includes the core language and
the
datetime,json,nio,sql,templatesandxmlmodules. A scriptthat uses a class that Groovy moved to a new package in version 3 or 4, such
as
groovy.util.XmlSlurper, which is nowgroovy.xml.XmlSlurper, must importit from its new package.
concourse importalso compiles a custom importerwritten in a
.groovyfile with Groovy 4, so the same package note appliesto it.
history file,
~/.cash_history, readable and writable by its owner only.Concourse Shell also never saves an input that calls
createUserorConcourse.connector mentions a password, and it drops any such input thatan existing history file holds.
starts with your input, in faint text after the cursor. Press the right arrow
key or
Ctrl+Eto accept the suggestion, orAlt+Fto accept its next word.selectacross records is a table, any other map is a list of key and value pairs,
and a
findis a comma-separated list. Links show as@<record>, timestampsshow to the microsecond, and long values wrap instead of being cut off. A
table too wide for the terminal even with its columns shrunk opens in the
pager at its full width, where the left and right arrow keys scroll sideways.
Type
:wide blocksto show each record as a block of key and value linesinstead, and
:wide scrollto return to the pager. A faint footer counts therows and shows the elapsed time, and a blank line separates the output of each
input from the next prompt.
--runand piped scripts still printReturned '...' in 0.011 sec.diff, values that wereadded are green and values that were removed are red, and in the result of an
audit, each revision that adds a value is green and each revision thatremoves one is red.
:at <time>in CaSH to look around your data as it was at that time,such as
:at "last friday". Until you type:at now, eachselect,get,find,browse,describe,navigate,verify,calculate,jsonifyandtracethat doesn't name its own time reads as of that moment, including itswherecondition, and the prompt shows the time, as in[default/cash@2026-10-17 09:00:00]$. The time can also be microseconds or atimestamp as CaSH shows it, such as one that you copy from an
audit, whichlands on that exact revision. Writes and Groovy input run as written, so after
each Groovy input, CaSH prints a note that it read the present.
values across all records. Before it lists a key's values, CaSH asks
Concourse Server how many the key holds, so pressing
TABafterwhere name =on a large key no longer makes the server send every valueand record of that key.
instead of logging in again for each lookup of keys or values, so completions
arrive sooner and a long session doesn't leave a trail of short sessions on
the server. After
:reconnect, completion connects with the new connection'ssettings.
:editin CaSH to open your previous input, even one that failed, in theeditor that
$VISUALor$EDITORnames, or in a built-in nano if neither isset. When you save and quit, CaSH puts the edited text at the prompt, so you
can review it before you press Enter to run it.
lessthat JLine provides,instead of running the
lessprogram. Paging works on Windows and incontainers that don't have
less, and pressingqbefore the end of a longresult no longer prints the whole result again.
:format jsonwrites each result as prettyprinted JSON in the form that Concourse reads, so you can paste it into an
insert;:format csvwrites comma separated values;:format textwritesthe
Returned '...' in 0.011 sectext; and:format tablereturns to thelayout that fits the terminal.
:formatalone shows the current format. Pass--formatto startconcourse shellin a format, which also applies to--runand piped scripts, as inconcourse shell --format json < report.cash. CaSH remembers the:formatand
:widechoices that you make at the prompt in~/.cash_settings, so yournext session starts with them.
the variable
_, so Groovy input can build on it, as inselect("name", _)after a
find. An input that fails or returns nothing leaves_unchanged.:txnwhile a transaction is open, as in[default/cash:txn]$, so you can see that your writes are staged until youcommitorabort.find(, thestatus line now shows the method's overload signatures, so you don't have to
press
TABto see what the method takes.:watch [seconds] <command>in CaSH to run a read every few seconds, twounless you say otherwise, and see its latest result full screen, as with
watchin a terminal. PressqorCtrl+Cto return to the prompt. CaSHrefuses to watch a CCL command that writes.
:explore <record>to see the recordfull screen, with a line for each key and its values. Move between the lines
with the arrow keys, press Enter to open the record that a line links to and
the left
Configuration
📅 Schedule: (UTC)
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate CLI.