summaryrefslogtreecommitdiffstats
path: root/src/k8splugin/api
AgeCommit message (Collapse)AuthorFilesLines
2021-02-25Provide Healthcheck API MVP0.8.0Konrad Bańka7-22/+102
Implements basic functionality of running starting Healthcheck. Results can be inspected so-far without dedicated API, by using, for example, Query API. Issue-ID: MULTICLOUD-1233 Signed-off-by: Konrad Bańka <k.banka@samsung.com> Change-Id: Ia4d96d936d573173d7d8f41e6c39d059bf5f8b1f
2021-02-25Merge "Provide Query API for CNF Instances"Ritu Sood2-0/+51
2021-02-24Provide Query API for CNF InstancesKonrad Bańka2-0/+52
Query API doesn't directly use Status API code, in order to allow for querying derived resources that might not be typically returned by Status API like replicasets for deployment. Issue-ID: MULTICLOUD-1305 Signed-off-by: Konrad Bańka <k.banka@samsung.com> Change-Id: If15adce23845880f3e6771cc8eab78a78ab13517
2021-02-23Move Day2 Config Values API to new endpointKonrad Bańka2-30/+20
Issue-ID: MULTICLOUD-1280 Signed-off-by: Konrad Bańka <k.banka@samsung.com> Change-Id: Ibeb0920b4ce083f4294b83c887fc7c793a2c3df5
2020-09-30Fix Status API to actually provide instance statusKonrad Bańka1-85/+0
Provide information about instance resources and Pods inside status response. Issue-ID: MULTICLOUD-1177 Signed-off-by: Konrad Bańka <k.banka@samsung.com> Change-Id: Iee6fd56120d091dddfa6b6d0e4aa7eb36d40e888
2020-09-08Provide capability to specify release-name during instantiationKonrad Bańka1-0/+8
Allow release-name property to be provided during instantiation that, if provided, overrides release-name specified in profile. Additionally updated Makefile to allow easy compilation with different go version easily. Issue-ID: MULTICLOUD-1175 Signed-off-by: Konrad Bańka <k.banka@samsung.com> Change-Id: Id8db484369045cfb0bc99543a80317644fc838f9
2020-05-06Revert "Update brokerhandler API to conform with /v1/ path pattern"0.6.0Konrad Banka2-9/+8
This reverts commit 4ae60c1b50750587ab9d3960617a47d7db57b311. Reason for revert: Unable to reproduce bug, reverting fix implementation Issue-ID: MULTICLOUD-1053 Change-Id: Icc12260f9c122c6e5ac038d07a0e6cd56201e3ba Signed-off-by: Konrad Bańka <k.banka@samsung.com>
2020-04-16Update brokerhandler API to conform with /v1/ path patternKonrad Bańka2-8/+9
Issue-ID: MULTICLOUD-1053 Signed-off-by: Konrad Bańka <k.banka@samsung.com> Change-Id: I8f567bed2783e7257784cd4ce4c9f76207634e7a
2020-02-20Provide OverrideParameters capability for infra_workload APIKonrad Bańka2-86/+262
Provide parameters provided in sdnc, oof and user directives as override parameters for instantiate call. Issue-ID: MULTICLOUD-838 Signed-off-by: Konrad Bańka <k.banka@samsung.com> Change-Id: I69c6dab82ee233b2365a656bfaf1c7d64e375c98
2020-01-23Merge "Update profilehandler comments"Ritu Sood1-9/+9
2020-01-10Merge "Instantiate infra_workload based on vf-module-*-ids"Ritu Sood2-42/+21
2020-01-07Change missing profile HTTP response code to 404Konrad Bańka2-4/+20
Issue-ID: MULTICLOUD-967 Signed-off-by: Konrad Bańka <k.banka@samsung.com> Change-Id: I3d213f65ee37443a55b74255b475e27c0d93cf2c
2020-01-07Instantiate infra_workload based on vf-module-*-idsKonrad Bańka2-42/+21
Deprecate k8s-rb-definition-* parameters from sdnc_directives in favor of vf-module-*-id that are used by newer artifact broker. Issue-ID: MULTICLOUD-836 Signed-off-by: Konrad Bańka <k.banka@samsung.com> Change-Id: I26ae16bd53ced56ae11523584f900a102f6e0bb9
2019-11-26Switch instantiation parameters source from user to sdnc parametersKonrad Bańka2-13/+40
Issue-ID: MULTICLOUD-941 Signed-off-by: Konrad Bańka <k.banka@samsung.com> Change-Id: I3a6c67eb442023f64600b65f5af54a49117a8c51
2019-11-08Update logutils to support multiple fieldsKiran Kamineni1-20/+60
Added support for multiple fields and updated instancehandler and app/client.go to use the new functions Issue-ID: MULTICLOUD-577 Change-Id: I7cc04f67e72448aa121d10cfd80d66d544981933 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-10-29Update profilehandler commentsMarcus G K Williams1-9/+9
Issue-ID: MULTICLOUD-828 Signed-off-by: Marcus G K Williams <marcus.williams@intel.com> Change-Id: Ib7678c6829916cb7e29611d151f7d67c2a274faf
2019-10-25Implementing suggested changessanjaymekhale1-0/+18
Renamed package from logs to logutils Issue-ID: MULTICLOUD-577 Change-Id: I05e2acbfbb5dd79bd26df73e0ad64c2068b9f6e5 Signed-off-by: sanjaymekhale <sm00557598@techmahindra.com>
2019-10-15Add unit testsKiran Kamineni1-3/+97
Add unit tests for the handler as well as backend status function Issue-ID: MULTICLOUD-675 Change-Id: I4c73e2c18f243702f3e791fec48d4bc5023cafd5 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-10-15Add a status getter api endpointKiran Kamineni2-0/+21
Add a status endpoint to get status of instances. Status information will be added to the database asynchronously. Issue-ID: MULTICLOUD-675 Change-Id: Ia7d79a6f18f01bf24f2690caf74a48c2a082bd73 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-10-11Remove unused codeKiran Kamineni2-127/+0
Remove unused code. This is part of the old legacy code and will anyway have to be re-implemented whenever the update functionality gets added. Issue-ID: MULTICLOUD-666 Change-Id: I02a91a2b221da9d82433f8c2ee1dd014a81e4f4d Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-08-13Add query parameters support to instance APIKiran Kamineni4-22/+61
Add support for query parameters to find instances with rb-name, rb-version, profile-name as query parameters eg: curl IP:PORT/v1/instance?rb-name=test&rb-version=v1 Issue-ID: MULTICLOUD-662 Change-Id: If68c87885c8b8dd097cbb3860e8c7320310a6ef7 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-07-23Merge "Add a listallhandler to definitions api"Bin Yang3-1/+102
2019-07-23Merge "Add a list api for instances"Bin Yang3-2/+135
2019-07-18Add list api for profilesKiran Kamineni3-1/+126
Add a list api for profiles for a specific definition and version. GET /v1/rb/definition/name/version/profile will list all the profiles. Issue-ID: MULTICLOUD-730 Change-Id: If1b8e6910c276a0f7139ab13340721c6ec8a49e8 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-07-18Add a listallhandler to definitions apiKiran Kamineni3-1/+102
GET calls to the v1/rb/definition will return all definitions and their versions Issue-ID: MULTICLOUD-715 Change-Id: Ia0951ac83283830e475bf727e7d5ced7aab3add2 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-07-18Add a list api for instancesKiran Kamineni3-2/+135
curl -X GET /v1/instance returns all the instances created. It returns abbreviated instances for improved readability. For details on what resources were created for each instance, use the ID with GET. Issue-ID: MULTICLOUD-715 Change-Id: I05afe0fd2c254acbca4329289c81545f95c9fac5 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-06-26Move connectionhandler.go into api packageKiran Kamineni7-25/+176
Move connectionhandler.go into api package This brings it inline with the other API handlers Issue-ID: MULTICLOUD-666 Change-Id: Ia3b832159f537c6d8d8ecc93b56bc9b085649f7e Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-06-24Change the import paths for go get accessKiran Kamineni13-18/+18
This allows other projects to do a go get and use this repo. go get github.com/multicloud-k8s/src/k8splugin will do the job. import github.com/multicloud-k8s/src/k8splugin will import the root package Issue-ID: MULTICLOUD-666 Change-Id: I2f41c88c5a7fb3305b78cce8a83a0e102baa444c Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-05-23Update broker responses to match spec and SOKiran Kamineni4-35/+245
The broker responses need to match the spec and what SO expects as responses. CREATE_COMPLETE instead of CREATED in both POST and GET DELETE now returns a response body GET by name is now supported Name is an alias for vf_module_id which is expected to be provided as an attribute in sdnc_directives in the original POST request Issue-ID: MULTICLOUD-645 Change-Id: Ifeca755a07298d0a858cbe9e80f9ce654d6d21b8 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-05-22Minor change to instance responseKiran Kamineni2-24/+36
Minor change to instance response. Now it includes the full request parameters in the response. Issue-ID: MULTICLOUD-649 Change-Id: Ia4a7e479f842dd580bcfb13aa91dc0b0a456cf25 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-05-16Support user_directives that are attributes listsKiran Kamineni2-14/+81
Support the attributes in user_directives attributes are lists of the following form: "attributes": [ { "attribute_value": "foo", "attribute_name": "bar" }, { "attribute_value": "value2", "attribute_name": "name2" } ] Issue-ID: ONAPARC-349 Change-Id: I576bc251d1566dc26696f12f826a09bacb7417a0 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-05-16Merge "Move config to app and connect to instance"Bin Yang2-9/+10
2019-05-15Move config to app and connect to instanceKiran Kamineni2-9/+10
Move config instantiation to app and connect it to the instance to allow updates and so on. Issue-ID: MULTICLOUD-464 Change-Id: Ic994ef78a6e0d2db5e695e33b7b8a302c74c10da Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-05-15Remove extra v1 from broker pathKiran Kamineni2-8/+7
Remove extra v1 from path as it is added in the MSB api anyway. Issue-ID: MULTICLOUD-630 Change-Id: Ib7adbf2315e0a3b1fe8170096d877df8f1b64683 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-04-25Adding healthcheck for OOM testingKiran Kamineni3-0/+96
Add a heathcheck endpoint for OOM testing Issue-ID: ONAPARC-363 Change-Id: Id5f77478d331fedb19ac162389d95852e10c5022 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-04-16Replace Kind with GroupVersionKindKiran Kamineni3-24/+113
Kind is not unique to track resources in Kubernetes GroupVersionKind is unique. We are just using that to track our data. It is abstracted behind a couple of new types for templates and resources. This change makes a lot of the old kind based operations redundant and simplified. Issue-ID: MULTICLOUD-573 Change-Id: I8f4ded2ba6a0821a8fbd679dc99ce3a44d805524 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-04-15Fix build errorKiran Kamineni1-3/+3
Build is broken because of some changes that were merged without being rebased on dependent patches. Issue-ID: MULTICLOUD-350 Change-Id: If8bd455103dea3191fedb39ea525efaafb145953 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-04-12Merge "Add Connectivity Info API"Bin Yang1-0/+9
2019-04-12Merge "Day 2 Configuration API's"Bin Yang6-13/+381
2019-04-11Add Connectivity Info APIrsood1-0/+9
API to add connectivity information for Cloud Regions to K8s Plugin https://wiki.onap.org/display/DW/MultiCloud+K8s-Plugin-service+API%27s Change-Id: I0a9166df9b076a7fdacf0b2f9e51a9cdebe4b621 Signed-off-by: rsood <ritu.sood@intel.com> Issue-ID: MULTICLOUD-292 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-04-11Add support for so integrationKiran Kamineni3-0/+395
Add support for the multicloud-api that is called by SO for instantiation. Issue-ID: MULTICLOUD-350 Change-Id: Icf9137dae9796ac256c3319b49af6c30b275a4a9 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-04-11Day 2 Configuration API'srsood6-13/+381
This patch adds Configuration API's https://wiki.onap.org/display/DW/MultiCloud+K8s-Plugin-service+API%27s Change-Id: I52ebfc5aa980ec8af4a31569d569216e9a2a760c Issue-ID: MULTICLOUD-464 Signed-off-by: rsood <ritu.sood@intel.com>
2019-04-04Use consistent naming for Name and VersionKiran Kamineni2-20/+20
Definition Name and Definition Version are now using the consistent naming similar to the Profile and instance structure. Name becomes RBName Version becomes RBVersion Issue-ID: MULTICLOUD-350 Change-Id: Ifc329d4979a06cb017c6f9d916c227c696b664e0 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-04-04Use common code for executeRequestKiran Kamineni2-27/+9
Use the common executeRequest function instead of multiple copies of the same lines for test requests Issue-ID: MULTICLOUD-557 Change-Id: Icde498b55592333af265fc348f3a286a59b9b61c Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-04-04Merge "Add url path tests to definition handler"Bin Yang1-33/+38
2019-04-04Merge "Add url path tests to profile handler"Bin Yang1-49/+45
2019-04-03Add url path tests to profile handlerKiran Kamineni1-49/+45
Improve the profile tests by testing the url path parameters as well. Issue-ID: MULTICLOUD-547 Change-Id: Ib31a42cc6c3622d17ddc37eb0506ca991d2334c0 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-04-03Add url path tests to definition handlerKiran Kamineni1-33/+38
Url path parameters are not tested in the current unit tests. This is fixed with the use of the same router that is used by the main program. Issue-ID: MULTICLOUD-547 Change-Id: Ie162150fb1ecf22766011339e68e03f1067779a0 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-04-03Refactor instance codeKiran Kamineni5-1100/+533
Issue-ID: MULTICLOUD-350 Change-Id: I2574d94e4ebada1e138913b2a03549dd90906d7b Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
2019-04-02Merge "Make profile key explicit"Victor Morales3-7/+7