Federations

1 view
Skip to first unread message

Linde, A.E.

unread,
Feb 13, 2009, 6:25:17 AM2/13/09
to skd
Couple of questions and a suggestion:

What query do I post to get a list of federations from a SAC? What is the structure of a federation assertion?

I’m trying to build a SAC browser/query interface using Flex and wondered if we want to allow the user to select which federations are active for a query. Probably only useful for a query depth of 1?

Also, have we got any SACs available for querying on live servers?

T.

--
Tony Linde
Project Manager
Department of Physics & Astronomy
University of Leicester

Kona Andrews

unread,
Feb 13, 2009, 9:53:23 AM2/13/09
to skua-d...@googlegroups.com
Hi Tony,

> Couple of questions and a suggestion:
>
> What query do I post to get a list of federations from a SAC? What is the structure of a federation assertion?
>
> I'm trying to build a SAC browser/query interface using Flex and wondered if we want to allow the user to select which federations are active for a query. Probably only useful for a query depth of 1?

Here are the latest API docs:
http://myskua.org/doc/qsac/interface-http.html

The delegations info is kept in the general SAC metadata; I guess
filtering info as you suggest could go in the incoming query in some
way?

> Also, have we got any SACs available for querying on live servers?

There is generally one here:
http://apps.myskua.org/qsac-latest/
However it isn't currently the latest release (despite the name!)
I'm using a frozen older release, compiled without persistence,
because the relevant tomcat is not running in java 1.6 right now and
can't therefore run the latest release. We really need a separate
tomcat, I think; this one is shared with AstroGrid services not
checked/ready for java 1.6.

K.
--
Kona Andrews k...@roe.ac.uk
AstroGrid Project http://www.astrogrid.org
IfA, Royal Observatory, Blackford Hill, Edinburgh EH9 3HJ

Norman Gray

unread,
Feb 13, 2009, 9:54:19 AM2/13/09
to skua-d...@googlegroups.com

Tony, hello.

On 2009 Feb 13, at 11:25, Linde, A.E. wrote:

> What query do I post to get a list of federations from a SAC? What
> is the structure of a federation assertion?

It's part of the setup of the SAC, rather than an assertion within a
SAC. If you dereference the URL <sac-name>?metadata then you'll get
back the metadata which was used to set up the SAC initially, which is
where the delegations are set up.

> I'm trying to build a SAC browser/query interface using Flex and
> wondered if we want to allow the user to select which federations
> are active for a query. Probably only useful for a query depth of 1?

It's an idea, but since the query consists only of a SPARQL query, and
the delegation happens transparently, it's not obvious where that
limitation would be expressed. It's not impossible to think of
something (for example, we could potentially have a ?delegate=1
parameter on the URL to which the query was posted), but I'd probably
prefer not to implement that until we've got a definite problem with
the dumb/transparent federation we've got now.

> Also, have we got any SACs available for querying on live servers?

We haven't, no. I think that now might be the time to get an EC2
machine up semi-continuously. Any thoughts about that?

See you,

Norman


--
Norman Gray : http://nxg.me.uk
Dept Physics and Astronomy, University of Leicester

Norman Gray

unread,
Feb 13, 2009, 10:28:13 AM2/13/09
to skua-d...@googlegroups.com

On 2009 Feb 13, at 14:53, Kona Andrews wrote:

> There is generally one here:
> http://apps.myskua.org/qsac-latest/
> However it isn't currently the latest release (despite the name!)
> I'm using a frozen older release, compiled without persistence,
> because the relevant tomcat is not running in java 1.6 right now and
> can't therefore run the latest release. We really need a separate
> tomcat, I think; this one is shared with AstroGrid services not
> checked/ready for java 1.6.

I'd forgotten about that. As an evasion of the Tomcat problems, could
we get the standalone SAC running there? It just needs 'java -jar
qsac-standalone-0.3.jar', with Java 6 on the path. Is the plan.

Linde, A.E.

unread,
Feb 13, 2009, 12:33:39 PM2/13/09
to skd
The location also needs to contain a file which says that Flex/Flash/Silverlight/etc progs can make api calls from outside the domain. Will get back to you with the structure, name etc.

T.

Linde, A.E.

unread,
Feb 13, 2009, 12:39:12 PM2/13/09
to skd
That was quicker than I thought. The root of the server has to have a file called ‘crossdomain.xml’ and this file has to contain:

<cross-domain-policy>
<allow-access-from domain="*"/>
</cross-domain-policy>

Eg see http://www.flexgrocer.com/crossdomain.xml or http://www.cnn.com/crossdomain.xml

T.

Norman Gray

unread,
Feb 15, 2009, 11:43:25 AM2/15/09
to skua-d...@googlegroups.com

Tony, hello.

On 2009 Feb 13, at 17:39, Linde, A.E. wrote:

> That was quicker than I thought. The root of the server has to have
> a file called 'crossdomain.xml' and this file has to contain:
>
> <cross-domain-policy>
> <allow-access-from domain="*"/>
> </cross-domain-policy>

Is this so that the Flash content in Spacebook/meExperiment is allowed
by Flash to make HTTP connections to a site in another domain? That
seems a bit ass-backwards -- shouldn't the client code be making that
configuration?

Linde, A.E.

unread,
Feb 15, 2009, 1:23:33 PM2/15/09
to skd
No. it is up to the server to decide whether and who can make the connections. A bit like a SAC knowing which other SACs can federate to it and only allowing those connections.

T.



On 15/02/2009 16:43, "Norman Gray" <nor...@astro.gla.ac.uk> wrote:

Is this so that the Flash content in Spacebook/meExperiment is allowed
by Flash to make HTTP connections to a site in another domain?  That
seems a bit ass-backwards -- shouldn't the client code be making that
configuration?

Linde, A.E.

unread,
Feb 19, 2009, 7:43:14 AM2/19/09
to skd
Hi Norman,

I got the attached (modified for easier reading) doing a .../sac/tonylinde?metadata call (latest qsac version). If I want to add federations to this, how do I do so? And what format do they need to take?

Ta,
T.



On 13/02/2009 14:54, "Norman Gray" <nor...@astro.gla.ac.uk> wrote:

On 2009 Feb 13, at 11:25, Linde, A.E. wrote:

> What query do I post to get a list of federations from a SAC? What
> is the structure of a federation assertion?

It's part of the setup of the SAC, rather than an assertion within a
SAC.  If you dereference the URL <sac-name>?metadata then you'll get
back the metadata which was used to set up the SAC initially, which is
where the delegations are set up.
tonylinde-metadata.rdf

Norman Gray

unread,
Feb 19, 2009, 8:30:45 AM2/19/09
to skua-d...@googlegroups.com

Tony, hello.

On 2009 Feb 19, at 12:43, Linde, A.E. wrote:

> I got the attached (modified for easier reading) doing a .../sac/
> tonylinde?metadata call (latest qsac version). If I want to add
> federations to this, how do I do so? And what format do they need to
> take?

When you initially create the SAC, you do so by PUTting some RDF which
sets the SAC description (as described in the tutorial page). Though
come to think of it, I don't see anything like that in the RDF you
included in your message -- are you creating it in a different way?
That metadata might look like:

@prefix dc: <http://purl.org/dc/elements/1.1/>.
@prefix quaestor: <http://ns.eurovotech.org/quaestor#>.
<> dc:description "My SAC";
quaestor:delegatesTo <http://foo/myothersac>.

So the dc:description predicate is giving the SAC's dscription, and
the quaestor:delegatesTo predicate names the SAC delegate.

You can _change_ the metadata, but it's a little more involved, and
requires POSTing something like

<rdf:RDF xmlns:cs='http://purl.org/vocab/changeset/schema#'
xmlns:dc='http://purl.org/dc/elements/1.1/'
xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns#'>
<cs:ChangeSet>
<cs:subjectOfChange rdf:resource=''/>
<cs:addition>
<rdf:Statement>
<rdf:object>Test SAC</rdf:object>
<rdf:predicate rdf:resource='http://purl.org/dc/elements/1.1/description'/
>
<rdf:subject rdf:resource=''/>
</rdf:Statement>
</cs:addition>
<cs:removal>
<rdf:Statement>
<rdf:object>My SAC</rdf:object>
<rdf:predicate rdf:resource='http://purl.org/dc/elements/1.1/description'/
>
<rdf:subject rdf:resource=''/>
</rdf:Statement>
</cs:removal>
</cs:ChangeSet>
</rdf:RDF>

...to <.../tonylinde?metadata> with MIME type "application/
vnd.talis.changeset+xml". But I don't think that's necessary yet --
setting up the delegation metadata when the thing is initially created
is probably good enough for now.

Linde, A.E.

unread,
Feb 19, 2009, 10:52:54 AM2/19/09
to skd
Ok, thanks – I’d just been merrily creating SACs using the metadata.ttl example on http://www.myskua.org/doc/qsac/interface-http.html#createsac – doh!

Re adding federations though, we’ll need something a lot simpler before making anything live – that’ll be the first thing anyone will want to do, federate to new SACs they find out about. One for a coming iteration perhaps.

Speaking of which: when’s the next telecon?

T.

Kona Andrews

unread,
Feb 20, 2009, 10:08:45 AM2/20/09
to skua-d...@googlegroups.com
Hi all,

> Speaking of which: when's the next telecon?

Monday any good? Would be good to have one.

Linde, A.E.

unread,
Feb 20, 2009, 10:14:37 AM2/20/09
to skd
I’m not free until Weds.

T.

Kona Andrews

unread,
Feb 20, 2009, 10:41:55 AM2/20/09
to skua-d...@googlegroups.com
> I'm not free until Weds.

Weds 11am ?

Linde, A.E.

unread,
Feb 20, 2009, 11:19:19 AM2/20/09
to skd
Fine with me.

T.

Norman Gray

unread,
Feb 20, 2009, 2:38:27 PM2/20/09
to skua-d...@googlegroups.com, skd

...and me. Wednesday at 11 it is, then. 

Norman


-- 
Norman Gray  :  http://nxg.me.uk
Reply all
Reply to author
Forward
0 new messages