Commit Graph

126 Commits

Author SHA1 Message Date
ricolin 9bbf3d8a97 retire js-openstack-lib
This project is being retired

Release update: https://review.opendev.org/c/openstack/governance/+/771789

ML: http://lists.openstack.org/pipermail/openstack-discuss/2021-January/019847.html
Codesearch: https://codesearch.opendev.org/?q=js-openstack-lib&i=nope&files=&excludeFiles=&repos=

Change-Id: I94c42c0ac3ec23c685d1b50d35383ad078916f06
2023-10-19 12:29:20 -07:00
Monty Taylor 346f7eeda0 Update eslint and switch to standard
The openstack eslint package is just really not needed at this
point. Use standardjs and run --fix on it.

Switch away from using node 8 to run linters and tests.

Change-Id: I51f68d4ec30c8da5d1601ef00045e53f90d0554b
2020-06-12 13:04:59 -05:00
Monty Taylor 7f843d7ecb Update babel, webpack, karma, jasmine and istanbul
Update to babel v7 and webpack v4

Remove runtime depend on corejs-2 which is
unsupported. Just switch to runtime which requires polyfills be
provided by the end user.

Remove NSP - the service is being shut down and the important bits
are built in to npm now.

istanbul has been replaced by the nyc runner. Update karma
to latest.

Update yaml-loader and json-loader

Disable browser testing for now - we'll bring it back in a followup.

Change-Id: I45d1f77bb43e5d67f4154c5149fac77b853e3686
2020-06-12 12:35:09 -05:00
Radosław Piliszek 8354146c11 CI: New jobs
This follows removal of jobs from project-config. [1]

New jobs use newer node versions and new Zuul v3 format,
reusing devstack for deployment of OpenStack for functional
testing of jslib.

Version tests have been adapted to follow support logic
already in place instead of hardcoded supported versions.

Includes workaround (fixup) of devstack's bug. [2]

Move the functional test to experimental for now, because version
discovery doesn't work right and Firefox is generally grumpy.
We want to get the structural stuff in first.

[1] https://review.opendev.org/702030
[2] https://bugs.launchpad.net/devstack/+bug/1860287

Depends-on: https://review.opendev.org/704882
Depends-on: https://review.opendev.org/726547
Co-authored-by: Monty Taylor <mordred@inaugust.com>
Change-Id: I197eb2b59be7a49d168edf09d554b444bbcc29b2
2020-06-12 17:06:24 +00:00
OpenDev Sysadmins a88f833861 OpenDev Migration Patch
This commit was bulk generated and pushed by the OpenDev sysadmins
as a part of the Git hosting and code review systems migration
detailed in these mailing list posts:

http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003603.html
http://lists.openstack.org/pipermail/openstack-discuss/2019-April/004920.html

Attempts have been made to correct repository namespaces and
hostnames based on simple pattern matching, but it's possible some
were updated incorrectly or missed entirely. Please reach out to us
via the contact information listed at https://opendev.org/ with any
questions you may have.
2019-04-19 19:43:08 +00:00
Ian Wienand 448cc5df6b Replace openstack.org git:// URLs with https://
This is a mechanically generated change to replace openstack.org
git:// URLs with https:// equivalents.

This is in aid of a planned future move of the git hosting
infrastructure to a self-hosted instance of gitea (https://gitea.io),
which does not support the git wire protocol at this stage.

This update should result in no functional change.

For more information see the thread at

 http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003825.html

Change-Id: Iec8bb72bc9036beac9eea7f1c9dd686ddb0f5d02
2019-03-24 20:33:56 +00:00
gengchc2 ff006579b3 Use https instead of http for git.openstack.org
Trivialfix

Change-Id: Iae695850b7f9121e0532823ccc99589f23cd985e
2017-02-12 23:12:19 +00:00
Corentin Ardeois 4f19bfad3b Update glance version
This patch will fix functionnal test by updating glance version
to 2.5

Change-Id: Icdad36fad58c01c15b61ad4310c8d96c5e8a4f37
2017-02-08 20:54:39 -05:00
Jenkins 76da62a7c8 Merge "Add flavorList to Openstack wrapper" 2017-01-25 13:58:50 +00:00
Anh Tran 9136e573af Typo fix: constistent => consistent
Change-Id: Id5ffafd72fe3870f4f32123adf141f563f97cb75
2017-01-24 13:22:35 +07:00
Jenkins e8d6bcdda6 Merge "Created Nova service with flavorList method." 2017-01-20 14:47:23 +00:00
Corentin Ardeois b362b89813 Update supported keystone version
This patch will fix functionnal tests

Change-Id: Iffd37201e7b3f49468b964bd357d1d94854e4ce7
2017-01-19 19:37:59 -05:00
Dong Ma cfc2f665d4 Add flavorList to Openstack wrapper
This patch integrated nova into Openstack wrapper, allowing
flavorList to be used

Change-Id: Ic149ce2bd11bc439431cca0e2aa294874708d234
2016-12-04 07:18:15 -08:00
Michael Krotscheck 7ee22fdfbe Created Nova service with flavorList method.
We can now query for flavors.

Change-Id: Ia19afa530ae8c2df60db740cec9267fe240978c0
2016-12-02 17:49:37 -05:00
Jenkins cf336dec98 Merge "Add imageList to Openstack wrapper" 2016-12-02 21:55:05 +00:00
Jenkins f96704d7e4 Merge "Use serviceEndpoint compatible with versions" 2016-12-02 13:03:22 +00:00
Flavio Percoco 02fb8b1d62 Show team and repo badges on README
This patch adds the team's and repository's badges to the README file.
The motivation behind this is to communicate the project status and
features at first glance.

For more information about this effort, please read this email thread:

http://lists.openstack.org/pipermail/openstack-dev/2016-October/105562.html

To see an example of how this would look like check:

https://gist.github.com/f58218a48a92e39d9805b29538e63c50

Change-Id: Ie3313879c1242b12c1f6a017a40bf44045738838
2016-11-25 16:49:31 +01:00
Corentin Ardeois beec17c6e4 Use serviceEndpoint compatible with versions
This patch adds a more flexible selection of version in AbstractService.
A version will be selected if it's compatible with the 'supportedVersions'.
Example:
  supportedVersions = ['v3.1'];
  All minor versions above 3.1 will be compatible (3.1.2, 3.2, 3.3 etc)
  However 4.x will not be compatible

Change-Id: Icd540449ebf6a09d9bb7e1d25a85e2dbe787c5a4
2016-11-23 09:53:27 -05:00
Corentin Ardeois 0ba0ea9668 Add imageList to Openstack wrapper
This patch integrated glance into Openstack wrapper, allowing
imageList to be  used

Change-Id: I64e5d432224aa673ab1e6ace3e927af2f8b3a13f
2016-11-21 15:17:44 -05:00
Yujun Zhang cffe4a7c94 Ignore compiling output
Change-Id: Idb8afdb2e62bd40321dfd7837268d422b0ea053c
2016-11-03 13:49:20 +08:00
Jenkins 3c9ddf506e Merge "Update OpenStack documentation template" 2016-11-01 10:38:22 +00:00
Corentin Ardeois 33186289aa Update OpenStack documentation template
As we will upload documentation to developer.openstack.org, this
patch switch sphinx template from 'osloshpinx' to
'openstackdocstheme'

Change-Id: I8073e72c11117ec605dcc8441a0c091f030014f8
2016-10-25 20:20:54 +02:00
Corentin Ardeois 0a4fb9f8b9 Added support for multi-region catalog
OpenStack wrapper will read the 'region_name' from config, and use
the correct endpoint matching this region

Change-Id: I01049f3bed227eb1e11f9a1f7d338177e95aef34
2016-10-25 12:44:20 +02:00
Corentin Ardeois f137472a44 Release 0.0.2
Looks like version 0.0.1 was already published 5 months ago:
https://www.npmjs.com/package/openstack-lib

Change-Id: Ib225e45d6f2370c0cc7f3229916869201620f5d4
2016-10-19 19:52:10 -04:00
Jenkins cdac2da771 Merge "Added documentation for releasing" 2016-10-18 12:39:17 +00:00
Vitaly Kramskikh 9dabaecf11 Added tokenInfo() method to Keystone API
Also fixed nesting in keystone functional tests and deduplicated
mock data for Keystone.

Change-Id: Ia2f0def84d45616eb8c3464b7ba4f47fadfda50d
2016-10-17 21:53:07 +00:00
Jenkins 8828ec6382 Merge "Support names and ids for users, projects and domains in Keystone" 2016-10-17 21:49:20 +00:00
Vitaly Kramskikh 3956dbe65b Support names and ids for users, projects and domains in Keystone
In Keystone API it's possible to provide both ids and names for
users, projects, user domains and project domains. This commit
adds support for this functionality.

Change-Id: I3268bd82cc92a150927c98e0827ebd105d91f5e3
2016-10-17 19:01:11 +03:00
Corentin Ardeois 9903d95abd Add README
This patch adds a readme introducing js-openstack-lib and it's purpose.
A simple example in ES6 was added.

Change-Id: I8c6cedd13b6bcd965b7c88c73c8499f53882c331
2016-10-17 14:41:36 +00:00
Corentin Ardeois c330bbdc62 Added networkList() method to OpenStack wrapper
This patch adds the networkList() method to the OpenStack wrapper
class. This method will initialize `Neutron` instance if needed and
cache it. As neutron needs the URL, `Keystone` instance is also
initialize and cache if needed.

Change-Id: If12af29a86b9856a145c1f91de25eb3473938de5
2016-10-17 10:31:41 -04:00
Corentin Ardeois 58a4b79f65 Added documentation for releasing
This patch document the release guilines to publish js-openstack-lib
to npm.

Change-Id: I54f5ac4b418f057f17f4eaac4e06f72948d1f096
2016-10-12 14:56:00 -04:00
Corentin Ardeois 70a98fb10c Added networkList() method to neutron API
This patch adds the networkList() method to the network API.

Change-Id: Ie0878787169988253a93dd6d67b07a97bd005587
2016-10-05 15:58:42 -04:00
Vitaly Kramskikh 08aa4981f1 Fix unit tests failure caused my fetch-mock update
In some unit tests mockOptions.name was used instead of
mockOptions.matcher, and it was always undefined - this stopped
working with fetch-mock 5.5.0. This commit replaces
mockOptions.name with mockOptions.matcher where it is needed.

Change-Id: I367e1d957ce206c20c6b9d15c9f5ff1a2b285e33
2016-10-04 17:22:14 +03:00
Dong Ma c5c58bcaad Seperate OpenStack class from index.js
This commit to seperate OpenStack class from index.js to new file

Change-Id: If433040fce752e0033eb61139fd8daa9c6dbb669
2016-09-29 09:12:54 -07:00
Dong Ma 9677a06a2d OpenStack wrapper instance
Create wrapper class that takes clouds.yaml instance

Change-Id: I37429b7bda35ca09efc3bf153841d4dc92d96b55
2016-09-28 07:38:46 -07:00
Corentin Ardeois b033ad652e Added Neutron Service
This neutron service follows the same pattern as the glance service,
and provides both version negotiation and endpoint discovery.

Change-Id: Ia2f59213eedf6d7acbb02789ee921c13ff391d09
2016-09-26 14:05:34 -04:00
msmol 7c544e1460 Updates linting rules
New linting rule to disable spaces after functions, before parens
Fixed all new linting errors

I suppose I'd like this to eventually get landed in official
`eslint-config-openstack` project, but for now it is here

Change-Id: I6c77524c5679117ce3b211db0bd9943c5ad5e646
2016-09-23 13:46:04 -04:00
Jenkins 3221a3513d Merge "Export supported services from index.js" 2016-09-23 16:25:48 +00:00
Vitaly Kramskikh c2164e8b15 Export supported services from index.js
This is required to make services provided by library accessible
this way:

  import {Keystone} from 'openstack-lib';

instead of

  import Keystone from 'openstack-lib/dist/keystone';

Also, Test class and dummy functional and unit tests for it were
removed since they aren't needed anymore.

Change-Id: I6bf0b6eebab095d6585d19d8398d9f2ac119cacc
2016-09-22 20:42:27 +03:00
Michael Krotscheck 525d5897c7
Renamed abstract_service to abstractService
Mostly because abstract_serviceTest looks weird.

Change-Id: Ia27b0e0cc70b8e4280f52f40eb78b466e358aa54
2016-09-22 07:39:42 -07:00
Michael Krotscheck c8dfb08c50
Miscellaneous test cleanup.
This patch cleans up our constructor exception tests, and removes
old versions(), version(), and serviceEndpoint() tests that are
now handled in the parent class. Service specific tests have been
kept, and several tests to assert correct API behavior for specific
implementations have been added.

Change-Id: Ib42d94033ebb5613ee7e5c96654ab22f31fe4feb
2016-09-22 07:38:30 -07:00
Michael Krotscheck c8f7503f88
Moved serviceEndpoint() tests into abstract_serviceTest.
Also removed them from child classes.

Change-Id: I291e0d418a4a87ea21bf829712935cd0b1fb6530
2016-09-22 07:36:52 -07:00
Michael Krotscheck abfe901b5e
AbstractService will try to detect the versions resource in more places.
We have no guarantees that the keystone service catalog will have the
root resource of any given service registered. As most versioned API
endpoints require tokens, we can reasonably assume that a 401 will
be encountered. This patch adds an extra check against the response
from the provided URL, and should a 401 be encountered, attempts
to resolve the versions from the root resource of the provided URL.

Change-Id: I655409f0eb9bfbd3489827db46faef026ede82f9
2016-09-22 07:36:39 -07:00
Michael Krotscheck b60cb86755
Created test suite for the AbstractService
This patch creates a test suite for the AbstractService.

Change-Id: I23c61d3f9b77e911e24a740ad489e25d0ac08c86
2016-09-13 22:04:17 -07:00
Corentin Ardeois 773b2b8ee3 Add more service abstraction
This patch add _requestComponents and serviceEndpoint methods to
abstract service, as these methods ared used for both Keystone and
Glance services.

Change-Id: Iccc334c0bbd79c1207855260932dab984f2d9d6c
2016-09-06 13:21:29 -04:00
Jenkins a9bac97fab Merge "Use babel-plugin-transform-runtime instead of babel-polyfill" 2016-09-06 14:15:37 +00:00
Jenkins 10d3fb032c Merge "Create common service version abstraction" 2016-09-05 17:03:19 +00:00
Vitaly Kramskikh e33758f9db Use babel-plugin-transform-runtime instead of babel-polyfill
babel-plugin-transform-runtime allows to reduce size of the
resulting bundle dramatically (from 260kb to 24kb).

Change-Id: I3cceb1caddfb5b0b2048b7d4efc2cebfee26ab91
2016-09-05 19:25:18 +03:00
Jenkins 9ba04d83ab Merge "Created common service abstraction" 2016-09-05 16:19:52 +00:00
Jenkins 3cacbffd74 Merge "Added imageList() method to glance API" 2016-09-05 15:04:54 +00:00