From: adrian.freihofer@gmail.com
To: Alexander Kanavin <alex.kanavin@gmail.com>
Cc: Richard Purdie <richard.purdie@linuxfoundation.org>,
openembedded-architecture
<openembedded-architecture@lists.openembedded.org>,
Michael Halstead <mhalstead@linuxfoundation.org>,
Yocto-mailing-list <yocto@lists.yoctoproject.org>,
",openembedded-core@lists.openembedded.org"
<openembedded-core@lists.openembedded.org>,
Julien STEPHAN <jstephan@baylibre.com>
Subject: Re: [OE-core] Core workflow: sstate for all, bblock/bbunlock, tools for why is sstate not being reused?
Date: Sat, 04 Nov 2023 11:29:23 +0100 [thread overview]
Message-ID: <58e2c7a830bceac9b3a8c6cee63f03ae4a118da0.camel@gmail.com> (raw)
In-Reply-To: <CANNYZj_Cq+cncw5SCGii=Mhj0KGgo=qr=hCuo+wpdvtR9C=Qyg@mail.gmail.com>
Hi Alex, hi Richard
After some internal discussions, I would like to clarify my previous
answers on this topic.
* Usually there are two different workflows
- application developers: could use an SDK with a locked sstate-cache.
- Yocto/BSP developers: need an unlocked SDK. They change the recipes.
* A locked SDK
- can work with setscene from SSTATE_MIRRORS
- setscene does caching in the SSTATE_DIR (no issue about that)
- But network problems can occur during the initial build because
bitbake executes many independent setscene tasks. Opening so many
independent connections slows down the build, especially if the
server treats them as a denial of service attack.
- The denial of service problem is difficult to solve because each
setscene task runs in its own bibtake task. Reusing a connection to
download multiple sstate artifacts seems almost impossible.
This is much easier to solve with separate sstate download script.
* An unlocked SDK
- Tries to download the sstate cache for changed recipes and their
dependencies, which obviously can't work.
- The useless download requests slow down the build considerably and
cause a high load on the servers without any benefit.
- A script which gets a list of sstate artifacts from bitbake and then
does a upfront download works much better
+ The script runs only when the user calls it or the SDK gets boot-
strapped
+ The script uses a reasonable amount of parallel connections which
are re-used for more then one artifact download
* Idea for a smart lock/unlock implementation
- Form a user's perspective a locked vs. an unlocked SDK does not make
much sense. It makes more sense if the SDK would automatically
download the sstate-cache if it is expected to be available.
Lets think about an implementation (which allows to override the
logic) to switch from automatic to manual mode:
SSTATE_MIRRORS_ENABLED ?= "${is_sstate_mirror_available()}"
In our case the sstate mirror is expected to provide all artifacts
for tagged commits and for some git branches of the layer
repositories.
The sstate is obviousely not usable for a "dirty" git layer
repository. That's what the is_sstate_mirror_available function
could check to automatically enable and disable lazy downloads.
- If is_sstate_mirror_available() returns false, it should still be
possible to initiate a sstate-cache download manually.
* Terminology
- Older Yocto Releases:
+ eSDK means an installer which provides a different environment with
different tools
+ The eSDK was static, with a locked sstate cache
+ Was for one MACHINE, for one image...
- Newer Yocto Releases:
+ The bitbake environment offers all features of the eSDK installer. I
consider this as already implemented with meta-ide-support and
build-sysroots.
+ The term eSDK means a replicable bitbake environment. (The
documentation was recently changed in that sense)
+ The new SDK installer can be generated in different variants similar
to what was already supported by the eSDK
installer: https://docs.yoctoproject.org/sdk-manual/appendix-
customizing.html#customizing-the-extensible-sdk-standalone-
installer.
* The lightest variant is just a script that sets up the layers (git
clone or git checkout) and provides the build config. If
SSTATE_MIRRORS are configured lazy downloads will just work
otherwise bitbake will compile everything from scratch.
* The heaviest variant of the SDK installer includes the layers and
the sstate-cache. After installing it is_sstate_mirror_available()
evaluates to True.
* devtool ide
- Tries to bring this ideas further towards IDE configuration
- It supports two modes: No recipe mode is like the old eSDK
environment. The recipe mode goes beyond that. It is based on
devtool modify.
- Naming: I was thinking about "devtool ide" versus "devtool esdk"
+ Why ide? I want to set up my IDE to work with the Yocto SDK. And
that means, of course, that I have to bootstrap the SDK.
+ Could also be esdk: I want to bootstrap the eSDK and that should
also configure my IDE.
* Latest patch series is here:
- https://lists.openembedded.org/g/openembedded-core/message/189899
- docs: https://lists.yoctoproject.org/g/docs/message/4578
Adrian
next prev parent reply other threads:[~2023-11-04 10:29 UTC|newest]
Thread overview: 48+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-12 14:44 Yocto Project Status 12 September 2023 (WW37) Stephen K Jolley
2023-09-14 11:52 ` Core workflow: sstate for all, bblock/bbunlock, tools for why is sstate not being reused? Alexander Kanavin
2023-09-14 12:56 ` Richard Purdie
2023-09-14 18:51 ` Alexander Kanavin
2023-09-14 19:54 ` Richard Purdie
2023-09-15 8:28 ` Alexander Kanavin
2023-09-20 14:25 ` Julien Stephan
2023-09-20 14:31 ` Alexander Kanavin
2023-09-20 18:04 ` Julien Stephan
2023-09-21 11:11 ` Alexander Kanavin
2023-09-21 14:39 ` [Openembedded-architecture] " chris.laplante
2023-09-22 9:17 ` Alexander Kanavin
2023-09-22 10:42 ` Richard Purdie
2023-09-28 16:43 ` Alexander Kanavin
2023-09-28 16:49 ` Richard Purdie
2023-09-28 17:07 ` Alexander Kanavin
2023-09-29 12:06 ` Alexander Kanavin
2023-09-29 12:27 ` Richard Purdie
2023-09-29 13:09 ` Alexander Kanavin
2023-11-01 14:18 ` [OE-core] " adrian.freihofer
2023-11-01 15:19 ` Alexander Kanavin
2023-11-01 17:20 ` [Openembedded-architecture] " adrian.freihofer
2023-11-04 10:29 ` adrian.freihofer [this message]
2023-11-04 11:09 ` Richard Purdie
2023-11-05 19:43 ` adrian.freihofer
2023-11-06 11:48 ` Alexander Kanavin
2023-11-06 19:42 ` [Openembedded-architecture] " Mark Hatle
2023-10-30 13:50 ` Alexander Kanavin
2023-10-30 14:07 ` Richard Purdie
2023-10-30 15:02 ` Alexander Kanavin
[not found] ` <1792EACC19CD8046.7262@lists.openembedded.org>
2023-10-31 12:08 ` [OE-core] " Alexander Kanavin
2023-10-31 12:28 ` Richard Purdie
2023-10-31 13:53 ` Alexander Kanavin
2023-11-01 15:45 ` [yocto] " adrian.freihofer
2023-11-01 17:28 ` Alexander Kanavin
2023-11-02 8:32 ` adrian.freihofer
2023-11-02 9:02 ` Alexander Kanavin
[not found] ` <1793C2E61248AF31.11290@lists.yoctoproject.org>
2023-11-02 11:51 ` Alexander Kanavin
2024-01-22 10:47 ` Alexander Kanavin
[not found] ` <17ACA59E7A7FD97B.16230@lists.openembedded.org>
2024-02-05 20:35 ` [OE-core] " Alexander Kanavin
2024-02-05 21:11 ` Richard Purdie
2024-02-08 13:35 ` Alexander Kanavin
2024-02-08 13:42 ` Richard Purdie
2024-02-13 13:25 ` Alexander Kanavin
2024-02-13 13:44 ` Richard Purdie
2024-02-13 14:05 ` Alexander Kanavin
2024-02-13 14:28 ` Joshua Watt
2024-02-14 6:31 ` Alexander Kanavin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=58e2c7a830bceac9b3a8c6cee63f03ae4a118da0.camel@gmail.com \
--to=adrian.freihofer@gmail.com \
--cc=alex.kanavin@gmail.com \
--cc=jstephan@baylibre.com \
--cc=mhalstead@linuxfoundation.org \
--cc=openembedded-architecture@lists.openembedded.org \
--cc=openembedded-core@lists.openembedded.org \
--cc=richard.purdie@linuxfoundation.org \
--cc=yocto@lists.yoctoproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox