History | View | Annotate | Download (50 kB)
Remove typo from RAPI documentation
"be used instead." was repeated twice.
Signed-off-by: Michele Tartara <mtartara@google.com>Reviewed-by: Klaus Aehlig <aehlig@google.com>
Add multiple min/max specs in instance policy
Now instance policies can contain more than one min/max specs. This is themain element of the "Constrained instance sizes" section in the"Partitioned Ganeti" design doc.
This is a big patch, but changing the type of a configuration item requires...
Merge branch 'stable-2.7' into stable-2.8
Conflicts: NEWS doc/rapi.rst
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Guido Trotter <ultrotter@google.com>
Improve RAPI documentation for command line usage
Provide some more insights about how to use the RAPI from the command linethrough the "curl" command.
Signed-off-by: Michele Tartara <mtartara@google.com>Reviewed-by: Guido Trotter <ultrotter@google.com>
More info on using the RAPI
Add some additional information about how to use/test the RAPI,including how to specify authentication credentials.
Cherry picked from 681f4f7bb95a2b467f917c84a68ccf9aa7665763 on master.
Signed-off-by: Michele Tartara <mtartara@google.com>...
Refactor ispecs in ipolicy structures
Minimum and maximum instance specs are put together into a single elementof the instance policy. This is in preparation for introducing multiplemin/max specs.
Signed-off-by: Bernardo Dal Seno <bdalseno@google.com>...
Signed-off-by: Michele Tartara <mtartara@google.com>Reviewed-by: Helga Velroyen <helgav@google.com>
Add constants for storage types to constants.py
This patch adds the currently known and used storage methods to theconstants.py file. Note that storage types are different from disktemplates. For example both disk templates, drbd and plain, use lvmstorage types....
rapi.rst: Replace manual method lists with directive
Many resources, but not all, list their supported methods. With a newreST directive, this list is now automatically generated and also liststhe required permissions.
Signed-off-by: Michael Hanselmann <hansmi@google.com>...
Improve RAPI documentation on users and options
- Document fields in “rapi/users” file in the order they appear (username, password, options)- Mention new “--require-authentication” option- Clarify use of “write” on “GET” method
Build table with access permissions for RAPI resources
Sometimes it can be difficult to determine the access permissions neededfor a certain RAPI resource without looking at code. This table, addedat the end of “rapi.rst”, shows all resources and the permissions needed...
RAPI documentation: Add link targets
A newly added table of RAPI access permissions will link to allresources and their supported methods. For this reason link targets needto be added.
The GET method on “/2/nodes/[node_name]” was not separately mentioned....
RAPI documentation: Assertion for console fields
Assert that the documented fields are equal to those in the actualobject.
Signed-off-by: Michael Hanselmann <hansmi@google.com>Reviewed-by: Guido Trotter <ultrotter@google.com>
Remove network_type slot (Issue 363)
This slot was not used by Ganeti so the same info can beprovided via tags. In order not to break configuration datawe add a FromDict() method in Network config object thatremoves the deprecated network_type (if found) and then invoke...
RAPI documentation fix and update
- Mention user capabilities in security.rst- Replace “query” with “read” in RAPI documentation
Signed-off-by: Michael Hanselmann <hansmi@google.com>Reviewed-by: Iustin Pop <iustin@google.com>
doc/rapi.rst: Add ECODE_TEMP_NORES
The assertion was failing as ECODE_TEMP_NORES was not documented.
RAPI: Clarify non-exhaustive nature of examples
The examples given in the RAPI documentation are not exhaustive. Thispatch tries to clarify this by adding ellipses where appropriate. Oneexample's indentation is also fixed.
Fixes to pass unittests (make check)
Signed-off-by: Dimitris Aragiorgis <dimara@grnet.gr>Reviewed-by: Iustin Pop <iustin@google.com>
rapi: Add new user option for querying
This was requested in issue 301. Before this patch, requests to“/2/query/*” and “/2/instances/*/console” would require authenticationwith a user with write access. Since that is not strictly necessary, anew user option named “read” is added....
Convert two more 'sh' highlight styles to 'shell-example'
This is straightforward; only one shell example remained, but as weprocess the man pages via pandoc and not sphinx, it's not actuallyused, we leave it as such for now.
Signed-off-by: Iustin Pop <iustin@google.com>...
Adding RAPI resource for multi-allocation
This is straightforward.
Signed-off-by: René Nussbaumer <rn@google.com>Reviewed-by: Michael Hanselmann <hansmi@google.com>
Fix inconsistent punctuation in rapi docs and opcodes
While reviewing the RAPI docs (for commit 003306f9), I realised thatthe punctuation used in RAPI is inconsistent, especially with regardsto definition lists.
This patch changes all such lists to not have punctuation, except for...
ipolicy: Keep track of spindle usage
Signed-off-by: René Nussbaumer <rn@google.com>Reviewed-by: Iustin Pop <iustin@google.com>
Add job result descriptions to RAPI documentation
Add ipolicy parameter spindle_ratio
This will represent the instance (count) per spindle_count of theirnode(s). Debatable whether we need to add a per-instancespindle_weight.
Signed-off-by: Iustin Pop <iustin@google.com>Reviewed-by: Michael Hanselmann <hansmi@google.com>
doc/rapi.rst: Document ipolicy parameter
Merge branch 'devel-2.5'
Merge branch 'stable-2.5' into devel-2.5
Document OpNodeMigrate's result for RAPI
- Commit b7a1c8161 changed the LU to generate jobs- Mention documented results in NEWS
RAPI: Fix resource for replacing disks
Commit d1c172deb4f inadvertently changes the“/2/instances/[instance_name]/replace-disks” resource to use bodyparameters. There were no QA tests and the issue wasn't noticed.
This patch re-introduces support for query parameters and adds a QA...
Fix RAPI documentation build
mumble
rapi: Add resource for modifying node
A separate patch will add “auto-promote” through“/2/nodes/[node_name]/role”.
RAPI: Add resource to powercycle node
RAPI: Add resource to recreate instance's disks
This was still missing from RAPI.
Fix RAPI documentation for gnt-instance console
Fix a failing pyassert in the RAPI docs and update it to reflect theaddition of SPICE to gnt-instance console.
Signed-off-by: Andrea Spadaccini <spadaccio@google.com>Reviewed-by: Michael Hanselmann <hansmi@google.com>
rapi: Re-add “/2” resource
Like “/”, it'll just return a JSON null.
Signed-off-by: Michael Hanselmann <hansmi@google.com>Reviewed-by: René Nussbaumer <rn@google.com>
rapi: Remove “/2” resource, deprecate “/”
These were never really useful. Neither gave a complete list ofavailable resources—the documentation in doc/rapi.rst is much better atthat.
Since some monitoring code might use the “/” resource it's kept around...
Document job results for RAPI where possible
Some opcodes aren't documented yet.
Documentation fixes and clarification
- In README, refer to “install.rst”, not “install.html”- In rapi.rst, wrap line longer than 72 characters- In rlib2.py, update and clarify description of POST vs. PUT
List returned fields in RAPI documentation
Also replace console types with constants.
rapi: Bulk support for jobs
This was requested in issue 181.
Implement instance failover via RAPI
No idea why this was missed before.
Merge branch 'devel-2.4'
RAPI: Document all feature strings
- Use constants and an assertion- Update documentation for node migration
Change RAPI for new node evacuation opcode
The change is not backwards compatible, see the updated NEWS file.
Signed-off-by: Michael Hanselmann <hansmi@google.com>Reviewed-by: Iustin Pop <iustin@google.com>Reviewed-by: René Nussbaumer <rn@google.com>
Fix RAPI documentation regarding master role
Signed-off-by: Iustin Pop <iustin@google.com>Reviewed-by: René Nussbaumer <rn@google.com>
RAPI: Add support for tagging node groups
RAPI: Convert instance shutdown to the new FillOpCode
RAPI server: Drop support for instance creation format 0
Ganeti 2.1.3, released in June 2010, added support for a new, extensibleinstance creation request format, called version 1. This patch removessupport for the old and undocumented version 0 format....
RAPI: Document need for Content-type header in requests
This was added to the NEWS file in commit ab221ddf, but neverdocumented properly.
RAPI: Add support for querying resources
- Access is only permitted for authenticated clients (queries can return sensitive data)- Filters can be specified when sending a PUT request- Updates RAPI client, documentation and tests
RAPI documentation: Use constants and assertions
This doesn't cover everything yet, but it's a good demonstration on howto use “pyeval” and “pyassert”.
RAPI: Use FillOpCode for adding node group
RAPI: Use FillOpCode for renaming groups
RAPI: Clean up instance creation, use generated docs
- Use FillOpCode and unify parameter names between RAPI and opcode- Generate parameter documentation- Improve opcode parameter documentation
RAPI: Generate documentation for assigning nodes to groups
RAPI: Use FillOpCode for modifying node group
RAPI: Use FillOpCode for renaming instances
Generate parts of RAPI documentation from opcodes
This replaces hardcoded lists of parameters with automatically generatedones, making maintenance easier.
Add RAPI resource for instance console
Expose OpAssignGroupNodes over RAPI and RAPI client
Signed-off-by: Adeodato Simo <dato@google.com>Reviewed-by: Michael Hanselmann <hansmi@google.com>
RAPI: Add resource to grow instance disk
RAPI: Add resource to modify cluster
Expose OpSetGroupParams in RAPI and RAPI client
This creates the /2/groups/<name>/modify resource; at the moment, only the"alloc_policy" attribute can be modified.
Group operations: expose add/remove/rename in RAPI
Querying node groups: RAPI support
This implements /groups and /groups/%s RAPI end points.
Signed-off-by: Adeodato Simo <dato@google.com>Signed-off-by: Iustin Pop <iustin@google.com>Reviewed-by: Iustin Pop <iustin@google.com>
RAPI: Implement OS parameters for instance reinstallation
Dictionaries are hard to encode into query strings, therefore the“/2/instances/[instance_name]/reinstall” resource is changed to acceptits parameters via the request body. The old query string parameters are...
Move “rapi_users” file into separate directory
This reduces the number of notifications in “ganeti-rapi”. Until now itwas notified for every change in …/lib/ganeti and had to check whetherthe users file was affected. A symlink is always created in cfgupgrade...
RAPI: implement no_install during instance creation
Signed-off-by: Lance Albertson <ramereth@gmail.com>Signed-off-by: Iustin Pop <iustin@google.com>Reviewed-by: Iustin Pop <iustin@google.com>Reviewed-by: Michael Hanselmann <hansmi@google.com>
ganeti-rapi: Watch directory, not file for user file changes
We noticed several issues when just watching the file, among them raceconditions upon replacing the file using rename(2) (the new watcherwould be created too soon). By just watching the directory for events on...
Merge branch 'devel-2.2'
Update RAPI documentation for /2/nodes/[node_name]/migrate
This was forgotten in commit 52194140.
RAPI server: Move user file watching out, update documentation
This patch moves the code watching the users file into aa separate class to not mix it with HTTP serving. The usersfile is now driven from outside the HTTP server class.
Also the documentation is updated to mention the automatic...
Use Sphinx' :rfc: extension to refer to RFCs
Document non-standard usage of JSON in RAPI
This was requested in issue 118.
RAPI: Allow modifying instance
Small fixes for instance creation via RAPI documentation
- Inconsistencies- Missing types
Allow renaming instances via RAPI
RAPI: Support migrating instances
Update RAPI documentation for the OS changes
Use reserved documentation IPs and domains
Use RFC 5737 IP addresses and RFC 2606 domain names in allunittests, docs, qa and docstrings.
Signed-off-by: Manuel Franceschini <livewire@google.com>Reviewed-by: Iustin Pop <iustin@google.com>
RAPI: switch evacuate node to the new model
This patch removes the last use of the old-style OpEvacuateNode. It alsofixes the dry-run mode for this RAPI resource - the dry-run parameterwas not used at all before.
RAPI changes for instance moves
Two new resources are added:- /2/instances/$name/prepare-export- /2/instances/$name/export
The documentation for the existing resource for creating instances is updatedfor remote imports. The RAPI client is extended for the new resources....
Add missing documentation for RAPI instance creation mode
RAPI: Add new request data format for instance creation
As mentioned in commit d975f482d, the current way of creating aninstance via RAPI is not very flexible. With this patch, a newinstance creation request data format is introduced and documented.Support can be detected by checking the list of features returned...
Mention RAPI client in documentation
Add new /2/features RAPI resource
The /2/features RAPI resource can be used to detect optionalfeatures implemented by the RAPI server. This will be usedto recognize servers implementing a new request format forinstance creation requests.
RAPI: Allow waiting for job changes
Improving the RAPI documentation
Adding missing documentation to make the docs better
Also fixed a typo I noticed.
Update documentation for hashed passwords
A couple of doc updates
Clarify the fact that temporary HV/BE params in instance start overrideand do not extend the configured parameters; and change the instancelist headers from HVM_* to * since many of the parameters apply to KVMtoo. Also fix a typo in the rapi documention for '/2/nodes'....
Update RAPI documentation on job results
This documents the new error classifier added for OpPrereqError.
Add remote API users and passwords documentation