Quanta v0.2

 

Changes in Quanta since the release of Quanta v0.1(dated August 2002)

Changes were made to the following source files and header files.

Source files:

QUANTAdb_c.cxx
QUANTAdb_sharedState_c.cxx
QUANTAinit.cxx
QUANTAnet_extendedParallelTcp_c.cxx
QUANTAnet_extendedTcp_c.cxx

QUANTAnet_http_c.cxx
QUANTAnet_mcast_c.cxx
QUANTAnet_parallelTcp_c.cxx
QUANTAnet_perfClient_c.cxx
QUANTAnet_perfMonitor_c.cxx
QUANTAnet_rbudpSender_c.cxx
QUANTAnet_rbudpReceiver_c.cxx
QUANTAnet_remoteFileIO32_c.cxx
QUANTAnet_remoteFileIO64_c.cxx
QUANTAnet_remoteParallelFileIO32_c.cxx
QUANTAnet_remoteParallelFileIO64_c.cxx

QUANTAnet_rpc_c.cxx
QUANTAnet_socketbase_c.cxx
QUANTAnet_udp_c.cxx
QUANTAnet_udpReflector_c.cxx
QUANTAts_thread_c.cxx
keytool.cxx


1. Changes made to QUANTAdb_c :
  • Eliminated memory leak in QUANTAdb_client_c::blockingFetch(). Memory used for sending the fetch request will be deleted before the process loop begins. Previously, the process loop would often return, thus the memory for request was never deleted.
  • Used delete[] operator to correctly free rawdata in QUANTAdb_client_c::handleFetchReply() and QUANTAdb_client::handleIncomingPut().
  • Made QUANTAdb_client_c::blockingFetch() return OK after all other conditions have been met.
  • Changed QUANTAdb_client_c::init() to return OK if the servername was NULL. The client will continue to use a local db.

2. Changes made to QUANTAdb_sharedState_c :

  • Removed iostream.h header. Errors now use fprintf to stderr.
  • packAndSendState() and unpackState() are no longer pure virtual functions. They remain virtual, but they have empty implementations. This change removes the requirement that subclasses must redfine all virtual functions. unpackState() also has a size argument indicating the size in bytes of the buffer which must be unpacked.
  • The database path and key name are not delete[ ]'d on an incoming put, as that cleanup is done by the client. The solves a double-malloc error. However delete[ ] is called on the data that is obtained from client->get(). Previously, the standard delete was called, but this did not properly release the memory.

3. Changes made to QUANTAinit, QUANTAnet_extendedParallelTcp and QUANTAnet_extendedTcp_c :

  • Moved headers not present on Win32 systems and included the appropriate counterpart if needed.

4. Changes made to QUANTAnet_http_c :

  • Removed class-specific getSelfIP() functions. Replaced calls to use the newer QUANTAnet_socketbase_c::getSelfIP() implementations.
  • Added implementations for QUANTAnet_http_c::setRemoteSite(), QUANTAnet_http_c::setRemotePath(), QUANTAnet_http_c::setRemoteFile(), QUANTAnet_http_c::setLocalPath(), and QUANTAnet_http_c::setLocalFile().

5. Changes made to QUANTAnet_mcast_c :

  • Removed class-specific getSelfIP() functions. Replaced calls to use the newer QUANTAnet_socketbase_c::getSelfIP() implementations.
  • Added implementation for QUANTAnet_mcast_c::close().
  • Moved headers not present on Win32 systems and included the appropriate counterpart if needed.

6. Changes made to QUANTAnet_parallelTcp_c :

  • Removed class-specific getSelfIP() functions. Replaced calls to use the newer QUANTAnet_socketbase_c::getSelfIP() implementations.
  • Added implementations for QUANTAnet_parallelTcpServer_c destructor and QUANTAnet_parallelTcpServer_c::close().

7. Changes made to QUANTAnet_perfClient_c :

  • Removed class-specific getSelfIP() functions. Replaced calls to use the newer QUANTAnet_socketbase_c::getSelfIP() implementations.
  • Added declaration for errno if it has not been defined after including headers.

8. Changes made to QUANTAnet_perfMonitor_c :

  • Declared _DEFAULT_PERF_BUFFER_SIZE and _STREAM_INFO_SIZE as constants for use in memory allocation.

9. Changes made to QUANTAnet_rbudpSender_c :

  • Changed some assignments to first use reinterpret_cast<char*>() for gcc 3.1 compatibility.

10. Changes made to QUANTAnet_rbudpReceiver_c :

  • Renamed MAX macro to QMAX, as MAX is a common name already defined in system header files.
  • Changed some assignments to first use reinterpret_cast<char*>() for gcc 3.1 compatibility.

11. Changes made to QUANTAnet_remoteFileIO32_c, QUANTAnet_remoteFileIO64_c, QUANTAnet_remoteParallelIO32_c and QUANTAnet_remoteParallelIO64_c :

  • Removed class-specific getSelfIP() functions. Replaced calls to use the newer QUANTAnet_socketbase_c::getSelfIP() implementations.
  • Moved headers not present on Win32 systems and included the appropriate counterpart if needed.

12. Changes made to QUANTAnet_rpc_c :

  • Removed class-specific getSelfIP() functions. Replaced calls to use the newer QUANTAnet_socketbase_c::getSelfIP() implementations.

13. Changes made to QUANTAnet_socketbase_c :

  • Implemented static getSelfIP() member functions.
  • Moved headers not present on Win32 systems and included the appropriate counterpart if needed.

14. Changes made to QUANTAnet_udp_c.cxx :

  • Removed class-specific getSelfIP() functions. Replaced calls to use the newer QUANTAnet_socketbase_c::getSelfIP() implementations.
  • Added implementation for QUANTAnet_udp_c::close().
  • Moved headers not present on Win32 systems and included the appropriate counterpart if needed.

15. Changes made to QUANTAnet_udpReflector_c :

  • Updated QUANTAnet_udpReflector_c.cxx to spawn off threads to handle the udp reflection and multicast bridging.
  • Added return values for process() and processMCAST() to fix errors compiling on Win32. Added explicit use of 'this' when calling members in processMCAST()

16. Changes made to QUANTAts_thread_c :

  • Added stdio.h since it was required with the removal of the QUANTA.hxx file from the QUANTAts_thread_c header.
  • Updated thread class for dynamic binding via run().
  • Added member functions join and detach (pthread only).
  • Moved headers not present on Win32 systems and included the appropriate counterpart if needed.

17. Changes made to keytool :

  • Added implementation for keyEntity_c constructor.
  • Changed usleep() and sleep() calls to QUANTAsleep().
  • Moved headers not present on Win32 systems and included the appropriate counterpart if needed.

Header files:

QUANTAdb_c.hxx
QUANTAdb_sharedState_c.hxx
QUANTAmisc_hashDict.hxx
QUANTAnet_extendedTcp_c.hxx
QUANTAnet_http_c.hxx
QUANTAnet_mcast_c.hxx
QUANTAnet_parallelTcp_c.cxx
QUANTAnet_perfClient_c.hxx
QUANTAnet_perfMonitor_c.hxx
QUANTAnet_rbudpBase_c.hxx
QUANTAnet_remoteFileIO32_c.hxx
QUANTAnet_remoteFileIO64_c.hxx

QUANTAnet_remoteParallelFileIO32_c.hxx
QUANTAnet_remoteParallelFileIO64_c.hxx
QUANTAnet_socketbase_c.hxx
QUANTAnet_tcpReflector_c.hxx
QUANTAnet_tcp_c.hxx
QUANTAnet_udp_c.hxx
QUANTAnet_udpReflector_c.hxx
QUANTAts_thread_c.hxx
QUANTAts_mutex_c.hxx
keytool.hxx

1. Changes made to QUANTAdb_c.hxx :

  • Added forward declarations for QUANTAnet_tcpReflectorClient_c, QUANTAnet_tcpReflector_c, QUANTAnet_udpReflector_c, QUANTAnet_udp_c, QUANTAts_mutex_c, and keyToolManager_c and removed a few includes.

2. Changes made to QUANTAdb_sharedState_c.hxx :

  • Removed QUANTA.hxx from the headers using it. Required headers have been placed into the files accordingly.
  • packAndSendState() and unpackState() are no longer pure virtual functions. They remain virtual, but they have empty implementations. This change removes the requirement that subclasses must redefine all virtual functions. unpackState() also has a size argument indicating the size in bytes of the buffer which must be unpacked.

3. Changes made to QUANTAmisc_hashDict.hxx :

  • Preprocessor checks ensure that either QUANTA_THREAD_SAFE or NO_THREAD is defined, otherwise an error is generated.

4. Changes made to QUANTAnet_extendedTcp_c.hxx :

  • Added virtual destructor for QUANTAnet_extendedTcpServer_c.

5. Changes made to QUANTAnet_http_c.hxx :

  • Removed implementations for QUANTAnet_http_c::setRemoteSite(), QUANTAnet_http_c::setRemotePath(), QUANTAnet_http_c::setRemoteFile(), QUANTAnet_http_c::setLocalPath(), and QUANTAnet_http_c::setLocalFile().

6. Changes made to QUANTAnet_mcast_c.hxx :

  • Removed class getSelfIP() methods.
  • Removed QUANTAnet_mcast_c::close() implementation from the header.
  • Removed extern declarations of errno.

7. Changes made to QUANTAnet_parallelTcp_c.hxx :

  • Declared QUANTAnet_parallelTcpClient_c and QUANTAnet_parallelTcpServer_c destructors as virtual.
  • Removed class getSelfIP() methods.
  • Removed QUANTAnet_parallelTcpServer_c destructor and QUANTAnet_parallelTcpServer_c::close() implementations from the header.
  • Changed member ordering to match initializer use in the constructor. Using initializers requires that their order matches the order withing the class declaration.

8. Changes made to QUANTAnet_perfClient_c.hxx :

  • Removed class getSelfIP() methods.

9. Changes made to QUANTAnet_perfMonitor_c.hxx :

  • Removed #defines for DEFAULT_BUFFER_SIZE and _STREAM_INFO_SIZE since
    (a) they should be defined in the implementation files and
    (b) the first value conflicts with a define set in the tcp header.
  • Declared QUANTAnet_perfMonitor_c destructor as virtual.

10. Changes made to QUANTAnet_rbudpBase_c.hxx :

  • Removed system specific socklen_t check and moved socklen_t check to global header.

11. Changes made to QUANTAnet_remoteFileIO32_c.hxx, QUANTAnet_remoteFileIO64_c.hxx and QUANTAnet_remoteParallelFileIO64_c.hxx :

  • Removed QUANTA.hxx from the headers using it. Required headers have been placed into the files accordingly.

12. Changes made to QUANTAnet_remoteParallelFileIO32_c.hxx :

  • Removed implementation for QUANTAnet_remoteParallelFileIOServer32_c::setNeighborServer().
  • Removed QUANTA.hxx from the headers using it. Required headers have been placed into the files accordingly.

13. Changed made to QUANTAnet_socketbase_c.hxx :

  • Added static long getSelfIP() and static void getSelfIP(char*) member functions.
  • Removed numerous headers needlessly included. Added include guards around the required arpa/inet.h and netint/in.h headers.

14. Changes made to QUANTAnet_tcpReflector_c.hxx :

  • Removed class getSelfIP() methods.
  • Added forward declarations for QUANTAnet_tcpClient_c and QUANTAnet_tcpServer_c.

15. Changes made to QUANTAnet_tcp_c.hxx :

  • Removed class getSelfIP() methods.
  • Declared QUANTAnet_tcpClient_c and QUANTAnet_tcpServer_c destructors as virtual.

16. Changes made to QUANTAnet_udp_c.hxx :

  • Removed class getSelfIP() methods.
  • Added virtual destructor for QUANTAnet_udp_c.
  • Removed QUANTAnet_udp_c::close() implementation from the header.

17. Changes made to QUANTAnet_udpReflector_c.hxx :

  • Updated QUANTAnet_udpReflector_c.hxx to spawn off threads to handle the udp reflection and multicast bridging.
  • Declared QUANTAnet_udpReflector_c destructor as virtual.

18. Changes made to QUANTAts_thread_c.hxx :

  • Removed QUANTA.hxx from the headers using it. Required headers have been placed into the files accordingly.
  • Modified thread header for dynamic binding interface via run().

19. Changes made to QUANTAts_mutex_c.hxx :

  • Added __HAVE_WINSOCK_H include guard for winsock.h.

20. Changes made to keytool.hxx :

  • Changed preprocessor checking for defining macros. This will create an error message is neither QUANTA_THREAD_SAFE nor NO_THREADS are defined.