280 Commits

Author SHA1 Message Date
Jian Li
2907ad2941 [ONOS-4530] Allow to specify appId when insert FlowRule through REST
- Augment FlowRuleCodec to encode FlowRule
- Add unit test for encode method of FlowRuleCodec
- Add getFlowByAppId and removeFlowByAppId methods in FlowsWebResource
- Add more unit tests for FlowWebResource
- Add FlowRules.json swagger doc
- Rename Flows.json to FlowEntries.json, correct FlowEntries.json

Change-Id: Ic3ec390c13a349e51ae4208adbc478564b6724ba
2016-05-17 18:38:11 +00:00
HIGUCHI Yuta
dea375a7de Remove deprecated ConfigProvider.
Change-Id: Ibf927671b0729212e9d1d2bbfd19d4aaab48b9dd
2016-05-16 16:46:38 +00:00
Jian Li
7d06923446 Fix compile time NPE which is encountered in Eclipse IDE
Change-Id: Id447967ad6c7c68f4a6e5c562e7245029a89902f
2016-05-13 17:08:29 -07:00
Jian Li
a3e4c7ada6 Bugfix: fix the swagger broken issue caused by unsupported data type
Current implementation of SwaggerMojo does not support the data type
other than string, int, long and boolean.
This commit temporarily fix the issue on generating swagger doc.
Eventually, we need to augment SwaggerMojo to support more data type
including other primitive types and even Object data types.

Change-Id: I5cb69ea6af7faecfc19660c4bbf619c3d85508f3
2016-05-12 20:29:47 +00:00
Jian Li
847242ba4e [ONOS-4409] Merge getApp REST methods into one, revise unit test
Change-Id: I47e5dd1d795404d3ba2c73487858a3d389790ac9
2016-05-12 17:16:50 +00:00
Jian Li
cc730a66f5 Clean up source code of REST API
- Add missing @Produces annotation
- Correct comments
- Restrict variable access level

Change-Id: I7f75650b83651248370e7781b1e8aec7eac2314c
2016-05-11 04:34:59 +00:00
Jian Li
a7cd9d75f7 Try explicit class casting to remove warning message
Change-Id: If7830a12e0405c5b37f6e864bd7dfb915871959f
2016-05-10 23:08:33 +00:00
Jian Li
c2a542bcab Explicitly return NO CONTENT type response for http DELETE request
Change-Id: I920084b92197bb1687e7d978ad350b2e1290ecbc
2016-05-10 22:24:39 +00:00
Jian Li
cbf49898a2 Treat null as NOT FOUND for application and applicationId
Change-Id: Ieaf65770b0057c85cef47e1904efbc93709ff06b
2016-05-10 22:11:13 +00:00
Jian Li
e1c1c8dbd2 [ONOS-4409] Support applicationId registration and query via REST
With this commit, we can register and query on/off platform
applications through REST API.

Change-Id: I82e1e0e55bbc017d6c0cce7d9a6af7a578d7196e
2016-05-10 21:46:23 +00:00
HIGUCHI Yuta
4c0ef6b54a ONOS-4416 Remove OduCltPort out of core.
Change-Id: I04324a72e48af84afdbfa32b84c8e57f39411000
2016-05-09 23:38:47 +00:00
HIGUCHI Yuta
95d83e8067 ONOS-4415 Remove OmsPort out of core.
Change-Id: Ic796c4e715789ba18f350f28e29db04dd537822f
2016-05-09 23:38:16 +00:00
HIGUCHI Yuta
34a3f69be1 ONOS-3503 Remove OchPort out of core.
- Implementation of a Behavior OpticalDevice has the knowledge of
  translating annotations into optical specific port.
- OpticalDeviceServiceView checks if the Device is a OpticalDevice
  and translate all the Ports to optical specific port before returning.

- This commit contains feedbacks, issues, and fixes by Michele Santuari.

- Note: 3 more Port types to go (OduClt, Oms, Otu)

Change-Id: I4cbda8bc1922fbdd4dac8de8d02294bad74b8058
2016-05-09 22:24:41 +00:00
Jian Li
0409b709b3 Revise Mastership REST API to use synchronous methods
- Add missing swagger docs
- Add missing unit tests

Change-Id: I21a20410ea322e7893c5c0c48f5d9fd0f2f9dfe1
2016-05-05 00:04:43 +00:00
Jian Li
f96d41fd18 [ONOS-4438] Add REST API for mastership service
- Correct some typos in mastership codec

Change-Id: If8a0127d8d897d4b87cae71a194dfece6aa14f49
2016-05-04 00:10:39 +00:00
Claudine Chiu
1decd53931 ONOS-4077: REST API's for virtual networks, devices, ports, links: add missing onos.rsModel statements + fix example field in JSON files
Change-Id: I1ae2300143a0a56e5413f8837cea3016d964cb6c
2016-04-29 16:22:14 +00:00
Jonathan Hart
c341833b38 Make example priority smaller.
The original value overflows the 16-bits allowed by OpenFlow so that
example doesn't work very well for OpenFlow devices.

Change-Id: I0b61404ff7ae6c542f92787c9e8ab5c7a2e058f1
2016-04-26 15:59:42 +00:00
Jian Li
5c9891010f Update css for swagger 2.4.1, add missing resource to fix js error
Change-Id: I91c932ed21564eb862438464642a2f62982e8c71
2016-04-25 23:03:51 +00:00
Claudine Chiu
a98c2ea61e ONOS-4077: REST API's for virtual networks and tenants
Change-Id: Ic229c9bc78e4bfce20842717ae46a0b8acff0b76
2016-04-22 16:20:36 +00:00
Andrea Campanella
c99d430746 Fixed title field creates empty json objects
Change-Id: I1ccecacde9c5538b29ff219279538c8ea98beaa2
2016-04-21 14:04:26 -07:00
Brian Stanke
9a108975d7 ONOS-3633 - Implementation of virtual network point to point intent provider.
Change-Id: Ie2c1e5ac278bc0dd6259479c44dd92b9b625e90b
2016-04-21 19:12:39 +00:00
Jian Li
83d87a766a Bumpup swagger ui to 2.1.4 to fix the issues in 2.1.0
This commit resolves some issues on generating REST API request,
such as incorrect content-type generation for http DELETE request.

Change-Id: I70bf18247f95ccf22b1fd77bc48ce9977ff57212
2016-04-21 17:01:07 +00:00
Jian Li
08d65cf4a4 Remove duplicated removeVirtualLink and corresponding unit test
Change-Id: I9279bad857a54e47ba7ec72a53d65fede0ad132b
2016-04-20 17:35:03 +00:00
Jian Li
4fb7177c12 Replace Grizzly2 test container to Jetty test container
Grizzly2 test framework does not produce the same test results
compare to production REST API test through jetty web server.
By default Jersey 2.x uses the Grizzly2 test framework, this
commit tries to replace this test framework to Jetty based
http test framework.

Change-Id: I7bcb19bf73801cc66036487fd5a964e32ce1ba61
2016-04-20 17:18:43 +00:00
Jonathan Hart
345c019760 Turn off Swagger schema validation
Change-Id: I1d66c6535de5778aea703fb21c86220cae8e36f8
2016-04-20 09:00:58 -07:00
Ray Milkey
bee35092d6 Fix javadoc warnings
Change-Id: Iff748bf6a5b6653b515059506bb2d4f09d3c9878
2016-04-13 00:10:48 +00:00
Claudine Chiu
f6bf8d5076 ONOS-4077: REST API's for virtual links.
Change-Id: Idc838f24735e75ad2729393a03dcac4d256239bb
2016-04-11 17:18:53 +00:00
Ray Milkey
460f9b0523 Add bulk delete for flows
Change-Id: I77f266c75d0f9d1e99155eb48c216bff3fab2f40
2016-04-11 17:12:55 +00:00
Brian O'Connor
5ab426f9ff Updating copyrights
New format: 'Copyright .year-present Open Networking Laboratory'

Change-Id: I1a9e58b355b775e75245ad875a2d7a4df3f03098
2016-04-09 01:20:21 -07:00
Brian O'Connor
e4da59d8aa Simplifying rules and providing sensible defaults
Updated cordvtn, dhcp, fwd, onos-api, of-api, onlab-rest, onos-rest, onos-gui

Also, fixed checkstyle error print

Change-Id: I9d6ab76791e8603678079067a3b4e007ca7c4667
2016-04-08 18:43:36 -07:00
Ray Milkey
7c25182db9 Fix buck tests
Change-Id: I3d681e6e5c1d3e98c87ccb3d20a619b216ae6133
2016-04-06 19:04:52 -07:00
Brian O'Connor
b86c920526 Updating Buck files to build OSGi jars
- Using osgi_jar for all modules except apps
- Adding target for installation of core modules to .m2 repo

Change-Id: I65d9e3a9567918e275191724842d7d9b1f485128
2016-04-06 18:17:37 +00:00
Brian O'Connor
85f28d0a0a Updating test sources in several BUCK files
Change-Id: I17b83cb978f7b8fc1d31a1e96bec59a077dbdfbb
2016-04-06 16:57:45 +00:00
Ray Milkey
ddec794e1c Fixes for buck regressions
Change-Id: I40e6a68392d229bf2827e115a54c0d66fd39b2d4
2016-04-05 20:48:54 +00:00
Brian O'Connor
a450bd000b Simplifying Import-Package line in maven-bundle-plugin for REST bundles
Change-Id: Ic29e3f205e18b7b63e33a8c65cbb30a8b56d2e74
2016-04-04 21:33:36 +00:00
Claudine Chiu
fb8b816235 REST API's for tenants, virtual networks, virtual devices ad virtual ports.
Change-Id: I80abe14a083fce3dc6246118af8874028109388f

REST API's for tenants, virtual networks, virtual devices ad virtual ports.

Change-Id: Ib6c3d69d396e57822bae23f5bf3101c8b9c0b95c
2016-04-04 16:48:46 +00:00
Ray Milkey
90289b0cf9 STC fixes
Hosts without a VLAN are now represented as /None rather than /-1
Flow ID in location returned by POST operation was hex rather than decimal

Change-Id: Ibb403f696399012b2b90f2954112265a6e230815
2016-04-01 19:13:07 +00:00
alshabib
b028599214 adding group garbage collection functionality
If a group has a reference count of zero for more than
a configurable timeout, it is garbage collected.

This feature can be deactivated by component config.

Change-Id: I254d62a90ef7ac8d2ce2f406b67957455a5bf4d0
2016-03-31 17:48:04 +00:00
Luca Prete
283a96205e Using VlanId String None instead of -1
Change-Id: I2597ac37285cc3f40ad1304d668564a56a5b862f
2016-03-31 15:45:40 +00:00
Saurav Das
a2d37500d9 CORD-613 Adding ability to administratively enable or disable a port via CLI.
Currently uses the OpenFlow device provider to change portState.
Also fixes a bug in PortNumberCompleter.
Adds completion options to portstats for deviceId and portNumber.

Change-Id: Idcce775fe8bc5484fdd0e630bcb5026b85125478
2016-03-30 21:46:43 +00:00
Ray Milkey
f80bbb22c2 Initial BUCK build
Change-Id: I64e8a979301989062f4545a4841b06c15a372049
2016-03-29 21:39:14 +00:00
Thomas Vachuska
a1ae5e1a8c Adding ability to push flow rule batches via REST API.
Change-Id: I60a9b121cd9cc35a9704e59b8f1fde413af0a72f
2016-03-28 18:26:25 +00:00
Jian Li
7ff7978530 Randomize the port number to avoid race condition in REST unit test
Change-Id: Ib1b3bd5f16c7642af47b01d7a7930cae238fa71b
2016-03-28 18:12:51 +00:00
Sho SHIMIZU
a114d89a58 Remove IndexedLambda deprecated in Emu
Change-Id: I3dc3ea90049dd3331090472f8c4a0e83d430ba37
2016-03-25 15:43:31 +00:00
Jian Li
8ae91204a1 Move all REST test related files into org.onosproject.rest.resources
Move all REST test case classes under org.onosproject.rest.resources
package in a way to improve naming consistency.

Change-Id: I0a154fe492b90aa426e6af38a3c08d7c1ee8d031
2016-03-24 23:04:20 +00:00
Jian Li
44ccfb5098 Add unit test for MulticastRoute REST API
Change-Id: I33fb93256e701cbff8af3e4247917c90fea8da59
2016-03-24 21:21:13 +00:00
Jian Li
9d61649f0f [ONOS-4042] Bump up Jersey from 1.19 to 2.22.2
- Fix unit test errors of web/api
- Fix default page redirection problem
- Fix compilation errors of web/gui
- Fix configuration of aaa, acl, cordfabric, cord-gui, dhcp, mfwd,
  olt, openstack, segmentrouting, vtn, virtualbng, xos-integration
- Fix unit test errors of cpman, vtn, acl, faultmanagement
- Fix compilation errors of openstack, virtualbng, xos-integration,
  REST SB controller
- Rearrange features.xml to resolve bundle dependencies
- Remove all of stale Jersey 1.x libraries
- Rearrange web.xml to point new Jersey 2.x servlet

Change-Id: Ic17f461ede0aa36fa8d470546d8069152dc1d134
2016-03-24 18:54:28 +00:00
Jian Li
7011bdd2ee Fix typo in RegionsResourceTest
Change-Id: I486af535e57876b63854c5d11cb754ec3bb0c989
2016-03-23 23:23:06 +00:00
Jonathan Hart
b11c4d0ae9 Allow list-type config to be POSTed to subjectkey/subject/configkey endpoint.
Also add validation that the given JSON node is appropriate for the config
type (list vs object).

Change-Id: Ib1c12b538860a6f18b8311c5f5a786608c04beb8
2016-03-23 20:54:02 +00:00
Brian O'Connor
955c316b54 Starting snapshot 1.6.0-SNAPSHOT 2016-03-10 15:27:19 -08:00