source: XIOS/trunk/src/context_client.hpp @ 509

Last change on this file since 509 was 509, checked in by mhnguyen, 9 years ago

Implementing buffer size auto-detection for mode client -server

+) Process xml tree in client side then send all the information to server
+) Only information enabled fields in enabled files are sent to server
+) Some important change in structure of code which must be refactored

Test
+) On Curie
+) Only mode client-server
+) Passed for all tests

  • Property copyright set to
    Software name : XIOS (Xml I/O Server)
    http://forge.ipsl.jussieu.fr/ioserver
    Creation date : January 2009
    Licence : CeCCIL version2
    see license file in root directory : Licence_CeCILL_V2-en.txt
    or http://www.cecill.info/licences/Licence_CeCILL_V2-en.html
    Holder : CEA/LSCE (Laboratoire des Sciences du CLimat et de l'Environnement)
    CNRS/IPSL (Institut Pierre Simon Laplace)
    Project Manager : Yann Meurdesoif
    yann.meurdesoif@cea.fr
File size: 1.3 KB
Line 
1#ifndef __CONTEXT_CLIENT_HPP__
2#define __CONTEXT_CLIENT_HPP__
3
4#include "xmlioserver_spl.hpp"
5#include "buffer_out.hpp"
6#include "buffer_client.hpp"
7#include "event_client.hpp"
8#include "mpi.hpp"
9
10namespace xios
11{
12  class CContext ;
13
14  class CContextClient
15  {
16
17    public:
18    CContextClient(CContext* parent,MPI_Comm intraComm, MPI_Comm interComm) ;
19//    void registerEvent(CEventClient& event) ;
20
21//    list<CBufferOut*> newEvent(CEventClient& event,list<int>& sizes) ;
22    void sendEvent(CEventClient& event) ;
23
24    list<CBufferOut*> getBuffers(list<int>& serverlist, list<int>& sizeList) ;
25    void newBuffer(int rank) ;
26    size_t timeLine ;
27    int clientRank ;
28    int clientSize ;
29    int serverSize ;
30//    set<int> connectedServer ;
31    MPI_Comm interComm ;
32    MPI_Comm intraComm ;
33    map<int,CClientBuffer*> buffers ;
34    bool checkBuffers(list<int>& ranks) ;
35    bool checkBuffers(void);
36    void releaseBuffers(void);
37    void closeContext(void) ;
38    bool isServerLeader(void) ;
39    int getServerLeader(void) ;
40    void finalize(void) ;
41    void waitEvent(list<int>& ranks) ;
42
43    void setBufferSize(const std::map<int, StdSize>& mapSize);
44    void sendBufferSizeEvent();
45
46    CContext* context ;
47
48    private:
49    std::map<int, StdSize> mapBufferSize_;
50//    bool locked ;
51
52  } ;
53
54
55
56
57}
58
59
60
61#endif
Note: See TracBrowser for help on using the repository browser.