<feed xmlns='http://www.w3.org/2005/Atom'>
<title>otp.git/lib/kernel/src, branch sverker-ets-patch-1</title>
<subtitle>Mirror of Erlang/OTP repository.
</subtitle>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/'/>
<entry>
<title>Merge branch 'raimo/receive-TOS-TCLASS/ERIERL-187/OTP-15145' into maint</title>
<updated>2018-09-17T13:42:01+00:00</updated>
<author>
<name>Raimo Niskanen</name>
<email>raimo@erlang.org</email>
</author>
<published>2018-09-17T13:42:01+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=d6a08843e473da6eebbab0b0e7312efc978108ee'/>
<id>d6a08843e473da6eebbab0b0e7312efc978108ee</id>
<content type='text'>
* raimo/receive-TOS-TCLASS/ERIERL-187/OTP-15145:
  Write testcases for recvtos and friends
  Fix term buffer overflow bug
  Fix documentation due to feedback
  Implement socket option recvtos and friends
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* raimo/receive-TOS-TCLASS/ERIERL-187/OTP-15145:
  Write testcases for recvtos and friends
  Fix term buffer overflow bug
  Fix documentation due to feedback
  Implement socket option recvtos and friends
</pre>
</div>
</content>
</entry>
<entry>
<title>[logger] Read config before terminating handler process</title>
<updated>2018-09-14T12:12:13+00:00</updated>
<author>
<name>Siri Hansen</name>
<email>siri@erlang.org</email>
</author>
<published>2018-09-14T12:12:13+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=6073d37a5a0691704d0fa1a5ff9289ba9e35c8ed'/>
<id>6073d37a5a0691704d0fa1a5ff9289ba9e35c8ed</id>
<content type='text'>
When a handler process is terminated due to overload, it reads its
configuration from the configuration database, so it can be restarted
with the same configuration after a small delay. This was earlier done
in a different process, which was spawned off from the terminate
function. This caused a race condition, where in some cases, the
configuration was already removed before it could be read.

The reason for spawning off a process, is to avoid a deadlock due to
the call to logger:remove_handler/1.

This commit moves the call to logger:get_handler_config/1 back to the
handler process - to ensure that the data is still there, but keeps
the call to logger:remove_handler/1 in the spawned off process - to
avoid deadlock.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When a handler process is terminated due to overload, it reads its
configuration from the configuration database, so it can be restarted
with the same configuration after a small delay. This was earlier done
in a different process, which was spawned off from the terminate
function. This caused a race condition, where in some cases, the
configuration was already removed before it could be read.

The reason for spawning off a process, is to avoid a deadlock due to
the call to logger:remove_handler/1.

This commit moves the call to logger:get_handler_config/1 back to the
handler process - to ensure that the data is still there, but keeps
the call to logger:remove_handler/1 in the spawned off process - to
avoid deadlock.
</pre>
</div>
</content>
</entry>
<entry>
<title>[error_logger] Handle report_cb with arity 2</title>
<updated>2018-09-12T12:58:02+00:00</updated>
<author>
<name>Siri Hansen</name>
<email>siri@erlang.org</email>
</author>
<published>2018-09-11T09:18:52+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=48a1c458a46dcd1f031fd3b9689af80b32b4a6a2'/>
<id>48a1c458a46dcd1f031fd3b9689af80b32b4a6a2</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[logger] Include single_line option to report_cb</title>
<updated>2018-09-12T12:58:02+00:00</updated>
<author>
<name>Siri Hansen</name>
<email>siri@erlang.org</email>
</author>
<published>2018-09-12T12:37:02+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=a4ff9f378ae7008e268d1c2facd44d049be6e930'/>
<id>a4ff9f378ae7008e268d1c2facd44d049be6e930</id>
<content type='text'>
If the report callback function has two arguments, the second argument
is a map with options to limit the size of the log event. To even
allow a better formatting when the event shall be printed on a single
line, the new option single_line is now included in this
argument.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If the report callback function has two arguments, the second argument
is a map with options to limit the size of the log event. To even
allow a better formatting when the event shall be printed on a single
line, the new option single_line is now included in this
argument.
</pre>
</div>
</content>
</entry>
<entry>
<title>[logger] Check for deadlock when removing filters</title>
<updated>2018-09-12T12:58:02+00:00</updated>
<author>
<name>Siri Hansen</name>
<email>siri@erlang.org</email>
</author>
<published>2018-09-11T12:11:29+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=7140fe7679c1ea0862961d2fc34f9d8283c04ca3'/>
<id>7140fe7679c1ea0862961d2fc34f9d8283c04ca3</id>
<content type='text'>
If a filter fails, it is removed by a call to
logger:remove_filter/1,2. If the log event that caused the failure was
issued on the logger process itself, this would earlier cause a
deadlock due to a gen_server:call to self(). This is now prevented.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If a filter fails, it is removed by a call to
logger:remove_filter/1,2. If the log event that caused the failure was
issued on the logger process itself, this would earlier cause a
deadlock due to a gen_server:call to self(). This is now prevented.
</pre>
</div>
</content>
</entry>
<entry>
<title>[logger] Fix spec for handler callbacks to always return ok</title>
<updated>2018-09-12T12:58:02+00:00</updated>
<author>
<name>Siri Hansen</name>
<email>siri@erlang.org</email>
</author>
<published>2018-09-07T14:49:30+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=a98ffe831d2a1cf44d0b7c53e2d72ade9d5a3dbb'/>
<id>a98ffe831d2a1cf44d0b7c53e2d72ade9d5a3dbb</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[logger] Improve code coverage in test</title>
<updated>2018-09-12T12:58:02+00:00</updated>
<author>
<name>Siri Hansen</name>
<email>siri@erlang.org</email>
</author>
<published>2018-09-06T12:30:36+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=625616652595249ff0866d4de8a04f3c8fa0eec4'/>
<id>625616652595249ff0866d4de8a04f3c8fa0eec4</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[logger] Refactor, and add error detection for configuration</title>
<updated>2018-09-12T12:58:02+00:00</updated>
<author>
<name>Siri Hansen</name>
<email>siri@erlang.org</email>
</author>
<published>2018-09-06T11:51:49+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=a9a72da93e9b93a1d7ee9936b8e223545277480e'/>
<id>a9a72da93e9b93a1d7ee9936b8e223545277480e</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[logger] Remove encoding option from logger_formatter</title>
<updated>2018-09-12T12:58:02+00:00</updated>
<author>
<name>Siri Hansen</name>
<email>siri@erlang.org</email>
</author>
<published>2018-08-31T15:08:24+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=96c1aa0041b368afceef0aef88e82a6c9f8e901d'/>
<id>96c1aa0041b368afceef0aef88e82a6c9f8e901d</id>
<content type='text'>
The encoding option was introduced in commit
270d909696a753af022df72a404c73f2895b4a02, to allow report callbacks to
format according to a given encoding. There was, however, no
connection between this encoding option, and the encoding of the
device to which the logger handler was writing.

Since a formatter is defined to return unicode:chardata(), and in
order to avoid mismatch with the encoding of the device, the encoding
option is now removed from the formatter. The handler itself must make
sure that it does not write illegal data to its device.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The encoding option was introduced in commit
270d909696a753af022df72a404c73f2895b4a02, to allow report callbacks to
format according to a given encoding. There was, however, no
connection between this encoding option, and the encoding of the
device to which the logger handler was writing.

Since a formatter is defined to return unicode:chardata(), and in
order to avoid mismatch with the encoding of the device, the encoding
option is now removed from the formatter. The handler itself must make
sure that it does not write illegal data to its device.
</pre>
</div>
</content>
</entry>
<entry>
<title>[logger] Refactor some logger internals</title>
<updated>2018-09-12T12:58:02+00:00</updated>
<author>
<name>Siri Hansen</name>
<email>siri@erlang.org</email>
</author>
<published>2018-08-14T09:43:18+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=b6289e914c67bd786da829503b144c039303bfd3'/>
<id>b6289e914c67bd786da829503b144c039303bfd3</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
</feed>
