Hello,
Here are my toughs about this.

Needs:
from Steve Loughran :

reverse analysis, who uses "junit", or junit-3.7
cycle detection; who depends on a dependency
missing artifacts: what depends on things that arent there (split into sun,
OSS, proprietary)
scale: who depends on the most stuff
stability: who is most bleeding edge, versus trailing

output: generate fancy SVG graphs from it, or RDF triples for the fun of it.



Definitions :
project( m(Group,Artifact,Version) ). means that the project of group,
artifact and version exists in the repository. where
m(group,artifacy,version) is a prolog term.
depends( Project1, Project2). means that project1 depends on project2.



The first thing the is to create the base of facts.

Issue : does reading all the poms in the evangelism's cvs is enough or do
use of a remote repository is needed ?

the facts are created this way :
for each pom.xml found in the repository,
    read the model using the model builder (real class ?)
    create the fact project(m(groupId,artifactId,version)) of the project in
the prolog fact base
    check if the project's artifact exists in the remote repository, if yes,
create the fact exists(m(groupId,artifactId,version))
    for each of projects direct dependencies,
        create the fact
depends(m(groupId,artifactId,version),m(depGroupId,depArtifactId,depVersion))
store the prolog fact base into a file.

Issue : how to represent an exclusion ? what is an exclusion ?
Issue : how to handle snapshots ?



To query the fact base, we need to a list of rules about the fact predicates
defined in the fact base.



The programs which needs to be created are :
- the crawler which reads the poms from a local or remote repository. called
from command line. outputs the fact base in a file.
- the fact queryer which loads the fact base and the rules. called from the
command line, lets the user input its queries (using the Jlog applet ?)
- the graphing tool which loads the fact base and create an SVG from the
fact base.


Issue, is the prolog approach a correct one ?
    for : the queries are quite easy to create and the answers are complete.
    for : I know some bit of prolog and always liked this language.
    against : querying the facts is quite slow.

Regards,

Raphaël

Reply via email to