[ 
https://issues.apache.org/jira/browse/MINIFI-249?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16056639#comment-16056639
 ] 

ASF GitHub Bot commented on MINIFI-249:
---------------------------------------

Github user phrocker commented on a diff in the pull request:

    https://github.com/apache/nifi-minifi-cpp/pull/110#discussion_r123119025
  
    --- Diff: libminifi/include/core/repository/VolatileRepository.h ---
    @@ -331,22 +132,240 @@ class VolatileRepository : public core::Repository, 
public std::enable_shared_fr
         else
           return false;
       }
    -  /**
    -   * Purges the volatile repository.
    -   */
    -  void purge();
     
    - private:
       std::map<std::string, std::shared_ptr<minifi::Connection>> connectionMap;
    -
    -  std::atomic<uint32_t> current_size_;
    +  // current size of the volatile repo.
    +  std::atomic<size_t> current_size_;
    +  // current index.
       std::atomic<uint16_t> current_index_;
    -  std::vector<AtomicEntry*> value_vector_;
    +  // value vector.
    --- End diff --
    
    This is a base class. the super class MAY use a map in certain use cases. 
see https://github.com/apache/nifi-minifi-cpp/pull/113 for when the minimized 
locking is used. the vector here has the ability to be completely lock free for 
certain use cases. the computational complexity is pretty low versus the 
locking required. value_vector_ exists for the repositories that want complete 
lock free operations via CAS


> Volatile Provenance Repository
> ------------------------------
>
>                 Key: MINIFI-249
>                 URL: https://issues.apache.org/jira/browse/MINIFI-249
>             Project: Apache NiFi MiNiFi
>          Issue Type: New Feature
>          Components: C++, Core Framework
>            Reporter: Aldrin Piri
>            Assignee: marco polo
>
> It would be helpful to have a volatile implementation for handling 
> provenance.  While the data guarantees of capturing/storing information work 
> in some scenarios, in others, folks may wish to just hold data while the 
> instance is running.  This is predicated on an extensible interface that 
> supports this configurability.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to