-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[477 idl part2] SR.create API change and sharable flag #202
Conversation
Signed-off-by: Jon Ludlam <jonathan.ludlam@citrix.com>
There is a default_vdi_info in Storage_interface and another in Storage_client. Just define it in one place to make updating fields easier and avoid diverging. Signed-off-by: Edwin Török <edvin.torok@citrix.com>
The HA statefile and redo log needs to be attachable from multiple hosts, which used to be done as a side-effect of sm-config:type=raw in SMAPIv1. For SMAPIv3 we'll introduce a sharable flag in the vdi creation phase to make the semantics clearer, because for GFS2 what matters is not whether the file format is raw or not, but whether it can be attached from multiple hosts. Signed-off-by: Edwin Török <edvin.torok@citrix.com>
…ng place Signed-off-by: Edwin Török <edvin.torok@citrix.com>
1 similar comment
@@ -266,7 +271,7 @@ module SR = struct | |||
(** Functions which manipulate SRs *) | |||
|
|||
(** [create dbg sr name_label name_description device_config physical_size] creates an sr with id [sr] *) | |||
external create : dbg:debug_info -> sr:sr -> name_label:string -> name_description:string -> device_config:(string * string) list -> physical_size:int64 -> unit = "" | |||
external create : dbg:debug_info -> sr:sr -> name_label:string -> name_description:string -> device_config:(string * string) list -> physical_size:int64 -> (string * string) list = "" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So it returns the UUID as a string * string list? 😮
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It returns an updated device-config, containing the UUID. I think it is the equivalent of { foo with uuid = ...}
, except device-config is a string map not a regular type.
This is part of the SMAPIv3 interface change from
feature/REQ477/master
branch (that branch had 2 full nightlies run on it).SMAPIv3 requires a uuid returned from SR.create, this PR together with the one for XAPI changes SMAPIv2 to allow for that (SMAPIv1 is not affected).
This is a breaking API change for SMAPIv3 plugins!
Also expose the
sharable
field to SMAPIv3 (required for the HA statefile and redolog), internally XAPI already tracked this field. SMAPIv1 looked insm-config
to find this out, no change there.This PR needs to be merged together with these ones otherwise the build breaks:
xapi-project/sm-cli#26
xapi-project/xapi-storage#70
xapi-project/xapi-storage-script#56
xapi-project/xen-api#3433
I've done a build of these changes separately on the internal branch
private/edvint/477-idl-part2