Age | Commit message (Collapse) | Author |
|
|
|
On some test hosts a lot of applications are skipped from the erlang
installation in order to make test go faster.
systools_SUITE:app_start_type_relup uses a few applications which
therefore might not exist. This commit make sure the test is skipped
(instead of fail) if some of the needed applications are missing.
|
|
* dumbbell/function_clause-in-systools_make-format_error:
sasl: Fix crash in systools_make:format_error/1
OTP-11819
|
|
The crash occurred when systools:make_script/2 raises the
'duplicate_modules' error. Depending on the 'silent' option,
systools_make:format_error/1 is called to either format and display an
error message, or return a tuple containing the error properties.
When displaying a 'duplicate_modules' error message, format_error/1
receives a list of applications providing the same module(s):
[
{{Mod,App1,_}, {Mod,App2,_}},
...
]
However, before this fix, format_error/1 expected the following
structure, leading to a 'function_clause' exception:
[
{{Mod,_,App1,_,_}, {Mod,_,App2,_,_}},
...
]
The crash never occurred with the 'silent' option, because the error and
its properties are returned as is to the caller.
|
|
Conflicts:
erts/etc/win32/Install.c
|
|
|
|
|
|
This is to avoid lingering files after test runs on windows, since the
cleanup script often does not succeed in removing files with unicode
characters.
|
|
Some files with icky names (unicode) can not be deleted with the
cleanup scripts after daily tests. Therefore it is better to clean up
directly from the erlang node after test is run.
|
|
|
|
|
|
* siri/sasl/correct-app-name-in-error/OTP-9888:
Fix error message if stdlib has faulty start type in .rel file
|
|
If stdlib had a different start type than permanent, systools_make
would fail but it would say that it was sasl that had faulty start
type. This has been corrected.
|
|
OTP-9984
Applications that are listed in {applications,Apps} in the app file
were not sorted correctly in the script file. They were loaded/started
in the reverse order of how they were listed in the .app file.
This is corrected so they are now sorted (internally between each
other) in the same way as they are listed in the .rel file.
|
|
* siri/sasl/check-config-in-tar/OTP-9539:
Check that sys.config and relup have valid content when added to tar
|
|
systools:make_tar now does a minor check of the content of sys.config
and relup before adding them to the tar file. If the content is not
readable or in expected format, the function fails.
|
|
It should not be possible to create a .boot file unless kernel and
stdlib are stated as permanent applications in the .rel file. Note
that 'permanent' is the default start type, so not specifying a start
type for kernel and stdlib is, as always, ok.
|
|
|
|
This option will suppress the 'missing-sasl' warning which otherwise
is issued when compiling a .rel file which does not include the sasl
application.
|
|
make_script will give warning but allow it
make_relup will fail since it is not possible to upgrade if sasl is
not included in both releases.
|
|
New emulator upgrade mechanism introduced in R15 can only work if the
sasl version to upgrade from is 2.2 or later. I.e. if we are already
running at least R15.
This commit adds backwards compatiblity for upgrades from earlier
versions, meaning that the new code is loaded into the old emulator
and code_change is executed - then after all application code is
updated, the emulator is restarted with the new erts version.
Note that this might cause problems if the new code is compiled with
the new emulator and there have been updates to the beam format. If
this happens, the workaround is to compile the new code with the old
emulator.
|
|
Earlier, there was only one valid instruction to restart the emulator
in an appup/relup script, 'restart_new_emulator'. A new instuction,
'restart_emulator', is now added, and the meaning is as follows:
'restart_new_emulator' is mainly for the core applications (erts,
kernel, stdlib and sasl), and it indicates that there is new core
functionality in the release and the emulator needs to be restarted
before executing the upgrade scripts. If this instruction exists, a
temporary release will be created which consists of the new version
erts, kernel, stdlib and sasl, and the old versions of all other
applications. After restarting the emulator with this temporary
release, the rest of the upgrade instructions are executed, including
loading of new versions.
'restart_emulator' can be used by any application if a restart of the
emulator is needed after the upgrade instructions have been
executed. In this case, the emulator will be restarted with the new
release (i.e. not a tempoarary one) after all other upgrade
instructions for all applications have been excecuted.
|
|
The sys.config file used for the temporary release in an erts upgrade
is now a hybrid where kernel, stdlib and sasl configuration is taken
from the new release, and other configuration is taken from the old
release. I.e. similar to how the temporary boot file is created.
|
|
In order to avoid duplication of upgrade instructions in .appup files,
we now allow regular expressions to specify the UpFrom and DownTo
versions. To be considered a regular expression, the version
identifier must be specified as a binary, e.g.
<<"2\\.1\\.[0-9]+">> will match versions 2.1.x, where x is any number.
|
|
If the version of erts differs between two releases, the release
handler automatically adds a 'restart_new_emulator' instruction to the
upgrade script (relup). Earlier, this instruction was always added at
the end of the upgrade script, causing the following sequence of
operations during an upgrade (a bit simplified):
1. suspend processes
2. load new code
3. execute code_change functions
4. resume processes
5. restart emulator with new erts version
Obviously, this caused the new code to be loaded into the old emulator
and this would fail if the beam format had been changed in the new
version of the emulator.
To overcome this problem, this commit changes the order of the
instructions, so for upgrade with changed erts version we now have:
1. restart emulator with new erts, kernel, stdlib and sasl versions,
but old versions of all other applications.
2. suspend processes
3. load new code
4. execute code_change functions
5. resume processes
This is implemented by creating a temporary release, including new
erts, kernel, stdlib and sasl from the new release and all other
applications from the old release. A new boot file for this temporary
release is created, which includes a new 'apply' instruction to run
release_handler:new_emulator_upgrade/2. Then the emulator is restarted
using this boot file - and release_handler:new_emulator_upgrade/2
executes the rest of the upgrade script.
For downgrade, the order will be as before:
1. suspend processes
2. execute code_change functions with 'down'-indication
3. load old code
4. resume processes
5. restart emulator with old erts version
|
|
|
|
If a path was given as ONLY 'ebin' and not for example './ebin', then
systools:make_tar would fail with a function_clause exception in
filename:join/1. The bug was in systools_make:appDir/1, which tried to
find the parent directory of the given path. This function now uses
library functions filename:basename and filename:dirname instead of
general list manipulations.
|
|
|