summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* initial gen_server doc suggestiondgud/stdlib/gen-async-callDan Gudmundsson2017-09-221-0/+72
|
* stdlib: Add 'async_call' and 'yield' to generic behaviorsDan Gudmundsson2017-09-227-17/+215
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Simplify and encourage users to do more async work, the usage pattern is already available in 'rpc' module and similar usages are available in other languages and standards. Async calls can be implemented via cast or regular messages, but then the user need to implement it both in client and server. In this implementation the server does not need to know that the client are making async calls. This deliberately opens up and exposes the monitor reference, so that the user can choose not call 'yield' and instead do: Promise = gen:async_call(..), ... receive {Promise, Reply} -> erlang:demonitor(Promise, [flush]), Reply; {'DOWN', Promise, _, _, Reason} -> error(Reason) end, Or use async_call(..) from an gen_server to another gen behavior while not blocking the invoking server and handle the reply when it arrives in handle_info(..). This implies that systems that do can not handle monitors are not allowed to be used as target in async_call(). yield/[1|2] returns {reply, Reply} instead of {ok, Reply} since Reply may be positive or negative answer i.e.: {reply, {ok, Value}} and {reply, {error, Reason}} looks better than {ok, {error, Reason}} or {ok, {ok, Value}}. And we need to encapsulate the return value to differ between client timeouts and server response which may be the atom timeout, e.g. timeout vs {reply, timeout} We don't want do exit(timeout) since then you can't do non_blocking yields without catching the call to yield(Promise, 0).
* Merge branch 'maint'Dan Gudmundsson2017-09-2014-17/+17
|\ | | | | | | | | | | * maint: erts, stdlib: Fix xmllint warning Update runtime deps to depend on new stdlib functionality
| * Merge branch 'dgud/update-runtime-deps' into maintDan Gudmundsson2017-09-2014-17/+17
| |\ | | | | | | | | | | | | * dgud/update-runtime-deps: Update runtime deps to depend on new stdlib functionality
| | * Update runtime deps to depend on new stdlib functionalityDan Gudmundsson2017-09-1914-17/+17
| | | | | | | | | | | | ~tw and new string functions are new since OTP-20 (stdlib-3.4)
| * | erts, stdlib: Fix xmllint warningHans Bolinder2017-09-202-2/+2
| | |
* | | Merge branch 'maint'Siri Hansen2017-09-1919-199/+548
|\ \ \ | |/ / | | | | | | | | | | | | | | | Conflicts: lib/observer/src/crashdump_viewer.erl lib/sasl/src/sasl.appup.src lib/stdlib/src/stdlib.appup.src
| * | Merge branch 'siri/cdv/crash-on-large-dump/OTP-14386' into maintSiri Hansen2017-09-1915-188/+454
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * siri/cdv/crash-on-large-dump/OTP-14386: observer: Improve debugging code in test suite cdv: Add ~tw as formatting option when expanding a term observer: Remove compiler warnings in test and set warnings_as_errors cdv: Warn about unsafe crashdump cdv: Show progress bar while reading big data cdv: Optimize reading of crashdump with many binaries cdv: Find end of 'Last calls' section cdv: Don't mark process as truncated if truncation is after all proc_heaps cdv: Set ERL_CRASH_DUMP_SECONDS to 0 in cdv scripts
| | * | observer: Improve debugging code in test suiteSiri Hansen2017-09-181-1/+4
| | | |
| | * | cdv: Add ~tw as formatting option when expanding a termSiri Hansen2017-09-181-0/+1
| | | |
| | * | observer: Remove compiler warnings in test and set warnings_as_errorsSiri Hansen2017-09-183-16/+16
| | | |
| | * | cdv: Warn about unsafe crashdumpSiri Hansen2017-09-182-1/+37
| | | | | | | | | | | | | | | | | | | | Warn the user if the node executing the crashdump viewer potentially could overwrite the crashdump under inspection.
| | * | cdv: Show progress bar while reading big dataSiri Hansen2017-09-189-43/+132
| | | |
| | * | cdv: Optimize reading of crashdump with many binariesSiri Hansen2017-09-153-99/+193
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Earlier, crashdump_viewer stored an index of all binaries in a gb_tree on startup. The binary index was also stored in the cdv_dump_index_table along with all other "=xxx" tags from the dump. The difference between the indices was that the ets table contained the addresses of the binaries as strings (the hex address found after the "=binary:" tag) and in the gb_tree this hex address was instead converted to its integer value. The index in the ets table was only used once - when creating the gb_tree. The gb_tree was used for all later looups (to map integer address to file position). This commit replaces the two storages with one new ets table, cdv_binary_index_table, using the integer value of the hex address as key, and the position in the crashdump file as value. In the case of many binaries, this makes the start of crashdump viewer faster (only one place to write), and the data usage smaller (hex address strings are no longer stored). And it avoids the gc of the gb_tree.
| | * | cdv: Find end of 'Last calls' sectionSiri Hansen2017-09-132-27/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a bug fix: the end of the 'Last calls' section is meant to be an empty line, but in some situations this is not the case. This could cause the complete dump to be read and stored as 'Last calls', causing very unexpected behavior in the crashdump viewer. This commit adds a check for ": ", which indicates that a new heading has occured and thus the 'Last calls' section is completly read.
| | * | cdv: Don't mark process as truncated if truncation is after all proc_heapsSiri Hansen2017-09-131-1/+7
| | | |
| | * | cdv: Set ERL_CRASH_DUMP_SECONDS to 0 in cdv scriptsSiri Hansen2017-09-132-2/+2
| | | | | | | | | | | | | | | | | | | | This is to avoid crashdumps generated by crashdump_viewer, possibly overwriting the currently analysed crashdump.
| * | | Merge branch 'siri/appups-20.1' into maintSiri Hansen2017-09-192-4/+10
| |\ \ \ | | | | | | | | | | | | | | | | | | | | * siri/appups-20.1: Update appup in stdlib and sasl for OTP-20.1
| | * | | Update appup in stdlib and sasl for OTP-20.1Siri Hansen2017-09-182-4/+10
| | | | |
| * | | | Merge pull request #1564 from goertzenator/ecpkparameter_fixIngela Andin2017-09-194-11/+94
| |\ \ \ \ | | |_|_|/ | |/| | | | | | | | | | | | | fix ERL-481 ecpkParameters representation OTP-14621
| | * | | skip ec_pem_encode_generated when underlying crypto not availableDaniel Goertzen2017-09-151-0/+7
| | | | |
| | * | | fix ERL-481 ecpkParameters representationDaniel Goertzen2017-09-114-11/+87
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - type spec ecpk_parameters() added to represent DER-encodable ecpkParameters - type spec ecpk_parameters_api() added to represent ecpkParameters provided by the user through public_key API functions - API is now more generous in its input, and more strict in its output. - update to public key records documentation - add tests, including tests against EC key with explicit curve parameters - also fixes ERL-480
* | | | | Merge pull request #1557 from egobrain/000-fix-dns-lookupRaimo Niskanen2017-09-191-5/+7
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | OTP-13133 Fixed dns lookup in case of server close connection with econnrefused
| * | | | | Fixed dns lookup in case of server close connection with econnrefusedKozlov Yakov2017-09-131-5/+7
| | | | | |
* | | | | | Merge branch 'maint'Anders Svensson2017-09-185-21/+55
|\ \ \ \ \ \ | | |/ / / / | |/| | | |
| * | | | | Merge branch 'anders/diameter/20.1/OTP-14561' into maintAnders Svensson2017-09-182-3/+5
| |\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | * anders/diameter/20.1/OTP-14561: Update appup and version for 20.1
| | * | | | | Update appup and version for 20.1Anders Svensson2017-09-152-3/+5
| | | | | | |
| * | | | | | Merge branch 'anders/diameter/sctp/OTP-10889' into maintAnders Svensson2017-09-182-17/+49
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * anders/diameter/sctp/OTP-10889: Make unordered delivery configurable
| | * | | | | | Make unordered delivery configurableAnders Svensson2017-09-172-17/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changing the default in the parent commit is possibly a bit dangerous, even if the motivation still holds. Take a step back and make unordered delivery a matter of configuration, without changing the default: configuration is {unordered, boolean() | pos_integer()}, with false the default, and N equivalent to OS =< N, where OS is the number of outbound streams negotiated on the association in question. A user can mess with this by configuring an sctp_default_send_param of their own, but unordered sending is them from start, not only after the second message reception.
| * | | | | | | Merge branch 'anders/diameter/performance/OTP-14521' into maintAnders Svensson2017-09-181-1/+1
| |\ \ \ \ \ \ \ | | |_|_|_|_|/ / | |/| | | | | | | | | | | | | | | | | | | | | | * anders/diameter/performance/OTP-14521: Fix append of Route-Record AVPs
| | * | | | | | Fix append of Route-Record AVPsAnders Svensson2017-09-151-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit b3d9e0c0 did away with the reordering of diameter_avp lists, so prepending the AVP to the list means prepending it in the message, which is not what the RFC requires. Appending to a list isn't ideal, but right now there's no better way.
* | | | | | | | Merge branch 'maint'Kenneth Lundin2017-09-181-1/+1
|\ \ \ \ \ \ \ \ | |/ / / / / / /
| * | | | | | | Merge branch 'kenneth/erl_docgen_dtdfix' into maintKenneth Lundin2017-09-181-1/+1
| |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * kenneth/erl_docgen_dtdfix: Allow <chapter> without <section> in chapter dtd
| | * | | | | | | Allow <chapter> without <section> in chapter dtdKenneth Lundin2017-09-151-1/+1
| | | | | | | | |
* | | | | | | | | Merge pull request #1570 from Zorbash/typo-poolHans Bolinder2017-09-181-3/+3
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | Fix doc typos in pool module
| * | | | | | | | | Fix doc typos in pool moduleDimitris Zorbas2017-09-171-3/+3
| | | | | | | | | |
* | | | | | | | | | Merge branch 'maint'Siri Hansen2017-09-181-9/+24
|\ \ \ \ \ \ \ \ \ \ | | |/ / / / / / / / | |/| | | | | | | |
| * | | | | | | | | Merge branch 'siri/unicode-fixup' into maintSiri Hansen2017-09-181-9/+24
| |\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * siri/unicode-fixup: kernel: Don't call other modules from simple error logger
| | * | | | | | | | | kernel: Don't call other modules from simple error loggerSiri Hansen2017-09-141-9/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | error_logger implements a simple handler which is used when no other handler is active. This handler is used during system startup, when there is no guarantee that all modules are loaded and must therefore not use any other modules for the formatting. Commit 41b856a2cb270ef807beaa84afe1bb890de5f237 introduced a call to io_lib:printable_list/1, which is now removed.
* | | | | | | | | | | Merge branch 'maint'Dan Gudmundsson2017-09-1852-9644/+1060
|\ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: reltool: Remove export_all warning in tests et: Remove export_all warnings in test mnesia: Remove export_all in tests wx: Remove export_all in example code wx: test remove export_all wx: Update doc, OpenGL external links wx: Reduce Opengl docs
| * | | | | | | | | | Merge branch 'dgud/wx/decrease-opengl-docs' into maintDan Gudmundsson2017-09-1852-9644/+1060
| |\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * dgud/wx/decrease-opengl-docs: reltool: Remove export_all warning in tests et: Remove export_all warnings in test mnesia: Remove export_all in tests wx: Remove export_all in example code wx: test remove export_all wx: Update doc, OpenGL external links wx: Reduce Opengl docs
| | * | | | | | | | | | reltool: Remove export_all warning in testsDan Gudmundsson2017-09-156-10/+6
| | | | | | | | | | | |
| | * | | | | | | | | | et: Remove export_all warnings in testDan Gudmundsson2017-09-152-2/+2
| | | | | | | | | | | |
| | * | | | | | | | | | mnesia: Remove export_all in testsDan Gudmundsson2017-09-1523-145/+490
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Cleanup warnings
| | * | | | | | | | | | wx: Remove export_all in example codeDan Gudmundsson2017-09-148-59/+10
| | | | | | | | | | | |
| | * | | | | | | | | | wx: test remove export_allDan Gudmundsson2017-09-149-44/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove unnecessary warnings
| | * | | | | | | | | | wx: Update doc, OpenGL external linksDan Gudmundsson2017-09-143-492/+502
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | They have moved from opengl.org to www.khronos.org
| | * | | | | | | | | | wx: Reduce Opengl docsDan Gudmundsson2017-09-143-8891/+9
| | |/ / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Only use the first paragraph in the doc which contains an overview, the result of the more detailed doc generated non valid xml, and all math expressions was rendered poorly. Remove for now.
* | | | | | | | | | | Merge branch 'maint'Raimo Niskanen2017-09-186-25/+371
|\ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / /
| * | | | | | | | | | Merge branch ↵Raimo Niskanen2017-09-186-25/+371
| |\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 'raimo/snmp/compile-LLDP-MIB-use-before-define/ERL-375/OTP-13014' into maint * raimo/snmp/compile-LLDP-MIB-use-before-define/ERL-375/OTP-13014: Process augments in pass after definitions