From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55462) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W6LYX-0000rm-0R for qemu-devel@nongnu.org; Thu, 23 Jan 2014 09:47:02 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1W6LYS-0002tk-GJ for qemu-devel@nongnu.org; Thu, 23 Jan 2014 09:46:56 -0500 Received: from mx1.redhat.com ([209.132.183.28]:64052) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W6LYS-0002tc-8U for qemu-devel@nongnu.org; Thu, 23 Jan 2014 09:46:52 -0500 From: Amos Kong Date: Thu, 23 Jan 2014 22:46:31 +0800 Message-Id: <1390488396-16538-1-git-send-email-akong@redhat.com> Subject: [Qemu-devel] [PATCH v4 0/5] QMP full introspection List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: qiaonuohan@cn.fujitsu.com, lcapitulino@redhat.com, mdroth@linux.vnet.ibm.com, xiawenc@linux.vnet.ibm.com This is an implement of qmp full-introspection, parse and convert the json schema to a dynamical tree, return it to management through QMP command output. The whole output of query-qmp-schema command: http://i-kvm.rhcloud.com/static/pub/v4/qmp-introspection.output.txt http://i-kvm.rhcloud.com/static/pub/v4/qmp-introspection.h Welcome your comments! V2: use 'DataObject' to describe dynamic struct V3: improve the metadata as suggested by eric V4: use python to extend/parse schema for improving the response speed and simple the code Amos Kong (5): qapi: introduce DataObject to describe dynamic structs qapi: add qapi-introspect.py code generator qobject: introduce qobject_get_str() qmp: full introspection support for QMP update docs/qmp-full-introspection.txt .gitignore | 1 + Makefile | 5 +- docs/qmp-full-introspection.txt | 99 ++++++++++++++++++ include/qapi/qmp/qstring.h | 1 + qapi-schema.json | 152 ++++++++++++++++++++++++++++ qmp-commands.hx | 42 ++++++++ qmp.c | 215 ++++++++++++++++++++++++++++++++++++++++ qobject/qstring.c | 19 ++++ scripts/qapi-introspect.py | 172 ++++++++++++++++++++++++++++++++ 9 files changed, 705 insertions(+), 1 deletion(-) create mode 100644 docs/qmp-full-introspection.txt create mode 100644 scripts/qapi-introspect.py -- 1.8.4.2