[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-API] xapi-client
> On 9 Jan 2015, at 15:51, buzz heavyyear <buzzheavyyear@xxxxxxxxxxx> wrote: > > Ah, so you haven't installed xapi/xenserver on cubieboard yet? ;) /me suddenly realises his cubieboard is unplugged and swiftly turns it back on again ;) I’d like to improve the OCaml bindings so I’m interested in any experiences you have (positive or negative). My top 2 usability annoyances are: 1. we use labelled arguments but not optional arguments, even when there is a defined default value. 2. we should allow the client to register some kind of nice transient connection failure handler/policy: at the moment every RPC invocation can fail and it can be annoying to handle. Sometimes you just wish to say: keep retrying and bail out after n seconds. > > -n > > Subject: Re: [Xen-API] xapi-client > From: anil@xxxxxxxxxx > Date: Fri, 9 Jan 2015 15:35:12 +0000 > CC: xen-api@xxxxxxxxxxxxx > To: buzzheavyyear@xxxxxxxxxxx > > It so happens that I just (yesterday) also installed XenServer on x86 and > would like to get the XenAPI client bindings from OCaml, and so am most > interested in this! > > -a > > On 9 Jan 2015, at 09:56, buzz heavyyear <buzzheavyyear@xxxxxxxxxxx> wrote: > > Hello everyone, > > Just to introduce myself as someone starting out with xapi on arm. Apologies > in advance for any future trivial questions to the list! > > I've been trying to compile the lwt_test/list_vms.ml with the following > _oasis file: > > OASISFormat: 0.4 > Name: list_vms_lwt > Version: 0.1 > Synopsis: Xapi Client Example > Authors: njb > License: PROP > BuildTools: ocamlbuild > Plugins: META (0.4), DevFiles (0.4) > > Executable "list_vms_lwt" > Path: . > MainIs: list_vms.ml > BuildDepends: xen-api-client, xen-api-client.lwt, lwt, lwt.ssl, lwt.unix > CompiledObject: best > > > > With opam up to date with lwt etc., I get: > > File "list_vms.ml", line 32, characters 76-78: > Error: Syntax error > Command exited with code 2. > E: Failure("Command ''/usr/bin/ocamlbuild' list_vms.native -tag debug' > terminated with error code 10”) This almost certainly means it needs the lwt.syntax and didn’t have it. Try adding “, lwt.syntax” to the BuildDepends and “oasis setup” “make”. > > > When I modify _oasis to include the lwt Build flag: > > OASISFormat: 0.4 > Name: list_vms_lwt > Version: 0.1 > Synopsis: Xapi Client Example > Authors: njb > License: PROP > BuildTools: ocamlbuild > Plugins: META (0.4), DevFiles (0.4) > > Flag lwt > Description: build the Lwt library > Default: false > > Executable "list_vms_lwt" > Path: . > MainIs: list_vms.ml > Install$: flag(lwt) > Build$: flag(lwt) > BuildDepends: xen-api-client, xen-api-client.lwt, lwt, lwt.ssl, lwt.unix > CompiledObject: best > > > > > when running make I get : > > ocaml setup.ml -build > /usr/bin/ocamlopt.opt unix.cmxa -I /usr/lib/ocaml/ocamlbuild > /usr/lib/ocaml/ocamlbuild/ocamlbuildlib.cmxa myocamlbuild.ml > /usr/lib/ocaml/ocamlbuild/ocamlbuild.cmx -o myocamlbuild > MAKE SUCCESSFUL (total time: 1s) > > > .... but no executable. Hmm, the lwt flag defaults to false and is set to true by the Makefile: LWT ?= $(shell if ocamlfind query lwt.ssl >/dev/null 2>&1; then echo --enable-lwt; fi) So it looks like you need to “opam install ssl” Cheers, Dave > > Could somebody possibly point out my error? > > Thanks > Nick > _______________________________________________ > Xen-api mailing list > Xen-api@xxxxxxxxxxxxx > http://lists.xen.org/cgi-bin/mailman/listinfo/xen-api > > _______________________________________________ > Xen-api mailing list > Xen-api@xxxxxxxxxxxxx > http://lists.xen.org/cgi-bin/mailman/listinfo/xen-api _______________________________________________ Xen-api mailing list Xen-api@xxxxxxxxxxxxx http://lists.xen.org/cgi-bin/mailman/listinfo/xen-api
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |