Explorar el Código

对接Netty后端

lishengyin hace 3 años
padre
commit
d48fad9191

BIN
build/CMakeFiles/main.dir/source/src/main.cpp.o


+ 8 - 2
build/CMakeFiles/main.dir/source/src/main.cpp.o.d

@@ -1052,6 +1052,13 @@ CMakeFiles/main.dir/source/src/main.cpp.o: \
  /usr/include/boost/variant/bad_visit.hpp \
  /home/nvidia/work/MIVA/modules/dataType/include/ApiSyncData.h \
  /home/nvidia/work/MIVA/modules/dataType/include/ApiResult.h \
+ /home/nvidia/work/MIVA/modules/HttpClient/include/HttpClient.h \
+ /home/nvidia/work/MIVA/modules/md5/include/md5.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpResultMsg.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpToken.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpNull.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpCarInfo.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpTrainInfo.h \
  /usr/local/include/httplib.h /usr/include/ifaddrs.h \
  /usr/include/resolv.h /usr/include/aarch64-linux-gnu/sys/param.h \
  /usr/include/aarch64-linux-gnu/bits/param.h /usr/include/linux/param.h \
@@ -1088,5 +1095,4 @@ CMakeFiles/main.dir/source/src/main.cpp.o: \
  /usr/include/c++/7/bits/regex.h /usr/include/c++/7/bits/regex.tcc \
  /usr/include/c++/7/bits/regex_executor.h \
  /usr/include/c++/7/bits/regex_executor.tcc \
- /usr/include/aarch64-linux-gnu/sys/stat.h \
- /home/nvidia/work/MIVA/modules/md5/include/md5.h
+ /usr/include/aarch64-linux-gnu/sys/stat.h

BIN
build/modules/CMakeFiles/modules.dir/HttpClient/src/HttpClient.cpp.o


+ 157 - 145
build/modules/CMakeFiles/modules.dir/HttpClient/src/HttpClient.cpp.o.d

@@ -137,163 +137,63 @@ modules/CMakeFiles/modules.dir/HttpClient/src/HttpClient.cpp.o: \
  /usr/include/c++/7/bits/locale_facets.tcc \
  /usr/include/c++/7/bits/basic_ios.tcc \
  /usr/include/c++/7/bits/ostream.tcc /usr/include/c++/7/istream \
- /usr/include/c++/7/bits/istream.tcc /usr/local/include/httplib.h \
- /usr/include/arpa/inet.h /usr/include/netinet/in.h \
- /usr/include/aarch64-linux-gnu/sys/socket.h \
- /usr/include/aarch64-linux-gnu/bits/types/struct_iovec.h \
- /usr/include/aarch64-linux-gnu/bits/socket.h \
- /usr/include/aarch64-linux-gnu/bits/socket_type.h \
- /usr/include/aarch64-linux-gnu/bits/sockaddr.h \
- /usr/include/aarch64-linux-gnu/asm/socket.h \
- /usr/include/asm-generic/socket.h \
- /usr/include/aarch64-linux-gnu/asm/sockios.h \
- /usr/include/asm-generic/sockios.h \
- /usr/include/aarch64-linux-gnu/bits/types/struct_osockaddr.h \
- /usr/include/aarch64-linux-gnu/bits/socket2.h \
- /usr/include/aarch64-linux-gnu/bits/in.h /usr/include/c++/7/cstring \
+ /usr/include/c++/7/bits/istream.tcc /usr/include/c++/7/ctime \
+ /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Util/logger.h \
  /usr/include/string.h /usr/include/strings.h \
  /usr/include/aarch64-linux-gnu/bits/strings_fortified.h \
  /usr/include/aarch64-linux-gnu/bits/string_fortified.h \
- /usr/include/ifaddrs.h /usr/include/netdb.h /usr/include/rpc/netdb.h \
- /usr/include/aarch64-linux-gnu/bits/types/sigevent_t.h \
- /usr/include/aarch64-linux-gnu/bits/types/__sigval_t.h \
- /usr/include/aarch64-linux-gnu/bits/netdb.h /usr/include/resolv.h \
- /usr/include/aarch64-linux-gnu/sys/param.h \
- /usr/lib/gcc/aarch64-linux-gnu/7/include-fixed/limits.h \
- /usr/lib/gcc/aarch64-linux-gnu/7/include-fixed/syslimits.h \
- /usr/include/limits.h /usr/include/aarch64-linux-gnu/bits/posix1_lim.h \
- /usr/include/aarch64-linux-gnu/bits/local_lim.h \
- /usr/include/linux/limits.h \
- /usr/include/aarch64-linux-gnu/bits/posix2_lim.h \
- /usr/include/aarch64-linux-gnu/bits/xopen_lim.h \
- /usr/include/aarch64-linux-gnu/bits/uio_lim.h /usr/include/signal.h \
- /usr/include/aarch64-linux-gnu/bits/signum.h \
- /usr/include/aarch64-linux-gnu/bits/signum-generic.h \
- /usr/include/aarch64-linux-gnu/bits/types/sig_atomic_t.h \
- /usr/include/aarch64-linux-gnu/bits/types/siginfo_t.h \
- /usr/include/aarch64-linux-gnu/bits/siginfo-arch.h \
- /usr/include/aarch64-linux-gnu/bits/siginfo-consts.h \
- /usr/include/aarch64-linux-gnu/bits/siginfo-consts-arch.h \
- /usr/include/aarch64-linux-gnu/bits/types/sigval_t.h \
- /usr/include/aarch64-linux-gnu/bits/sigevent-consts.h \
- /usr/include/aarch64-linux-gnu/bits/sigaction.h \
- /usr/include/aarch64-linux-gnu/bits/sigcontext.h \
- /usr/include/aarch64-linux-gnu/asm/sigcontext.h \
- /usr/include/linux/types.h /usr/include/aarch64-linux-gnu/asm/types.h \
- /usr/include/asm-generic/types.h /usr/include/asm-generic/int-ll64.h \
- /usr/include/aarch64-linux-gnu/asm/bitsperlong.h \
- /usr/include/asm-generic/bitsperlong.h /usr/include/linux/posix_types.h \
- /usr/include/linux/stddef.h \
- /usr/include/aarch64-linux-gnu/asm/posix_types.h \
- /usr/include/asm-generic/posix_types.h \
- /usr/include/aarch64-linux-gnu/bits/types/stack_t.h \
- /usr/include/aarch64-linux-gnu/sys/ucontext.h \
- /usr/include/aarch64-linux-gnu/sys/procfs.h \
- /usr/include/aarch64-linux-gnu/sys/time.h \
- /usr/include/aarch64-linux-gnu/sys/user.h \
- /usr/include/aarch64-linux-gnu/bits/sigstack.h \
- /usr/include/aarch64-linux-gnu/bits/ss_flags.h \
- /usr/include/aarch64-linux-gnu/bits/types/struct_sigstack.h \
- /usr/include/aarch64-linux-gnu/bits/sigthread.h \
- /usr/include/aarch64-linux-gnu/bits/param.h /usr/include/linux/param.h \
- /usr/include/aarch64-linux-gnu/asm/param.h \
- /usr/include/asm-generic/param.h /usr/include/arpa/nameser.h \
- /usr/include/arpa/nameser_compat.h \
- /usr/include/aarch64-linux-gnu/bits/types/res_state.h \
- /usr/include/netinet/tcp.h /usr/include/c++/7/csignal \
- /usr/include/unistd.h /usr/include/aarch64-linux-gnu/bits/posix_opt.h \
- /usr/include/aarch64-linux-gnu/bits/environments.h \
- /usr/include/aarch64-linux-gnu/bits/confname.h \
- /usr/include/aarch64-linux-gnu/bits/getopt_posix.h \
- /usr/include/aarch64-linux-gnu/bits/getopt_core.h \
- /usr/include/aarch64-linux-gnu/bits/unistd.h \
- /usr/include/c++/7/algorithm /usr/include/c++/7/utility \
- /usr/include/c++/7/bits/stl_relops.h /usr/include/c++/7/bits/stl_algo.h \
- /usr/include/c++/7/bits/algorithmfwd.h \
- /usr/include/c++/7/bits/stl_heap.h /usr/include/c++/7/bits/stl_tempbuf.h \
- /usr/include/c++/7/bits/stl_construct.h \
- /usr/include/c++/7/bits/uniform_int_dist.h /usr/include/c++/7/limits \
- /usr/include/c++/7/array /usr/include/c++/7/atomic \
- /usr/include/c++/7/bits/atomic_base.h \
- /usr/include/c++/7/bits/atomic_lockfree_defines.h \
- /usr/include/c++/7/cassert /usr/include/assert.h \
- /usr/include/c++/7/climits /usr/include/c++/7/condition_variable \
- /usr/include/c++/7/chrono /usr/include/c++/7/ratio \
- /usr/include/c++/7/ctime /usr/include/c++/7/bits/parse_numbers.h \
- /usr/include/c++/7/bits/std_mutex.h /usr/include/c++/7/ext/concurrence.h \
- /usr/include/c++/7/bits/unique_ptr.h /usr/include/c++/7/tuple \
+ /usr/include/c++/7/set /usr/include/c++/7/bits/stl_tree.h \
+ /usr/include/c++/7/ext/aligned_buffer.h \
+ /usr/include/c++/7/bits/stl_set.h /usr/include/c++/7/bits/stl_multiset.h \
+ /usr/include/c++/7/map /usr/include/c++/7/bits/stl_map.h \
+ /usr/include/c++/7/tuple /usr/include/c++/7/utility \
+ /usr/include/c++/7/bits/stl_relops.h /usr/include/c++/7/array \
  /usr/include/c++/7/bits/uses_allocator.h \
- /usr/include/c++/7/bits/invoke.h /usr/include/c++/7/bits/shared_ptr.h \
- /usr/include/c++/7/bits/shared_ptr_base.h \
- /usr/include/c++/7/bits/allocated_ptr.h \
- /usr/include/c++/7/bits/refwrap.h \
- /usr/include/c++/7/ext/aligned_buffer.h /usr/include/fcntl.h \
- /usr/include/aarch64-linux-gnu/bits/fcntl.h \
- /usr/include/aarch64-linux-gnu/bits/fcntl-linux.h \
- /usr/include/linux/falloc.h /usr/include/aarch64-linux-gnu/bits/stat.h \
- /usr/include/aarch64-linux-gnu/bits/fcntl2.h /usr/include/c++/7/fstream \
- /usr/include/c++/7/bits/codecvt.h \
+ /usr/include/c++/7/bits/invoke.h /usr/include/c++/7/bits/stl_multimap.h \
+ /usr/include/c++/7/deque /usr/include/c++/7/bits/stl_construct.h \
+ /usr/include/c++/7/bits/stl_uninitialized.h \
+ /usr/include/c++/7/bits/stl_deque.h /usr/include/c++/7/bits/deque.tcc \
+ /usr/include/c++/7/fstream /usr/include/c++/7/bits/codecvt.h \
  /usr/include/aarch64-linux-gnu/c++/7/bits/basic_file.h \
  /usr/include/aarch64-linux-gnu/c++/7/bits/c++io.h \
- /usr/include/c++/7/bits/fstream.tcc /usr/include/c++/7/functional \
- /usr/include/c++/7/bits/std_function.h /usr/include/c++/7/iomanip \
- /usr/include/c++/7/locale /usr/include/c++/7/bits/locale_facets_nonio.h \
- /usr/include/aarch64-linux-gnu/c++/7/bits/time_members.h \
- /usr/include/aarch64-linux-gnu/c++/7/bits/messages_members.h \
- /usr/include/libintl.h /usr/include/c++/7/bits/locale_facets_nonio.tcc \
- /usr/include/c++/7/bits/locale_conv.h \
- /usr/include/c++/7/bits/stringfwd.h /usr/include/c++/7/bits/allocator.h \
- /usr/include/c++/7/bits/codecvt.h /usr/include/c++/7/bits/unique_ptr.h \
- /usr/include/c++/7/list /usr/include/c++/7/bits/stl_list.h \
- /usr/include/c++/7/bits/list.tcc /usr/include/c++/7/map \
- /usr/include/c++/7/bits/stl_tree.h /usr/include/c++/7/bits/stl_map.h \
- /usr/include/c++/7/bits/stl_multimap.h /usr/include/c++/7/memory \
- /usr/include/c++/7/bits/stl_uninitialized.h \
+ /usr/include/c++/7/bits/fstream.tcc /usr/include/c++/7/sstream \
+ /usr/include/c++/7/bits/sstream.tcc /usr/include/c++/7/thread \
+ /usr/include/c++/7/chrono /usr/include/c++/7/ratio \
+ /usr/include/c++/7/limits /usr/include/c++/7/bits/parse_numbers.h \
+ /usr/include/c++/7/memory /usr/include/c++/7/bits/stl_tempbuf.h \
  /usr/include/c++/7/bits/stl_raw_storage_iter.h \
+ /usr/include/c++/7/ext/concurrence.h \
+ /usr/include/c++/7/bits/unique_ptr.h \
+ /usr/include/c++/7/bits/shared_ptr.h \
+ /usr/include/c++/7/bits/shared_ptr_base.h \
+ /usr/include/c++/7/bits/allocated_ptr.h \
+ /usr/include/c++/7/bits/refwrap.h \
  /usr/include/c++/7/bits/shared_ptr_atomic.h \
+ /usr/include/c++/7/bits/atomic_base.h \
+ /usr/include/c++/7/bits/atomic_lockfree_defines.h \
  /usr/include/c++/7/backward/auto_ptr.h /usr/include/c++/7/mutex \
- /usr/include/c++/7/random /usr/include/c++/7/cmath /usr/include/math.h \
- /usr/include/aarch64-linux-gnu/bits/math-vector.h \
- /usr/include/aarch64-linux-gnu/bits/libm-simd-decl-stubs.h \
- /usr/include/aarch64-linux-gnu/bits/flt-eval-method.h \
- /usr/include/aarch64-linux-gnu/bits/fp-logb.h \
- /usr/include/aarch64-linux-gnu/bits/fp-fast.h \
- /usr/include/aarch64-linux-gnu/bits/mathcalls-helper-functions.h \
- /usr/include/aarch64-linux-gnu/bits/mathcalls.h \
- /usr/include/aarch64-linux-gnu/bits/iscanonical.h \
- /usr/include/aarch64-linux-gnu/bits/mathinline.h \
- /usr/include/c++/7/bits/random.h /usr/include/c++/7/vector \
- /usr/include/c++/7/bits/stl_vector.h \
- /usr/include/c++/7/bits/stl_bvector.h /usr/include/c++/7/bits/vector.tcc \
- /usr/include/aarch64-linux-gnu/c++/7/bits/opt_random.h \
- /usr/include/c++/7/bits/random.tcc /usr/include/c++/7/numeric \
- /usr/include/c++/7/bits/stl_numeric.h /usr/include/c++/7/regex \
- /usr/include/c++/7/bitset /usr/include/c++/7/iterator \
- /usr/include/c++/7/bits/stream_iterator.h /usr/include/c++/7/sstream \
- /usr/include/c++/7/bits/sstream.tcc /usr/include/c++/7/stack \
- /usr/include/c++/7/deque /usr/include/c++/7/bits/stl_deque.h \
- /usr/include/c++/7/bits/deque.tcc /usr/include/c++/7/bits/stl_stack.h \
- /usr/include/c++/7/bits/regex_constants.h \
- /usr/include/c++/7/bits/regex_error.h \
- /usr/include/c++/7/bits/regex_automaton.h \
- /usr/include/c++/7/bits/regex_automaton.tcc \
- /usr/include/c++/7/bits/regex_scanner.h \
- /usr/include/c++/7/bits/regex_scanner.tcc \
- /usr/include/c++/7/bits/regex_compiler.h \
- /usr/include/c++/7/bits/regex_compiler.tcc \
- /usr/include/c++/7/bits/regex.h /usr/include/c++/7/bits/regex.tcc \
- /usr/include/c++/7/bits/regex_executor.h \
- /usr/include/c++/7/bits/regex_executor.tcc /usr/include/c++/7/set \
- /usr/include/c++/7/bits/stl_set.h /usr/include/c++/7/bits/stl_multiset.h \
- /usr/include/aarch64-linux-gnu/sys/stat.h /usr/include/c++/7/thread \
- /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Util/logger.h \
+ /usr/include/c++/7/bits/std_mutex.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Util/util.h \
- /usr/include/c++/7/unordered_map /usr/include/c++/7/bits/hashtable.h \
+ /usr/include/c++/7/vector /usr/include/c++/7/bits/stl_vector.h \
+ /usr/include/c++/7/bits/stl_bvector.h /usr/include/c++/7/bits/vector.tcc \
+ /usr/include/c++/7/atomic /usr/include/c++/7/unordered_map \
+ /usr/include/c++/7/bits/hashtable.h \
  /usr/include/c++/7/bits/hashtable_policy.h \
- /usr/include/c++/7/bits/unordered_map.h \
+ /usr/include/c++/7/bits/unordered_map.h /usr/include/unistd.h \
+ /usr/include/aarch64-linux-gnu/bits/posix_opt.h \
+ /usr/include/aarch64-linux-gnu/bits/environments.h \
+ /usr/include/aarch64-linux-gnu/bits/confname.h \
+ /usr/include/aarch64-linux-gnu/bits/getopt_posix.h \
+ /usr/include/aarch64-linux-gnu/bits/getopt_core.h \
+ /usr/include/aarch64-linux-gnu/bits/unistd.h \
+ /usr/include/aarch64-linux-gnu/sys/time.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Util/List.h \
+ /usr/include/c++/7/list /usr/include/c++/7/bits/stl_list.h \
+ /usr/include/c++/7/bits/list.tcc \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Thread/semaphore.h \
+ /usr/include/c++/7/condition_variable \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Util/NoticeCenter.h \
+ /usr/include/c++/7/functional /usr/include/c++/7/bits/std_function.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Util/function_traits.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Util/onceToken.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Poller/EventPoller.h \
@@ -301,6 +201,7 @@ modules/CMakeFiles/modules.dir/HttpClient/src/HttpClient.cpp.o: \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Thread/TaskExecutor.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Util/onceToken.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Util/TimeTicker.h \
+ /usr/include/assert.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Util/logger.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Thread/ThreadPool.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Thread/threadgroup.h \
@@ -312,6 +213,22 @@ modules/CMakeFiles/modules.dir/HttpClient/src/HttpClient.cpp.o: \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Util/ResourcePool.h \
  /usr/include/c++/7/unordered_set /usr/include/c++/7/bits/unordered_set.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Network/sockutil.h \
+ /usr/include/netdb.h /usr/include/netinet/in.h \
+ /usr/include/aarch64-linux-gnu/sys/socket.h \
+ /usr/include/aarch64-linux-gnu/bits/types/struct_iovec.h \
+ /usr/include/aarch64-linux-gnu/bits/socket.h \
+ /usr/include/aarch64-linux-gnu/bits/socket_type.h \
+ /usr/include/aarch64-linux-gnu/bits/sockaddr.h \
+ /usr/include/aarch64-linux-gnu/asm/socket.h \
+ /usr/include/asm-generic/socket.h \
+ /usr/include/aarch64-linux-gnu/asm/sockios.h \
+ /usr/include/asm-generic/sockios.h \
+ /usr/include/aarch64-linux-gnu/bits/types/struct_osockaddr.h \
+ /usr/include/aarch64-linux-gnu/bits/socket2.h \
+ /usr/include/aarch64-linux-gnu/bits/in.h /usr/include/rpc/netdb.h \
+ /usr/include/aarch64-linux-gnu/bits/types/sigevent_t.h \
+ /usr/include/aarch64-linux-gnu/bits/types/__sigval_t.h \
+ /usr/include/aarch64-linux-gnu/bits/netdb.h /usr/include/arpa/inet.h \
  /usr/include/aarch64-linux-gnu/sys/ioctl.h \
  /usr/include/aarch64-linux-gnu/bits/ioctls.h \
  /usr/include/aarch64-linux-gnu/asm/ioctls.h \
@@ -320,8 +237,16 @@ modules/CMakeFiles/modules.dir/HttpClient/src/HttpClient.cpp.o: \
  /usr/include/asm-generic/ioctl.h \
  /usr/include/aarch64-linux-gnu/bits/ioctl-types.h \
  /usr/include/aarch64-linux-gnu/sys/ttydefaults.h /usr/include/net/if.h \
- /usr/include/aarch64-linux-gnu/sys/uio.h \
+ /usr/include/netinet/tcp.h /usr/include/aarch64-linux-gnu/sys/uio.h \
+ /usr/include/aarch64-linux-gnu/bits/uio_lim.h \
  /usr/include/aarch64-linux-gnu/bits/uio-ext.h \
+ /usr/lib/gcc/aarch64-linux-gnu/7/include-fixed/limits.h \
+ /usr/lib/gcc/aarch64-linux-gnu/7/include-fixed/syslimits.h \
+ /usr/include/limits.h /usr/include/aarch64-linux-gnu/bits/posix1_lim.h \
+ /usr/include/aarch64-linux-gnu/bits/local_lim.h \
+ /usr/include/linux/limits.h \
+ /usr/include/aarch64-linux-gnu/bits/posix2_lim.h \
+ /usr/include/aarch64-linux-gnu/bits/xopen_lim.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/src/Player/PlayerProxy.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/src/Common/Device.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/src/Common/MultiMediaSourceMuxer.h \
@@ -334,6 +259,7 @@ modules/CMakeFiles/modules.dir/HttpClient/src/HttpClient.cpp.o: \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/src/Record/HlsMaker.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/src/Common/config.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Util/mini.h \
+ /usr/include/c++/7/cstring /usr/include/c++/7/cassert \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/src/Common/macros.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Util/File.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Util/util.h \
@@ -410,6 +336,33 @@ modules/CMakeFiles/modules.dir/HttpClient/src/HttpClient.cpp.o: \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Thread/WorkThreadPool.h \
  /home/nvidia/work/MIVA/3rdparty/ZLMediaKit/3rdpart/ZLToolKit/src/Thread/ThreadPool.h \
  /home/nvidia/work/MIVA/modules/TCPClient/include/TCPClient.h \
+ /usr/include/signal.h /usr/include/aarch64-linux-gnu/bits/signum.h \
+ /usr/include/aarch64-linux-gnu/bits/signum-generic.h \
+ /usr/include/aarch64-linux-gnu/bits/types/sig_atomic_t.h \
+ /usr/include/aarch64-linux-gnu/bits/types/siginfo_t.h \
+ /usr/include/aarch64-linux-gnu/bits/siginfo-arch.h \
+ /usr/include/aarch64-linux-gnu/bits/siginfo-consts.h \
+ /usr/include/aarch64-linux-gnu/bits/siginfo-consts-arch.h \
+ /usr/include/aarch64-linux-gnu/bits/types/sigval_t.h \
+ /usr/include/aarch64-linux-gnu/bits/sigevent-consts.h \
+ /usr/include/aarch64-linux-gnu/bits/sigaction.h \
+ /usr/include/aarch64-linux-gnu/bits/sigcontext.h \
+ /usr/include/aarch64-linux-gnu/asm/sigcontext.h \
+ /usr/include/linux/types.h /usr/include/aarch64-linux-gnu/asm/types.h \
+ /usr/include/asm-generic/types.h /usr/include/asm-generic/int-ll64.h \
+ /usr/include/aarch64-linux-gnu/asm/bitsperlong.h \
+ /usr/include/asm-generic/bitsperlong.h /usr/include/linux/posix_types.h \
+ /usr/include/linux/stddef.h \
+ /usr/include/aarch64-linux-gnu/asm/posix_types.h \
+ /usr/include/asm-generic/posix_types.h \
+ /usr/include/aarch64-linux-gnu/bits/types/stack_t.h \
+ /usr/include/aarch64-linux-gnu/sys/ucontext.h \
+ /usr/include/aarch64-linux-gnu/sys/procfs.h \
+ /usr/include/aarch64-linux-gnu/sys/user.h \
+ /usr/include/aarch64-linux-gnu/bits/sigstack.h \
+ /usr/include/aarch64-linux-gnu/bits/ss_flags.h \
+ /usr/include/aarch64-linux-gnu/bits/types/struct_sigstack.h \
+ /usr/include/aarch64-linux-gnu/bits/sigthread.h \
  /home/nvidia/work/MIVA/modules/dataType/include/Notices.h \
  /home/nvidia/work/MIVA/modules/dataType/include/SendLogin.h \
  /home/nvidia/work/MIVA/3rdparty/rapidjson/include/rapidjson/document.h \
@@ -432,11 +385,13 @@ modules/CMakeFiles/modules.dir/HttpClient/src/HttpClient.cpp.o: \
  /home/nvidia/work/MIVA/3rdparty/rapidjson/include/rapidjson/internal/biginteger.h \
  /home/nvidia/work/MIVA/3rdparty/rapidjson/include/rapidjson/internal/diyfp.h \
  /home/nvidia/work/MIVA/3rdparty/rapidjson/include/rapidjson/internal/pow10.h \
+ /usr/include/c++/7/climits \
  /home/nvidia/work/MIVA/3rdparty/rapidjson/include/rapidjson/error/error.h \
  /home/nvidia/work/MIVA/3rdparty/rapidjson/include/rapidjson/error/../rapidjson.h \
  /home/nvidia/work/MIVA/3rdparty/rapidjson/include/rapidjson/internal/strfunc.h \
  /home/nvidia/work/MIVA/3rdparty/rapidjson/include/rapidjson/internal/../stream.h \
  /home/nvidia/work/MIVA/3rdparty/rapidjson/include/rapidjson/internal/../rapidjson.h \
+ /usr/include/c++/7/iterator /usr/include/c++/7/bits/stream_iterator.h \
  /home/nvidia/work/MIVA/3rdparty/rapidjson/include/rapidjson/rapidjson.h \
  /home/nvidia/work/MIVA/3rdparty/rapidjson/include/rapidjson/stringbuffer.h \
  /home/nvidia/work/MIVA/3rdparty/rapidjson/include/rapidjson/writer.h \
@@ -449,4 +404,61 @@ modules/CMakeFiles/modules.dir/HttpClient/src/HttpClient.cpp.o: \
  /home/nvidia/work/MIVA/modules/dataType/include/NettyClientResultMsg.h \
  /home/nvidia/work/MIVA/modules/dataType/include/NettyClientCommandEnum.h \
  /home/nvidia/work/MIVA/modules/dataType/include/SendHeartBeat.h \
- /home/nvidia/work/MIVA/modules/inifile/include/inifile.h
+ /home/nvidia/work/MIVA/modules/inifile/include/inifile.h \
+ /home/nvidia/work/MIVA/modules/md5/include/md5.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpResultMsg.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpToken.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpNull.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpCarInfo.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpTrainInfo.h \
+ /usr/local/include/httplib.h /usr/include/ifaddrs.h \
+ /usr/include/resolv.h /usr/include/aarch64-linux-gnu/sys/param.h \
+ /usr/include/aarch64-linux-gnu/bits/param.h /usr/include/linux/param.h \
+ /usr/include/aarch64-linux-gnu/asm/param.h \
+ /usr/include/asm-generic/param.h /usr/include/arpa/nameser.h \
+ /usr/include/arpa/nameser_compat.h \
+ /usr/include/aarch64-linux-gnu/bits/types/res_state.h \
+ /usr/include/c++/7/csignal /usr/include/c++/7/algorithm \
+ /usr/include/c++/7/bits/stl_algo.h \
+ /usr/include/c++/7/bits/algorithmfwd.h \
+ /usr/include/c++/7/bits/stl_heap.h \
+ /usr/include/c++/7/bits/uniform_int_dist.h /usr/include/fcntl.h \
+ /usr/include/aarch64-linux-gnu/bits/fcntl.h \
+ /usr/include/aarch64-linux-gnu/bits/fcntl-linux.h \
+ /usr/include/linux/falloc.h /usr/include/aarch64-linux-gnu/bits/stat.h \
+ /usr/include/aarch64-linux-gnu/bits/fcntl2.h /usr/include/c++/7/iomanip \
+ /usr/include/c++/7/locale /usr/include/c++/7/bits/locale_facets_nonio.h \
+ /usr/include/aarch64-linux-gnu/c++/7/bits/time_members.h \
+ /usr/include/aarch64-linux-gnu/c++/7/bits/messages_members.h \
+ /usr/include/libintl.h /usr/include/c++/7/bits/locale_facets_nonio.tcc \
+ /usr/include/c++/7/bits/locale_conv.h \
+ /usr/include/c++/7/bits/stringfwd.h /usr/include/c++/7/bits/allocator.h \
+ /usr/include/c++/7/bits/codecvt.h /usr/include/c++/7/bits/unique_ptr.h \
+ /usr/include/c++/7/random /usr/include/c++/7/cmath /usr/include/math.h \
+ /usr/include/aarch64-linux-gnu/bits/math-vector.h \
+ /usr/include/aarch64-linux-gnu/bits/libm-simd-decl-stubs.h \
+ /usr/include/aarch64-linux-gnu/bits/flt-eval-method.h \
+ /usr/include/aarch64-linux-gnu/bits/fp-logb.h \
+ /usr/include/aarch64-linux-gnu/bits/fp-fast.h \
+ /usr/include/aarch64-linux-gnu/bits/mathcalls-helper-functions.h \
+ /usr/include/aarch64-linux-gnu/bits/mathcalls.h \
+ /usr/include/aarch64-linux-gnu/bits/iscanonical.h \
+ /usr/include/aarch64-linux-gnu/bits/mathinline.h \
+ /usr/include/c++/7/bits/random.h \
+ /usr/include/aarch64-linux-gnu/c++/7/bits/opt_random.h \
+ /usr/include/c++/7/bits/random.tcc /usr/include/c++/7/numeric \
+ /usr/include/c++/7/bits/stl_numeric.h /usr/include/c++/7/regex \
+ /usr/include/c++/7/bitset /usr/include/c++/7/stack \
+ /usr/include/c++/7/bits/stl_stack.h \
+ /usr/include/c++/7/bits/regex_constants.h \
+ /usr/include/c++/7/bits/regex_error.h \
+ /usr/include/c++/7/bits/regex_automaton.h \
+ /usr/include/c++/7/bits/regex_automaton.tcc \
+ /usr/include/c++/7/bits/regex_scanner.h \
+ /usr/include/c++/7/bits/regex_scanner.tcc \
+ /usr/include/c++/7/bits/regex_compiler.h \
+ /usr/include/c++/7/bits/regex_compiler.tcc \
+ /usr/include/c++/7/bits/regex.h /usr/include/c++/7/bits/regex.tcc \
+ /usr/include/c++/7/bits/regex_executor.h \
+ /usr/include/c++/7/bits/regex_executor.tcc \
+ /usr/include/aarch64-linux-gnu/sys/stat.h

+ 6 - 0
build/modules/CMakeFiles/modules.dir/compiler_depend.internal

@@ -552,6 +552,12 @@ modules/CMakeFiles/modules.dir/HttpClient/src/HttpClient.cpp.o
  /home/nvidia/work/MIVA/modules/dataType/include/NettyClientCommandEnum.h
  /home/nvidia/work/MIVA/modules/dataType/include/SendHeartBeat.h
  /home/nvidia/work/MIVA/modules/inifile/include/inifile.h
+ /home/nvidia/work/MIVA/modules/md5/include/md5.h
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpResultMsg.h
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpToken.h
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpNull.h
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpCarInfo.h
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpTrainInfo.h
 
 modules/CMakeFiles/modules.dir/TCPClient/src/TCPClient.cpp.o
  /home/nvidia/work/MIVA/modules/TCPClient/src/TCPClient.cpp

+ 39 - 23
build/modules/CMakeFiles/modules.dir/compiler_depend.make

@@ -550,7 +550,13 @@ modules/CMakeFiles/modules.dir/HttpClient/src/HttpClient.cpp.o: ../modules/HttpC
   ../modules/dataType/include/NettyClientResultMsg.h \
   ../modules/dataType/include/NettyClientCommandEnum.h \
   ../modules/dataType/include/SendHeartBeat.h \
-  ../modules/inifile/include/inifile.h
+  ../modules/inifile/include/inifile.h \
+  ../modules/md5/include/md5.h \
+  ../modules/dataType/include/NettyHttpResultMsg.h \
+  ../modules/dataType/include/NettyHttpToken.h \
+  ../modules/dataType/include/NettyHttpNull.h \
+  ../modules/dataType/include/NettyHttpCarInfo.h \
+  ../modules/dataType/include/NettyHttpTrainInfo.h
 
 modules/CMakeFiles/modules.dir/TCPClient/src/TCPClient.cpp.o: ../modules/TCPClient/src/TCPClient.cpp \
   /usr/include/stdc-predef.h \
@@ -3988,8 +3994,6 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: ../modules/userApp/sr
 
 /usr/include/boost/variant/variant_fwd.hpp:
 
-/usr/include/boost/variant/detail/config.hpp:
-
 /usr/include/boost/mpl/aux_/preprocessed/gcc/or.hpp:
 
 /usr/include/boost/mpl/aux_/yes_no.hpp:
@@ -4274,6 +4278,10 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: ../modules/userApp/sr
 
 /usr/include/gstreamer-1.0/gst/gstprotection.h:
 
+/usr/include/gstreamer-1.0/gst/gstvalue.h:
+
+/usr/include/gstreamer-1.0/gst/gsterror.h:
+
 /usr/include/boost/mpl/insert_range.hpp:
 
 /usr/include/boost/mpl/aux_/empty_impl.hpp:
@@ -4342,6 +4350,10 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: ../modules/userApp/sr
 
 ../3rdparty/ZLMediaKit/src/Rtsp/RtspSplitter.h:
 
+/usr/include/boost/variant/detail/config.hpp:
+
+../modules/dataType/include/NettyHttpTrainInfo.h:
+
 /usr/include/boost/mpl/O1_size.hpp:
 
 /usr/include/boost/type_traits/is_array.hpp:
@@ -4362,9 +4374,9 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: ../modules/userApp/sr
 
 /usr/include/c++/7/bits/regex_automaton.h:
 
-../modules/md5/include/md5.h:
+/usr/include/gstreamer-1.0/gst/gstpipeline.h:
 
-/usr/include/c++/7/bits/algorithmfwd.h:
+../3rdparty/rapidjson/include/rapidjson/internal/stack.h:
 
 /usr/include/boost/preprocessor/tuple/eat.hpp:
 
@@ -4562,6 +4574,8 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: ../modules/userApp/sr
 
 /usr/include/aarch64-linux-gnu/sys/socket.h:
 
+../modules/dataType/include/NettyHttpResultMsg.h:
+
 /usr/include/boost/mpl/fold.hpp:
 
 /usr/include/gstreamer-1.0/gst/gsturi.h:
@@ -4850,6 +4864,8 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: ../modules/userApp/sr
 
 /usr/include/c++/7/bits/exception_ptr.h:
 
+../modules/dataType/include/NettyHttpNull.h:
+
 /usr/include/boost/mpl/aux_/config/workaround.hpp:
 
 /usr/include/c++/7/bits/regex_compiler.h:
@@ -4886,6 +4902,8 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: ../modules/userApp/sr
 
 /usr/include/wctype.h:
 
+../modules/dataType/include/NettyHttpCarInfo.h:
+
 /usr/include/boost/mpl/void.hpp:
 
 /usr/include/c++/7/bits/stl_function.h:
@@ -4932,6 +4950,12 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: ../modules/userApp/sr
 
 /usr/lib/gcc/aarch64-linux-gnu/7/include/stddef.h:
 
+/usr/include/boost/preprocessor/enum_params.hpp:
+
+/usr/include/gstreamer-1.0/gst/gstinfo.h:
+
+/usr/include/c++/7/ios:
+
 /usr/include/glib-2.0/glib/gthread.h:
 
 /usr/include/c++/7/bits/stl_map.h:
@@ -4968,6 +4992,10 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: ../modules/userApp/sr
 
 /usr/include/c++/7/type_traits:
 
+/usr/include/c++/7/bits/algorithmfwd.h:
+
+../modules/md5/include/md5.h:
+
 ../3rdparty/rapidjson/include/rapidjson/stream.h:
 
 /usr/include/gstreamer-1.0/gst/gstbufferpool.h:
@@ -5228,6 +5256,8 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: ../modules/userApp/sr
 
 /usr/include/aarch64-linux-gnu/bits/types/sigset_t.h:
 
+../modules/dataType/include/NettyHttpToken.h:
+
 /usr/include/c++/7/ext/atomicity.h:
 
 /usr/include/aarch64-linux-gnu/bits/types/struct_sigstack.h:
@@ -5314,6 +5344,10 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: ../modules/userApp/sr
 
 /usr/include/c++/7/bits/vector.tcc:
 
+/usr/include/gstreamer-1.0/gst/gstghostpad.h:
+
+/usr/include/c++/7/bits/random.tcc:
+
 /usr/include/c++/7/bitset:
 
 /usr/include/aarch64-linux-gnu/bits/stdlib-float.h:
@@ -5834,8 +5868,6 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: ../modules/userApp/sr
 
 /usr/include/glib-2.0/glib/gdataset.h:
 
-/usr/include/gstreamer-1.0/gst/gstvalue.h:
-
 /usr/include/boost/detail/reference_content.hpp:
 
 /usr/include/glib-2.0/glib/gbase64.h:
@@ -5894,8 +5926,6 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: ../modules/userApp/sr
 
 /usr/include/glib-2.0/glib/gkeyfile.h:
 
-/usr/include/gstreamer-1.0/gst/gsterror.h:
-
 /usr/include/boost/exception/exception.hpp:
 
 /usr/include/glib-2.0/glib/gmessages.h:
@@ -6051,17 +6081,3 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: ../modules/userApp/sr
 /usr/include/gstreamer-1.0/gst/gstpluginfeature.h:
 
 /usr/include/gstreamer-1.0/gst/gstdeviceprovider.h:
-
-/usr/include/c++/7/bits/random.tcc:
-
-/usr/include/gstreamer-1.0/gst/gstghostpad.h:
-
-/usr/include/boost/preprocessor/enum_params.hpp:
-
-/usr/include/c++/7/ios:
-
-/usr/include/gstreamer-1.0/gst/gstinfo.h:
-
-../3rdparty/rapidjson/include/rapidjson/internal/stack.h:
-
-/usr/include/gstreamer-1.0/gst/gstpipeline.h:

BIN
build/modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o


+ 7 - 0
build/modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o.d

@@ -1053,6 +1053,13 @@ modules/CMakeFiles/modules.dir/userApp/src/user_app.cpp.o: \
  /usr/include/boost/variant/bad_visit.hpp \
  /home/nvidia/work/MIVA/modules/dataType/include/ApiSyncData.h \
  /home/nvidia/work/MIVA/modules/dataType/include/ApiResult.h \
+ /home/nvidia/work/MIVA/modules/HttpClient/include/HttpClient.h \
+ /home/nvidia/work/MIVA/modules/md5/include/md5.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpResultMsg.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpToken.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpNull.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpCarInfo.h \
+ /home/nvidia/work/MIVA/modules/dataType/include/NettyHttpTrainInfo.h \
  /usr/local/include/httplib.h /usr/include/ifaddrs.h \
  /usr/include/resolv.h /usr/include/aarch64-linux-gnu/sys/param.h \
  /usr/include/aarch64-linux-gnu/bits/param.h /usr/include/linux/param.h \

BIN
lib/libmodules.so


+ 57 - 5
modules/HttpClient/include/HttpClient.h

@@ -4,12 +4,14 @@
  * @Autor: lishengyin
  * @Date: 2021-11-03 14:08:44
  * @LastEditors: lishengyin
- * @LastEditTime: 2021-11-03 15:58:19
+ * @LastEditTime: 2021-11-10 17:15:44
  */
 #pragma once
 
 #include <iostream>
-#include <httplib.h>
+
+#include <time.h>
+#include <ctime>
 #include "Util/logger.h"
 #include "Util/NoticeCenter.h"
 #include "Poller/EventPoller.h"
@@ -25,8 +27,13 @@
 #include "inifile.h"
 
 #include "Notices.h"
+#include "md5.h"
+#include "NettyHttpResultMsg.h"
+#include "NettyHttpToken.h"
+#include "NettyHttpNull.h"
+#include "NettyHttpCarInfo.h"
+
 
-using namespace httplib;
 using namespace std;
 
 namespace MIVA
@@ -34,7 +41,9 @@ namespace MIVA
     class HttpClient
     {
     private:
-        std::shared_ptr<httplib::Client> m_httpClient = NULL;
+        // 用户名
+        std::string account;
+        std::string pwd;
 
         // 固定16位私钥
         std::string privateKey = "mwWAH2eUAAHodlRt";
@@ -44,12 +53,55 @@ namespace MIVA
         // refreshToken
         std::string refreshToken = "";
 
+        
+
     public:
         HttpClient();
         ~HttpClient();
 
-        int32_t Init(std::string url, int port);
+        /**
+         * @description: 初始化
+         * @param {string} account
+         * @param {string} url
+         * @param {int} port
+         * @return {*}
+         */        
+        int32_t Init(std::string account,std::string url, int port);
+
+        /**
+         * @description: 创建对象
+         * @param {*}
+         * @return {*}
+         */        
+        static std::shared_ptr<HttpClient> CreateNew();
+
+        /**
+         * @description: 登录
+         * @param {*}
+         * @return {*}
+         */        
         int32_t LoginNetty();
+
+        /**
+         * @description: 获取用户时间
+         * @param {*}
+         * @return {*}
+         */        
+        int32_t GetUserData();
+
+        /**
+         * @description: 获取时间
+         * @param {char} *ctime
+         * @return {*}
+         */        
+        static void getDataTime(char *ctime);
+
+        /**
+         * @description: 判断是否获取到Token
+         * @param {*}
+         * @return {*}
+         */        
+        bool alive();
         
     };
 } // namespace name

+ 97 - 5
modules/HttpClient/src/HttpClient.cpp

@@ -4,14 +4,17 @@
  * @Autor: lishengyin
  * @Date: 2021-11-03 14:08:57
  * @LastEditors: lishengyin
- * @LastEditTime: 2021-11-03 16:53:10
+ * @LastEditTime: 2021-11-10 17:12:38
  */
 
 #include "HttpClient.h"
+#include <httplib.h>
 
+using namespace httplib;
 namespace MIVA
 {
-
+    std::shared_ptr<httplib::Client> m_httpClient = NULL;
+    std::shared_ptr<HttpClient> httpClient = NULL;
     HttpClient::HttpClient(){
 
         
@@ -23,13 +26,23 @@ namespace MIVA
     }
 
     /**
-     * @description: 初始化
+     * @description: 创建对象
      * @param {*}
      * @return {*}
      */    
-    int32_t HttpClient::Init(std::string url, int port){
+    std::shared_ptr<HttpClient> HttpClient::CreateNew(){
+        if(httpClient == NULL) httpClient = std::make_shared<HttpClient>();
+        return httpClient;
+    }
 
-        m_httpClient = std::make_shared<httplib::Client>("url", port);
+    /**
+     * @description: 初始化
+     * @param {*}
+     * @return {*}
+     */    
+    int32_t HttpClient::Init(std::string account,std::string url, int port){
+        this->account = account;
+        m_httpClient = std::make_shared<httplib::Client>(url, port);
         if(m_httpClient == NULL){
             ErrorL << "HttpClient initialization failed";
             return ERR;
@@ -42,10 +55,89 @@ namespace MIVA
         return OK;
     }
 
+    /**
+     * @description: 登录Netty换取Token
+     * @param {*}
+     * @return {*}
+     */    
     int32_t HttpClient::LoginNetty(){
+        // 获取时间
+        char ctime[80];
+        getDataTime(ctime);
+        string reqTime = ctime;
+        std::string reqSign = md5(this->privateKey + this->account + this->pwd + reqTime);
+        
+        httplib::Params params;
+        params.emplace("account", this->account);
+        params.emplace("reqSign", reqSign);
+        params.emplace("reqSign", reqSign);
 
+        if (auto res = m_httpClient->Post("/FACEREC-SYSTEM/user/pass/loginByNetty",params)){
+            if (res->status == 200) {
+                std::cout << res->body << std::endl;
+                NettyHttpResultMsg<NettyHttpNull,NettyHttpToken> nettyHttpResultMsg;
+                // 解析数据
+                if(!nettyHttpResultMsg.jsonToObject(res->body)){
+                    return ERR;
+                }
+                // 提取token
+                this->authToken = nettyHttpResultMsg.extentDatas[0].authToken;
+                this->refreshToken = nettyHttpResultMsg.extentDatas[0].refreshToken;
+            }
+        }else{
+            auto err = res.error();
+            return ERR;
+        }
+        return OK;
+    }
 
+    /**
+     * @description: 获取用户数据
+     * @param {*}
+     * @return {*}
+     */    
+    int32_t HttpClient::GetUserData()
+    {
+        httplib::Params params;
+        params.emplace("authToken", this->authToken);
+        params.emplace("authUid", this->account);
+        if (auto res = m_httpClient->Post("/FACEREC-DEVICE/carInfo/tree",params)){
+            if (res->status == 200) {
+                std::cout << res->body << std::endl;
+                NettyHttpResultMsg<NettyHttpCarInfo,NettyHttpNull> nettyHttpResultMsg;
+                // 解析数据
+                if(!nettyHttpResultMsg.jsonToObject(res->body)){
+                    return ERR;
+                }
+            }
+        }else{
+            auto err = res.error();
+            return ERR;
+        }
+        return OK;
+    }
 
+    /**
+     * @description: 获取时间
+     * @param {char} *ctime
+     * @return {*}
+     */    
+    void HttpClient::getDataTime(char *ctime)
+    {
+        time_t rawtime;
+        struct tm *info;
+        time(&rawtime);
+        info = localtime(&rawtime);
+        strftime(ctime, 80, "%Y-%m-%d %H:%M:%S", info);
+    }
+    
+    /**
+     * @description: 判断是否获取到Token
+     * @param {*}
+     * @return {*}
+     */    
+    bool HttpClient::alive(){
+        return this->authToken  == "" ? false : true;
     }
 
     

+ 1 - 1
modules/dataType/include/NettyHttpCarInfo.h

@@ -4,7 +4,7 @@
  * @Autor: lishengyin
  * @Date: 2021-11-04 15:59:10
  * @LastEditors: lishengyin
- * @LastEditTime: 2021-11-09 11:53:10
+ * @LastEditTime: 2021-11-09 14:17:15
  */
 
 #pragma once

+ 29 - 0
modules/dataType/include/NettyHttpNull.h

@@ -0,0 +1,29 @@
+/*
+ * @Description: 
+ * @Version: 1.0
+ * @Autor: lishengyin
+ * @Date: 2021-11-09 16:31:01
+ * @LastEditors: lishengyin
+ * @LastEditTime: 2021-11-09 16:32:16
+ */
+#pragma once
+
+#include <iostream>
+using namespace std;
+#include <rapidjson/document.h>
+#include <rapidjson/rapidjson.h>
+#include <rapidjson/stringbuffer.h>
+#include <rapidjson/writer.h>
+
+class NettyHttpNull
+{
+private:
+    
+public:
+    NettyHttpNull() {}
+    ~NettyHttpNull() {}
+    bool jsonToObject(const rapidjson::Value& object){
+        
+        return true;
+    }
+};

+ 3 - 3
modules/dataType/include/NettyHttpResultMsg.h

@@ -4,7 +4,7 @@
  * @Autor: lishengyin
  * @Date: 2021-11-03 15:16:14
  * @LastEditors: lishengyin
- * @LastEditTime: 2021-11-04 15:07:43
+ * @LastEditTime: 2021-11-09 16:45:50
  */
 #pragma once
 
@@ -23,7 +23,7 @@ using namespace std;
 template <typename T1, typename T2>
 class NettyHttpResultMsg
 {
-private:
+public:
     std::string code;
     std::string msg;
     
@@ -99,7 +99,7 @@ public:
                 for (size_t i = 0; i < objs.Size(); ++i) {
                     const rapidjson::Value& obj = objs[i];
                     T2 extentData;
-                    if(!(data.jsonToObject(obj))){
+                    if(!(extentData.jsonToObject(obj))){
                         return false;
                     }
                     extentDatas.push_back(extentData);

+ 2 - 2
modules/dataType/include/NettyHttpToken.h

@@ -4,7 +4,7 @@
  * @Autor: lishengyin
  * @Date: 2021-11-04 09:39:46
  * @LastEditors: lishengyin
- * @LastEditTime: 2021-11-04 15:45:32
+ * @LastEditTime: 2021-11-09 16:36:49
  */
 
 #include <iostream>
@@ -12,7 +12,7 @@ using namespace std;
 
 class NettyHttpToken
 {
-private:
+public:
     std::string authToken = "";
     std::string expiration = "";
     std::string refreshToken = "";

+ 13 - 3
modules/userApp/include/user_app.h

@@ -4,7 +4,7 @@
  * @Autor: lishengyin
  * @Date: 2021-10-13 09:41:50
  * @LastEditors: lishengyin
- * @LastEditTime: 2021-11-03 13:40:20
+ * @LastEditTime: 2021-11-10 17:08:00
  */
 #pragma once
 
@@ -49,7 +49,7 @@
 #include "Notices.h"
 #include "ApiSyncData.h"
 #include "ApiResult.h"
-
+#include "HttpClient.h"
 #include <httplib.h>
 
 using namespace toolkit;
@@ -58,7 +58,6 @@ using namespace inifile;
 
 using namespace std;
 
-
 namespace MIVA
 {  
     class UserApp
@@ -118,6 +117,7 @@ namespace MIVA
          * @author: lishengyin
          */        
         static uint32_t DataCalculation(uint32_t noLoad, uint32_t dynamicLoad, int num);
+
         /**
          * @description: 拥挤成都判定
          * @param {int} num 识别结果
@@ -147,18 +147,28 @@ namespace MIVA
         std::string password;
         std::string character;
 
+        // Http
+        std::string account;
+        std::string pwd;
+        std::string uri;
+        std::string port;
+
+
         int device_id;
         bool play = false;
         bool start = true;
     private:
         std::shared_ptr<TCPClient> m_tcpClient = NULL;
         std::shared_ptr<Inference> m_Infer = NULL;
+        std::shared_ptr<HttpClient> m_httpClient = NULL;
+
         Socket::Ptr m_udpClient = NULL;
 
         std::vector<DataSource> DataList;
         Timer::Ptr m_timer0;
         Timer::Ptr m_timer1;
         Timer::Ptr m_timer2;
+        Timer::Ptr m_timer3;
         
     private:
 

+ 23 - 2
modules/userApp/src/user_app.cpp

@@ -4,7 +4,7 @@
  * @Autor: lishengyin
  * @Date: 2021-10-13 09:35:42
  * @LastEditors: lishengyin
- * @LastEditTime: 2021-11-03 11:04:36
+ * @LastEditTime: 2021-11-10 17:18:25
  */
 #include "user_app.h"
 
@@ -94,11 +94,13 @@ namespace MIVA
         // 链接Netty后端
         ConnectNetty();
 
+
+
         // UDP绑定端口
         this->m_udpClient = Socket::createSocket();
         this->m_udpClient->bindUdpSock(this->PIS_port);
 
-         vector<vector<string>> sqlRet;
+        vector<vector<string>> sqlRet;
          // 清洗旧数据
         SqlWriter sqlTruncate("truncate table MIVA_DB.InferTime");
         sqlTruncate << sqlRet;
@@ -157,6 +159,7 @@ namespace MIVA
         InfoL << "System initialization is successful!";
         return OK;
     }
+    
     /**
      * @description: 释放数据
      * @param {*}
@@ -174,6 +177,7 @@ namespace MIVA
         this->m_Infer->Destory();
         this->m_Infer = NULL;
     }
+    
     /**
      * @description: 启动任务
      * @param {*}
@@ -205,6 +209,18 @@ namespace MIVA
             this->ReportData(); // 上报数据
             return true;
         }, nullptr);
+
+        // 定时获取数据
+        this->m_timer3 = std::make_shared<Timer>(3.0f,[&](){
+            if(this->m_httpClient->alive()){
+                // 获取到数据并解析成功
+                if(this->m_httpClient->GetUserData() == OK){
+                    
+                }
+            }
+            return true;
+        }, nullptr);
+
         // 记录时间
         clock_gettime(CLOCK_BOOTTIME, &time1);
         poolInfer.start();
@@ -262,6 +278,11 @@ namespace MIVA
     {
         if(this->m_tcpClient == NULL) this->m_tcpClient = TCPClient::Ptr(new TCPClient());
         this->m_tcpClient->startConnect(this->Netty_ip, this->Netty_port);
+
+        if(this->m_httpClient == NULL) this->m_httpClient = HttpClient::CreateNew();
+        if(this->m_httpClient->Init("nettyUser2",this->Netty_ip,8760) != OK){
+            ErrorL << "HttpClient登录Netty失败" << endl;
+        }
     }
 
     /**

BIN
source/bin/main