This changelog contains a loose collection of changes in every release. I will also try and document all breaking changes to the API.
The format is based on Keep a Changelog and this project adheres to a "shifted" version of semantic versioning while the major version remains at 0: Minor version changes indicate breaking changes, patch version changes should not contain breaking changes.
Thanks to @Atsman for cleaning up and improving the frontend code in this release!
This release contains update of frontend libs and related tools such as: reagent, reframe, figwheel etc.
House-Keeping Release.
This release contains no new functionality but only cleans up the dependencies, codebase and removes deprecated interfaces.
These are breaking changes so if you are still using deprecated features or rely on some very specific behavior, take care when upgrading.
lambdacd.internal.pipeline-state/PipelineStateComponent
(deprecated since 0.11.0). Use the functions in lambdacd.state.core
access state or the protocols in lambdacd.state.protocols
to implement custom persistence functionality.lambdacd.util
(deprecated since 0.12.1)lambdacd.ui.ui-server
(deprecated since 0.13.1)lambdacd.execution
(deprecated since 0.13.0)lambdacd.steps.result
(deprecated since 0.13.1)lambdacd.steps.status
(deprecated since 0.13.1)lambdacd.steps.support
(deprecated since 0.13.1)lambdacd.core
(deprecated since 0.9.5)lambdacd.ui.ui-page
private (use was deprecated since 0.13.1)lambdacd.presentation.pipeline-structure
private (use was deprecated since 0.13.1)lambdacd.runners
private (use was deprecated since 0.13.1)lambdacd.presentation.pipeline-structure
private (use was deprecated since 0.13.1)lambdacd.steps.control-flow
private (use was deprecated since 0.13.1)lambdacd.steps.shell
private (use was deprecated since 0.13.1)lambdacd.presentation.pipeline-state
private (use was deprecated since 0.13.1)lambdacd.presentation.unified
private (were deprecated since 0.13.1)lambdacd.presentation.pipeline-state/history-for
with state instead of ctx (deprecated since 0.11.0)nil
-values in the pipeline-structure (e.g. from conditionals when creating it) led to step-information being in the wrong place for the UI (#172)org.ow2.proactive/process-tree-killer
that was only available in an insecure maven repo with com.jezhumble/javasysmon
so that LambdaCD Projects can be built with Leiningen 2.8.0 and later (fixes #171)java.lang.ClassNotFoundException: clojure.test
in lambdacd.presentation.pipeline-structure
under some circumstances (#169):status :dead
(#134)junction
did not behave like a sequential step, i.e. it did not pass the results of the condition to the arguments of the branch steps (#162)lambdacd.stepresults.merge/merge-step-results
default behavior consistent with other step-result merging strategies: should concatenate colliding listsBuilt-in Git-Support (lambdacd.steps.git
) should be considered deprecated now and will be removed in the future. Use the more modern lambdacd-git
library instead.
A couple of functions were only public by accident and should not be considered part of the public API. They will be moved or become private in the future:
lambdacd.presentation.pipeline-state/not-retriggered?
lambdacd.presentation.pipeline-structure/pad
lambdacd.presentation.pipeline-structure/step-display-representation-internal
lambdacd.runners/should-trigger-next-build?
lambdacd.steps.control-flow/synchronize-atoms
lambdacd.steps.shell/kill
lambdacd.steps.status/choose-last-or-not-success
lambdacd.steps.support/{replace-args-and-ctx,to-fn,to-fn-with-args,unify-results}
lambdacd.ui.ui-page/{css-includes,js-includes,favicon,app-placeholder,title,header,ui-config,ui-page}
lambdacd.presentation.unified/unified-presentation
is unused and therefore deprecated and will be removed in the future. Use pipeline-structure-with-step-results
instead.
lambdacd.steps.support/merge-globals
is no longer necessary, normal step result merging (merge-step-results
,merge-two-step-results
) should already conserve and merge globals just fine
A couple of functions were moved to make the package structure more clear. The existing functions still exist but are now deprecated and will be removed in the future.
lambdacd.steps.result/flatten-step-result-outputs
moved to lambdacd.stepresults.flatten
lambdacd.steps.result/{merge-step-results,merge-two-step-results}
moved to lambdacd.stepresults.merge
lambdacd.steps.result/*-resolver
moved to lambdacd.stepresults.merge-resolvers
lambdacd.steps.status/successful-when-*
moved to lambdacd.stepstatus.unify
lambdacd.steps.status/is-active?
moved to lambdacd.stepstatus.predicates
lambdacd.steps.support/assoc-build-metadata!
moved to lambdacd.stepsupport.metadata
lambdacd.steps.support/unify-only-status
moved to lambdacd.stepstatus.unify
lambdacd.steps.support/{capture-output,printed-output,print-to-output,set-output,new-printer}
moved to lambdacd.stepsupport.output
lambdacd.steps.support/{killed?,if-not-killed}
moved to lambdacd.stepsupport.killable
lambdacd.steps.support/{chaining,chain-steps,always-chaining,always-chain-steps,injected-args,injected-ctx,last-step-status-wins}
moved to lambdacd.stepsupport.chaining
lambdacd.ui.ui-server/ui-for
moved to lambdacd.ui.core
:human-readable-build-label
:pipeline-started
and :pipeline-finished
(#155):pipeline-finished
events (#155, #154):lambdacd.steps.result/flatten-step-result-outputs
lambdacd.presentation.pipeline-structure/flatten-pipeline-representation
lambdacd.presentation.pipeline-structure/step-display-representation-by-step-id
lambdacd.internal.execution
was refactored into several independent namespaces, functions were moved around, replaced or made private.
You shouldn't have dependencies on those unless you are doing something really crazy or advanced. If you did, please consider using functions in public namespaces (i.e. that don't have internal
in their name).
If you have dependencies on functions that have no public equivalent, please open an issue to get this fixed.lambdacd.execution
was deprecated in favor of lambdacd.execution.core
:unify-status-fn
parameter in execute-steps
(deprecated since 0.9.4). Use :unify-results-fn
instead. lambdacd.steps.support/unify-only-status
can help with migrating unify-status-fns.New years cleanup and bug fix release.
lambdacd.util
was cleaned up or moved to separate, internal namespaces as most of this functionality was never intended to be part of the public namespace. If you depend on utility functions and feel they should be part of LambdaCDs public API, please open an issue. Specifically, the following functions are now deprecated
lambdacd.util/write-as-json
lambdacd.util/ok
lambdacd.util/bash
lambdacd.util/range-from
lambdacd.util/map-if
lambdacd.util/no-file-attributes
lambdacd.util/temp-prefix
lambdacd.util/create-temp-dir
lambdacd.util/create-temp-file
lambdacd.util/with-temp
lambdacd.util/json
lambdacd.util/to-json
lambdacd.util/put-if-not-present
lambdacd.util/parse-int
lambdacd.util/contains-value?
lambdacd.util/buffered
lambdacd.util/fill
lambdacd.util/merge-with-k-v
This release was released without proper CSS, use 0.12.1
:use-new-event-bus true
to activate it. This will become the default in upcoming releases.lambdacd.event-bus/publish
(deprecated since 0.9.1), use lambdacd.event-bus/publish!!
instead (or lambdacd.event-bus/publish!
when being called from a go-block):step-updates-per-sec
.:step-result-update-consumed
to indicate that a step update was consumed and is available in the pipeline state #136lambdacd.state.protocols
replace lambdacd.internal.pipeline-state/PipelineStateComponent
which is now deprecated. Custom persistence-mechanisms need to migrate.lambdacd.state.core
for all state-related functionality. Access directly to PipelineStateComponent
is now deprecated.lambdacd.presentation.pipeline-state/history-for
should now be called with ctx; Calling it with a build-state (the result of lambdacd.internal.pipeline-state/get-all
) still works but is now deprecated.lambdacd.presentation.unified/unified-presentation
is now deprecated, use lambdacd.presentation.unified/pipeline-structure-with-step-results
instead:pipeline-def
in ctxlambdacd.internal.pipeline-state
to lambdacd.state.internal.pipeline-state-updater
and refactored interface. As this is an internal namespace, it should not affect users unless they customized LambdaCDs startup procedure to a large degree.:unify-status-fn
or :unify-results-fn
(e.g. chaining steps) might not pass on intermediate update events; the ultimately resulting unified step result will remain the same.nil
-check from DefaultPipelineState/{update,consume-step-result-update}
: This was meant as a convenience for internal tests that set up incomplete components. Tests have since been fixed so this is no longer necessary. If you are impacted by this issue, make sure you create DefaultPipelineState
with new-default-pipeline-state
lambdacd.internal.step-id
(was deprecated since 0.7.0), use lambdacd.step-id
insteadThis release is broken (#133), do not use
:max-builds
in config (#132). Defaults to Integer/MAX_VALUE
so this should be a non-breaking changelambdacd.execution/run
to the public namespace. If you were using lambdacd.internal.execution/run
until now, migrate to make sure you are using the official public namespace as internal interfaces can change without notice (#128)lambdacd.core
into separate namespace lambdacd.execution
. lambdacd.core/{retrigger,kill-step,execute-steps,execute-step}
are now deprecated and will be removed in subsequent releases. Use the equivalent functions in lambdacd.execution
insteadlambdacd.steps.support/{chain,always-chain,chaining,always-chaining}
now return outputs of individual chained steps (#122)lambdacd.steps.support/last-step-status-wins
to coerce a step result into having the status of the last output
to make an always-chained step successful even though it had a failing step in it (#122):unify-results-fn
to unify the whole step-result, not just the step status from children in core/execute-steps
:unify-status-fn
parameter in core/execute-steps
is now deprecated and will be removed in subsequent releases.
Use :unify-results-fn
instead.either
step to be killed when one of its children was killed (#118)with-workspace
when the workspace contained circular symlinks (#112)lambdacd.event-bus/publish
is now deprecated in favor of lambdacd.event-bus/publish!!
and lambdacd.event-bus/publish!
(to be able to properly publish from within a go-block)lambdacd.steps.support/always-chain-steps
and lambdacd.steps.support/always-chaining
to support chaining
build-steps without stopping on error, to allow post-processing steps, e.g. test-report processors. (#108)
Check the wiki for detailslambdacd.steps.support/chain-steps
with a vector of steps, use varargs insteadlambdacd.steps.support/chain
, use chaining
insteadChanged the default persistence format from JSON to EDN to fix #101. This change should be backwards and forwards compatible (i.e. you keep your history when upgrading to 0.8.0 and when downgrading to an earlier version). However, if your history is critical, consider backing up your LambdaCD home-dir just in case.
Removed deprecated function lambdacd.presentation.pipeline_state/most-recent-build-number-in
LambdaCD no longer depends on Logback as a logging implementation and gives you more freedom to choose a logging implementation. If you see the following message you need to add a dependency to a library that's compatible with SLF4J:
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
The default dependencies were:
[ch.qos.logback/logback-core "1.0.13"]
[ch.qos.logback/logback-classic "1.0.13"]
LambdaCD no longer depends on ring-server and leaves the decision on how you serve the UI to you. If you see the following error, you were probably using ring-server and need to add it to your dependencies:
Exception in thread "main" java.io.FileNotFoundException: Could not locate ring/server/standalone__init.class or ring/server/standalone.clj on classpath.
The default dependency was:
[ring-server "0.3.1"]
\r
in console output (#88)args
and ctx
if they were referred to via the namespace (#93)lambdacd.presentation.pipeline-state/overall-build-status
lambdacd.presentation.pipeline-state/latest-most-recent-update
lambdacd.presentation.pipeline-state/earliest-first-update
lambdacd.presentation.pipeline-state/build-duration
lambdacd.internal.step-id
to lambdacd.step-id
to officially make it public.
In case someone was using the internal namespace, it is still there but is considered DEPRECATED and will be removed in subsequent releases.with-workspace
now creates temporary directories in the home-dir (#79)lambdacd.presentation.pipeline-state/most-recent-build-number-in
seems to be unused and now considered DEPRECATED.
Will be removed in subsequent releases.(ui-server/ui-for pipeline-def pipeline-state ctx)
(deprecated since 0.4.3). Use (ui-server/ui-for pipeline)
instead.with-workspace
container step that allows users to run operations in the context of a clean workspace on disk (#72)either
no longer aggregates to failure if only some children failed (#67)in-parallel
no longer aggregates to failure while other children are still running (#68)successful-when-one-successful
status aggregation only fails if all statuses are :failure
(#67)successful-when-all-successful-sequential
status aggregation doesn't fail while other steps are still running (#68)UI: Displaying duration of each build step (#34)
Prevent retriggering of steps that have dependencies to previous steps by adding :depends-on-previous-steps true
to metadata:
(defn ^{:depends-on-previous-steps true} publish-artifact [{cwd :cwd} ctx]
(shell/bash ctx cwd
"./publish.sh"))
This can be useful if several steps work on a workspace created by a nested step (such as with-git
) and rely on the products of previous steps.
See #36 for details.
Improved calculation of build duration for retriggered pipelines (#30)
UI: collapsing child steps by default (#59)
Add feature to alias build steps in UI:
; this displays "trigger" instead of "either" in UI
(alias "trigger"
(either
wait-for-manual-trigger
wait-for-repo))
UI: Added feedback after killing a step
Killing a shell/bash
-step now kills the whole process tree spawned by it. This helps in cases where the step spawns
longer-running processes and bash doesn't pass on the TERM signal to its children)
Fixed UI bug where pipeline was no longer visible for long step output
Added lambdacd.steps.support/capture-output
to simplify working with stdout in build-steps (#60)
Added lambdacd.steps.support/chaining
, a more flexible and powerful variant of the existing chain
macro. (#39)
It supports injecting args
and ctx
at random places and, together with capture-output, also allows for
easy debugging:
(chaining {} {}
(some-step injected-args injected-ctx)
; prints the foo value that's returned by some-step and is injected into some-other-step
(print "foo-value:" (:foo injected-args))
(some-other-step injected-args injected-ctx))
This change also DEPRECATES lambdacd.steps.support/chain
which will be removed in subsequent releases.
:global
values can now be overwritten by later stages in the pipeline (#61)title
tag of UI if configured.first-updated-at
timestamps when retriggering children of container-steps (#56, flosell/lambdacd-cctray#3)with-git-branch
that always checks out the latest commit on a particular branch (as opposed to with-git
which checks out a revision given in args
or the master
branch in case nothing is given) (#46) (thanks @exload
for this):name
Made :display-type :container
the default for container steps, no longer throwing incomprehensible exceptions
when display-type declarations are forgotten (#43)
Now supporting steps with parameters in the pipeline:
(defn mk-pipeline-def [{repo-uri :repo-uri test-command :test-command}]
`(
wait-for-manual-trigger
(with-repo ~repo-uri
(run-tests ~test-command)
publish)))
Polished the UI
internal.default-pipeline-state
so they can be reused in other persistence components (#38)assemble-pipeline
and pushes updates to any pipeline-state
component that is configured (#38)assemble-pipeline
(#40)either
didn't kill remaining steps after finishing/api/builds/<buildnumber>/
now returns status 404 in case the build does not exist instead of
returning a half empty data-structure (#42):state
in the result of assemble-pipeline:step-results-channel
pipeline-state-updater
now started by assemble-pipeline (see above), pipeline-state component should no longer
start their own update mechanism (#38)Housekeeping release: Contains mostly cleanup under the hood and changes to APIs for advanced users. If you are using custom control-flow steps, runners, persistence mechanisms or other advanced features, make sure you look through the changes and upgrade as future releases will remove deprecated functionality.
:step-result-updated
and :step-finished
on event-bus for use by other components like
runners and persistence components (#38)core/execute-step
:step-results-channel
is now deprecated, unsupported and will be removed in subsequent releases.
Use the new :step-result-updated
event and filter on :step-id
to receive updates from child-steps while they run.(ui-server/ui-for pipeline-def pipeline-state ctx)
is now deprecated and will be removed in subsequent releases.
Use (ui-server/ui-for pipeline)
instead.:state
in the result of assemble-pipeline is now deprecated
and will be removed in subsequent releases. Use the event-bus or access the state through the PipelineStateComponent
protocol instead.default-pipeline-state/notify-when-no-first-step-is-active
.
Use the new events (see above) to be notified about changes to the state of the pipelineIncreased time between git-polls in git/wait-for-git
and git/wait-for-details
to 10 seconds and
made that value configurable with an optional parameter :ms-between-polls
, e.g.
(git/wait-with-details ctx some-repo-uri "master" :ms-between-polls 60000)
Added a feature to kill running steps on user request (#31)
junction
control flow step that adds a way to model if-then-else logic in a pipeline (#28,#32)logback.xml
in the published jar.chain-steps
(#29):step-results-channel
which can be used to access a stream of step-state updates,
e.g. to create custom persistence components or runners (still experimental):status
will now be treated as failures instead of receiving status :undefined
:result-channel
argument for execute-step
core/new-base-context-for
core/execute-step
does no longer output the result-channel data to a :result-channel
in ctx.
Was replaced with :step-results-channels
which provides a stream of complete, aggregated step-result datalambdacd.steps.support/chain-steps
with a vector instead of just the steps is now deprecated (#29)run
-container step that can group nested steps (#21):result-channel
argument for execute-step
is now deprecated. Pass custom result-channels in via the ctx insteadexecute-step
, therefore core/new-base-context-for
is now deprecated, just use ctx
insteadchain
-macroshell/bash
(#9)lambdacd.internal.execution/execute-steps
support/print-to-output
simplifies printing to the output-channel within a stepsupport/printed-output
in return allows you to get everything that was printed within that step, typically to return at the end of a stepwith-git
removes its workspace after all child-steps are finishedlambdacd.internal.execution/execute-steps
is now deprecated. use the public lambdacd.core/execute-steps
instead. (#7)
lambdacd.core/execute-steps
takes keyword-arguments instead of argument lists for optional parameters.lambdacd.internal.execution/execute-step
is now deprecated. use the public lambdacd.core/execute-step
instead. (#7)wait-for-git
no longer returns immediately when no last commit is known. Instead just waits for the first commit.
This behavior seems more intuitive since otherwise on initial run, all build pipelines would start running.with-commit-details
, a function that enriches the wait-for-git
result with information about the
commits found since last build and a convenience function wait-with-details
that wraps both./api/pipeline
and /api/pipeline-state
core/mk-pipeline
as a method to initialize the pipeline.
Replaced with a more flexible core/assemble-pipeline
and a few single functions that take over things like running
the pipeline and providing ring-handlers to access the pipeline. For details, see examples.scripts/migrate-to-new-package-structure.sh
can help rewrite your code to work with the new structure)
control-flow
, git
, manualtrigger
and shell
are now in steps
-packagelambdacd.presentation
is now lambdacd.presentation.pipeline-structure
lambdacd.pipeline-state
to lambdacd.presentation.pipeline-state
internal
packageui
packagesteps now receive a :result-channel
value through the context to send intermediate values.
use this channel instead of returning a result-channel from the step. the latter is now DEPRECATED and will be removed in the next release.
bash
now needs the context as first parameter:
(shell/bash ctx cwd
"lein test")
no breaking API changes
wait-for-git
now receives the context as first parameter: (wait-for-git ctx some-repo some-branch)
The context must contain a configuration with the :home-dir
set to a directory where the step can store a file with the last seen revisions (see below)mk-pipeline
requires and additional parameter, the configuration-map (which is where you set the home-dir)(async/>!! ch [:out "hello"])
(async/>!! ch [:out "hello world"])
(async/>!! ch [:status :success])
(async/close! ch)
:status
value in a steps result-map. Use channels for the whole result instead (see above)(defn some-step [args step-id])
(defn some-step [args {:keys [step-id] :as ctx}])
start-pipeline-thread
has been removed as the initializing function. use the new setup-functionality using mk-pipeline
:(def pipeline (core/mk-pipeline pipeline-def))
(def app (:ring-handler pipeline))
(def start-pipeline-thread (:init pipeline))
Can you improve this documentation? These fine people already did:
Florian Sellmayr, flosell, Jan-Hendrik Peters, Astma, Your Name & Matthias SpliethEdit on GitHub
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close