Signed-off-by: Justin Pettit <jpet...@nicira.com> --- lib/jsonrpc.c | 4 ++-- lib/jsonrpc.h | 11 +++++++---- ovsdb/SPECS | 4 +++- vswitchd/bridge.c | 2 +- 4 files changed, 13 insertions(+), 8 deletions(-)
diff --git a/lib/jsonrpc.c b/lib/jsonrpc.c index b43b044..cef96a9 100644 --- a/lib/jsonrpc.c +++ b/lib/jsonrpc.c @@ -63,7 +63,7 @@ static void jsonrpc_error(struct jsonrpc *, int error); int jsonrpc_stream_open(const char *name, struct stream **streamp, uint8_t dscp) { - return stream_open_with_default_port(name, JSONRPC_TCP_PORT, + return stream_open_with_default_port(name, OVSDB_OLD_PORT, streamp, dscp); } @@ -72,7 +72,7 @@ jsonrpc_stream_open(const char *name, struct stream **streamp, uint8_t dscp) int jsonrpc_pstream_open(const char *name, struct pstream **pstreamp, uint8_t dscp) { - return pstream_open_with_default_port(name, JSONRPC_TCP_PORT, + return pstream_open_with_default_port(name, OVSDB_OLD_PORT, pstreamp, dscp); } diff --git a/lib/jsonrpc.h b/lib/jsonrpc.h index 2c691cf..5397200 100644 --- a/lib/jsonrpc.h +++ b/lib/jsonrpc.h @@ -32,11 +32,14 @@ struct stream; /* API for a JSON-RPC stream. */ -/* Default port number. +/* Default port numbers. * - * There is nothing standard about this port number. It is simply what - * we have chosen. */ -#define JSONRPC_TCP_PORT 6632 + * OVSDB_OLD_PORT defines the original port number used by OVS. + * OVSDB_PORT defines the official port number assigned by IANA. By + * default, we still uses OVSDB_OLD_PORT, but we present a warning that + * that will change. */ +#define OVSDB_OLD_PORT 6632 +#define OVSDB_PORT 6640 int jsonrpc_stream_open(const char *name, struct stream **, uint8_t dscp); int jsonrpc_pstream_open(const char *name, struct pstream **, uint8_t dscp); diff --git a/ovsdb/SPECS b/ovsdb/SPECS index 5bdb974..5656b9d 100644 --- a/ovsdb/SPECS +++ b/ovsdb/SPECS @@ -316,7 +316,9 @@ over HTTP, for these reasons: * The JSON-RPC specification for HTTP transport is incomplete. -We are using TCP port 6632 for the database JSON-RPC connection. +We are currently using TCP port 6632 for the database JSON-RPC +connection, but future versions will switch to using IANA-assigned TCP +port 6640. The database wire protocol consists of the following JSON-RPC methods: diff --git a/vswitchd/bridge.c b/vswitchd/bridge.c index 423da10..ec3633c 100644 --- a/vswitchd/bridge.c +++ b/vswitchd/bridge.c @@ -474,7 +474,7 @@ collect_in_band_managers(const struct ovsrec_open_vswitch *ovs_cfg, struct sockaddr_in *sin = &managers[n_managers]; if (stream_parse_target_with_default_port(target, - JSONRPC_TCP_PORT, + OVSDB_OLD_PORT, sin)) { n_managers++; } -- 1.7.5.4 _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev