You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@avro.apache.org by "ASF GitHub Bot (Jira)" <ji...@apache.org> on 2023/05/11 07:19:00 UTC
[jira] [Updated] (AVRO-3758) [Rust] Use AtomicXyz types instead of static mutable ones
[ https://issues.apache.org/jira/browse/AVRO-3758?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
ASF GitHub Bot updated AVRO-3758:
---------------------------------
Labels: pull-request-available (was: )
> [Rust] Use AtomicXyz types instead of static mutable ones
> ---------------------------------------------------------
>
> Key: AVRO-3758
> URL: https://issues.apache.org/jira/browse/AVRO-3758
> Project: Apache Avro
> Issue Type: Improvement
> Components: rust
> Reporter: Martin Tzvetanov Grigorov
> Assignee: Martin Tzvetanov Grigorov
> Priority: Major
> Labels: pull-request-available
> Time Spent: 10m
> Remaining Estimate: 0h
>
> apache_avro::util uses "static mut" for MAX_ALLOCATION_BYTES and SERDE_HUMAN_READABLE. Because of this it has to use "unsafe {}" blocks to update their values.
>
> It would be cleaner to use AtomicBool/AtomicUsize instead and get rid of the unsafe blocks.
>
> Suggested at https://github.com/apache/avro/pull/2202#issuecomment-1542887124
--
This message was sent by Atlassian Jira
(v8.20.10#820010)