Bug fix for equals(Object) in virtual node path classes.

Virtual node paths of different types should be treated as different
objects even if they have the same path components.

Change-Id: If2e6ab3cfc1436b8a14210e63284190c284957f8
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>
Remove unused dependency, jersey-json.

Change-Id: Ia3846fc9bd20d77c835cff123223a82f074e5aeb
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>
Refactor VTN Manager.

  * Determine virtual node where an incoming packet is mapped using
    global cluster cache instead of virtual node scan.
  * Ease VLAN mapping restriction.
    * The same VLAN ID can be mapped to different vBridges as long as
      different nodes are specified.
    * A VLAN mapping configured with a non-null node (which maps VLAN
      network on a specific switch) can coexist with another VLAN mapping
      configured with the same VLAN ID and a null node (which maps VLAN
      network on all switches).
      * VLAN mapping configured with a non-null node is always prior to
        VLAN mapping configured with a null node.

Change-Id: Ifc9a3170ceab65492df3b05f356a44991c515748
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>
Fixed unstable unit test.

A MacAddressEntry instance keeps a set of InetAddress instances using
an unorderd set. So string representation of a MacAddressEntry instance
is unstable because it is affected by the order of InetAddress instances.

Change-Id: Ic91af42fcfa851c67d0197d7ad34c2ae1e974413
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>
Eliminate duplicate code in toString().

Change-Id: Ieb1093941c502406ac65ae2e10756df9b122e2e8
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>
Implement Comparable to VTenantPath class.

Change-Id: I3054f4e6c7e57b279ba5f25b02648ee00a63932f
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>
Never learn zero MAC address in vBridge.

Change-Id: I78ede562fe4cbd689f18e6e58eb18437e6c1b28c
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>
Map StatusCode.BADREQUEST to HTTP 400 response (Bad Request) in REST API.

Note that this patch affects error response code returned by REST API.

Change-Id: I0165cc40c03bfc31196527faf1df378b4477d0e8
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>
Try to detect IP address for a host as possible.

VTN Manager will send at most 10 ARP requests to a detected host.

Change-Id: I4356b8d42f91a5901315e75cc5dc69e6fffa322a
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>
Update VTN Coordinator sources to the latest version.

VTN Coordinator version is changed to 5.1.0.0-SNAPSHOT.

Change-Id: I6f76c22e5210ad5c7d97eb52ec23953aa1fe052d
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>
Provide Tomcat instance only for the VTN Coordinator.

  * vtn_start starts a Tomcat instance only for the VTN Coordinator,
    and vtn_stop stops.
  * VTN web application, including required Tomcat configuration, is
    pre-installed.
  * Note that TCP port number used by Tomcat is changed from 8080 to 8083.

Change-Id: I37176c83e60cf69c3fa5eeaece4fa7b3fe0bf9a1
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>
Terminate Tomcat instance when uncd crashes.

Change-Id: I464a39416b18aabb4079675ff245bcad5d0a253e
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>
Allow unprivileged user to run VTN Coordinator.

  * A user who runs VTN Coordinator needs to have write permission
    for /usr/local/vtn/var directory.
  * db_setup command installs ownership of VTN Coordinator.
    Only a user who executed db_setup command can execute VTN commands,
    vtn_start, vtn_stop, and db_setup.
  * "db_setup -c" reset VTN Coordinator environment to initial state.
    * All data and log files are erased.

Change-Id: I366c14559bafe6bd0284815824bac7871721040b
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>
Added VTenantPath.contains(VTenantPath).

VTenantPath.contains(VTenantPath) determines whether the virtual node
associated with the VTenantPath instance contains the virtual node
specified by another VTenantPath instance.

Change-Id: Ic1dbb1e6935d20ddea8d32e270e3ebe59a09797d
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>
Implement Comparable to MacVlan and MapReference classes.

Change-Id: Ifcc3addbb3e3a42336805e75c08bbed4b18388f9
Signed-off-by: Shigeru Yasuda <s-yasuda@da.jp.nec.com>