Skip to content

Commit

Permalink
Merge pull request #42 from MetaBorgCube/release/0.8.2
Browse files Browse the repository at this point in the history
Release/0.8.2
  • Loading branch information
dcharkes authored Feb 8, 2018
2 parents f94a3e8 + 4a7646e commit bd8c660
Show file tree
Hide file tree
Showing 30 changed files with 381 additions and 207 deletions.
2 changes: 1 addition & 1 deletion .mvn/extensions.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
<extension>
<groupId>org.metaborg</groupId>
<artifactId>spoofax-maven-plugin-pomless</artifactId>
<version>2.3.0</version>
<version>2.4.0</version>
</extension>
</extensions>
2 changes: 1 addition & 1 deletion .mvn/settings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
</repository>
<repository>
<id>spoofax-eclipse-repo</id>
<url>http://artifacts.metaborg.org/content/unzip/releases-unzipped/org/metaborg/org.metaborg.spoofax.eclipse.updatesite/2.3.0/org.metaborg.spoofax.eclipse.updatesite-2.3.0-assembly.zip-unzip/</url>
<url>http://artifacts.metaborg.org/content/unzip/releases-unzipped/org/metaborg/org.metaborg.spoofax.eclipse.updatesite/2.4.0/org.metaborg.spoofax.eclipse.updatesite-2.4.0-assembly.zip-unzip/</url>
<layout>p2</layout>
<releases>
<enabled>false</enabled>
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ Or build the Editor (in Spoofax)

## Try the Examples

See the [icedust.examples](icedust.examples).
See the [icedust examples](icedust.example).

There are three backends:

Expand Down
6 changes: 3 additions & 3 deletions change_spoofax_version.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROMVERSION=2.2.0
TOVERSION=2.2.1
FROMVERSION=2.3.0
TOVERSION=2.4.0

grep -rEl --exclude=*/target/* --exclude=*/src-gen/* --include=*.{yaml,xml,MF} "${FROMVERSION}" * | xargs sed -i "" "s/${FROMVERSION}/${TOVERSION}/g"
grep -rEl --exclude=*/target/* --exclude=*/src-gen/* --include=*.{yaml,xml,MF} "${FROMVERSION}" . | xargs sed -i "" "s/${FROMVERSION}/${TOVERSION}/g"
4 changes: 2 additions & 2 deletions change_version.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROMVERSION=0.7.2
TOVERSION=0.8.1
FROMVERSION=0.8.1
TOVERSION=0.8.2

grep -rEl --exclude=*/target/* --exclude=*/src-gen/* --include=*.{yaml,xml,MF} "${FROMVERSION}(.qualifier|-SNAPSHOT)" * | xargs sed -i "" "s/${FROMVERSION}/${TOVERSION}/g"
4 changes: 2 additions & 2 deletions change_version_to_stable.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
FROMVERSION=0.8.1
TOVERSION=0.8.1
FROMVERSION=0.8.2
TOVERSION=0.8.2

grep -rEl --exclude=*/target/* --exclude=*/src-gen/* --include=*.{yaml,xml,MF} "${FROMVERSION}.qualifier" * | xargs sed -i "" "s/${FROMVERSION}.qualifier/${TOVERSION}/g"
grep -rEl --exclude=*/target/* --exclude=*/src-gen/* --include=*.{yaml,xml,MF} "${FROMVERSION}-SNAPSHOT" * | xargs sed -i "" "s/${FROMVERSION}-SNAPSHOT/${TOVERSION}/g"
4 changes: 2 additions & 2 deletions icedust.eclipse.feature/feature.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<feature
id="icedust.eclipse.feature"
label="icedust language Eclipse plugin"
version="0.8.1"
version="0.8.2"
>
<plugin id="icedust.eclipse" version="0.8.1" unpack="true" />
<plugin id="icedust.eclipse" version="0.8.2" unpack="true" />
<includes id="org.metaborg.spoofax.eclipse.feature" version="0" />
</feature>
6 changes: 3 additions & 3 deletions icedust.eclipse.feature/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@
<modelVersion>4.0.0</modelVersion>
<groupId>org.metaborg.lang</groupId>
<artifactId>icedust.eclipse.feature</artifactId>
<version>0.8.1</version>
<version>0.8.2</version>
<packaging>eclipse-feature</packaging>

<parent>
<groupId>org.metaborg</groupId>
<artifactId>parent.eclipse.plugin</artifactId>
<version>2.3.0</version>
<version>2.4.0</version>
<relativePath />
</parent>

Expand All @@ -39,7 +39,7 @@
</repository>
<repository>
<id>spoofax-eclipse-repo</id>
<url>http://artifacts.metaborg.org/content/unzip/releases-unzipped/org/metaborg/org.metaborg.spoofax.eclipse.updatesite/2.3.0/org.metaborg.spoofax.eclipse.updatesite-2.3.0-assembly.zip-unzip/</url>
<url>http://artifacts.metaborg.org/content/unzip/releases-unzipped/org/metaborg/org.metaborg.spoofax.eclipse.updatesite/2.4.0/org.metaborg.spoofax.eclipse.updatesite-2.4.0-assembly.zip-unzip/</url>
<layout>p2</layout>
<releases>
<enabled>false</enabled>
Expand Down
6 changes: 3 additions & 3 deletions icedust.eclipse.site/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@
<modelVersion>4.0.0</modelVersion>
<groupId>org.metaborg.lang</groupId>
<artifactId>icedust.eclipse.site</artifactId>
<version>0.8.1</version>
<version>0.8.2</version>
<packaging>eclipse-update-site</packaging>

<parent>
<groupId>org.metaborg</groupId>
<artifactId>parent.eclipse.plugin</artifactId>
<version>2.3.0</version>
<version>2.4.0</version>
<relativePath />
</parent>

Expand All @@ -39,7 +39,7 @@
</repository>
<repository>
<id>spoofax-eclipse-repo</id>
<url>http://artifacts.metaborg.org/content/unzip/releases-unzipped/org/metaborg/org.metaborg.spoofax.eclipse.updatesite/2.3.0/org.metaborg.spoofax.eclipse.updatesite-2.3.0-assembly.zip-unzip/</url>
<url>http://artifacts.metaborg.org/content/unzip/releases-unzipped/org/metaborg/org.metaborg.spoofax.eclipse.updatesite/2.4.0/org.metaborg.spoofax.eclipse.updatesite-2.4.0-assembly.zip-unzip/</url>
<layout>p2</layout>
<releases>
<enabled>false</enabled>
Expand Down
2 changes: 1 addition & 1 deletion icedust.eclipse.site/site.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<site>
<feature url="features/icedust.eclipse.feature_0.8.1.jar" id="icedust.eclipse.feature" version="0.8.1">
<feature url="features/icedust.eclipse.feature_0.8.2.jar" id="icedust.eclipse.feature" version="0.8.2">
<category name="icedust"/>
</feature>
<category-def name="icedust" label="icedust language Eclipse plugin">
Expand Down
2 changes: 1 addition & 1 deletion icedust.eclipse/META-INF/MANIFEST.MF
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: icedust language Eclipse plugin
Bundle-SymbolicName: icedust.eclipse;singleton:=true
Bundle-Version: 0.8.1
Bundle-Version: 0.8.2
Bundle-Vendor: org.metaborg.lang
Bundle-ActivationPolicy: lazy
Require-Bundle: org.metaborg.spoofax.eclipse
Expand Down
6 changes: 3 additions & 3 deletions icedust.eclipse/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@
<modelVersion>4.0.0</modelVersion>
<groupId>org.metaborg.lang</groupId>
<artifactId>icedust.eclipse</artifactId>
<version>0.8.1</version>
<version>0.8.2</version>
<packaging>eclipse-plugin</packaging>

<parent>
<groupId>org.metaborg</groupId>
<artifactId>parent.eclipse.language</artifactId>
<version>2.3.0</version>
<version>2.4.0</version>
<relativePath />
</parent>

Expand Down Expand Up @@ -66,7 +66,7 @@
</repository>
<repository>
<id>spoofax-eclipse-repo</id>
<url>http://artifacts.metaborg.org/content/unzip/releases-unzipped/org/metaborg/org.metaborg.spoofax.eclipse.updatesite/2.3.0/org.metaborg.spoofax.eclipse.updatesite-2.3.0-assembly.zip-unzip/</url>
<url>http://artifacts.metaborg.org/content/unzip/releases-unzipped/org/metaborg/org.metaborg.spoofax.eclipse.updatesite/2.4.0/org.metaborg.spoofax.eclipse.updatesite-2.4.0-assembly.zip-unzip/</url>
<layout>p2</layout>
<releases>
<enabled>false</enabled>
Expand Down
2 changes: 1 addition & 1 deletion icedust.example/metaborg.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
---
dependencies:
compile:
- org.metaborg.lang:icedust:0.8.1
- org.metaborg.lang:icedust:0.8.2
43 changes: 43 additions & 0 deletions icedust.example/objectquery/objectquery.ice
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
module objectquery

// model taken from Demand-Driven Incremental Object Queries - PPDP 2016

model

entity Celeb {

}

entity User {
loc : String
email : String
}

relation Celeb.followers * <-> * User.celebs

entity Group {

}

relation User.groups * <-> * Group.members

entity Demand {
cond : String // equality check
result : String* = users.email
}

relation Demand.celeb 1 <-> * Celeb.demands

relation Demand.group 1 <-> * Group.demands

relation Demand.users * = group.members.filter(u => u.loc == cond).filter(u => u.celebs.filter(c => c == celeb).count()>0) // schedule: first join group users, then check whether celeb
<-> * User.demandResults

// comparison with IncOQ
//
// update triggers:
// User.loc -> groups.demands.users (which is exactly the first nested for loops in running example in paper - but IceDust re-evalutes full expression instead of modifies cache with deltas)
//
// the re-evaluation of the users field triggers:
// User.loc -> groups.demands.members.filter(...).filter(u => u.groups.filter(g => g == group)) (which is the remainder of nested for loops. Though IceDust looks at all members of the demand rather than only the changed member. IncOQ only accesses the single changed member.)

48 changes: 48 additions & 0 deletions icedust.example/objectquery/objectquery2.ice
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
module objectquery2

// model taken from Generating Incremental Implementations of Object-Set Queries - GPCE 2008

model

entity User {
id : String
}

entity Group {
active : Boolean
}

relation User.groups * <-> * Group.members

entity Permission {
name : String
}

relation Group.perms * <-> * Permission.groups

entity Query {
uid : String
result : String* = permissions.name
}

relation Query.users * <-> * User.queries

relation Query.user ? = users.find(u => u.id == uid)
<-> User.queries2 // cache the user per query

relation Query.permissions * = user.groups.filter(g => g.active).perms
<-> Permission.queries

// comparison with Object-Set Queries
//
// update triggers:
// User.groups -> queries2.permissions (triggers reevaluation for all queries of which this user is of interest)
//
// the re-evaluation of the permissions field triggers:
// User.groups -> queries2.user.groups.filter(g => g.active).perms (reads all groups of the query, rather than only the single group that is added, OSQ uses deltas, IceDust does not)
//
// the order of forloops in OSQ is different:
// - group.permissions (this IceDust implementation selects permissions of all relevent queries.user.groups at the end)
// group.users.filter(_.id == uid) (this IceDust implementation filters users second)
// group.users is in a query (this IceDust implementation filter on queries first)

6 changes: 3 additions & 3 deletions icedust.example/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,20 +7,20 @@
<modelVersion>4.0.0</modelVersion>
<groupId>org.metaborg.lang</groupId>
<artifactId>icedust.example</artifactId>
<version>0.8.1</version>
<version>0.8.2</version>
<packaging>spoofax-project</packaging>

<parent>
<groupId>org.metaborg</groupId>
<artifactId>parent.language</artifactId>
<version>2.3.0</version>
<version>2.4.0</version>
</parent>

<dependencies>
<dependency>
<groupId>org.metaborg.lang</groupId>
<artifactId>icedust</artifactId>
<version>0.8.1</version>
<version>0.8.2</version>
<type>spoofax-language</type>
</dependency>
</dependencies>
Expand Down
4 changes: 2 additions & 2 deletions icedust.test/metaborg.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
id: org.metaborg:icedust.test:0.8.1
id: org.metaborg:icedust.test:0.8.2
name: IceDust
dependencies:
compile:
- org.metaborg.lang:icedust:0.8.1
- org.metaborg.lang:icedust:0.8.2
- org.metaborg:org.metaborg.meta.lang.spt:${metaborgVersion}
runtime:
nabl2:
Expand Down
8 changes: 4 additions & 4 deletions icedust.test/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,20 +7,20 @@
<modelVersion>4.0.0</modelVersion>
<groupId>org.metaborg.lang</groupId>
<artifactId>icedust.test</artifactId>
<version>0.8.1</version>
<version>0.8.2</version>
<packaging>spoofax-test</packaging>

<parent>
<groupId>org.metaborg</groupId>
<artifactId>parent.language</artifactId>
<version>2.3.0</version>
<version>2.4.0</version>
</parent>

<dependencies>
<dependency>
<groupId>org.metaborg.lang</groupId>
<artifactId>icedust</artifactId>
<version>0.8.1</version>
<version>0.8.2</version>
<type>spoofax-language</type>
</dependency>
<dependency>
Expand All @@ -39,7 +39,7 @@
<artifactId>spoofax-maven-plugin</artifactId>
<version>${metaborg-version}</version>
<configuration>
<languageUnderTest>org.metaborg.lang:icedust:0.8.1</languageUnderTest>
<languageUnderTest>org.metaborg.lang:icedust:0.8.2</languageUnderTest>
</configuration>
</plugin>
</plugins>
Expand Down
2 changes: 1 addition & 1 deletion icedust/.mvn/extensions.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
<extension>
<groupId>org.metaborg</groupId>
<artifactId>spoofax-maven-plugin-pomless</artifactId>
<version>2.3.0</version>
<version>2.4.0</version>
</extension>
</extensions>
17 changes: 15 additions & 2 deletions icedust/lib-java/src/derivations/Settings.java
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,16 @@ public static void setUpdatesEnabled(boolean setting) {
updatesEnabled = setting;
}

static volatile boolean dirtyFlaggingEnabled = true;

public static boolean getDirtyFlaggingEnabled() {
return dirtyFlaggingEnabled;
}

public static void setDirtyFlaggingEnabled(boolean setting) {
dirtyFlaggingEnabled = setting;
}

static WorkerSet workers;

public Settings(int n, int millis) {
Expand Down Expand Up @@ -148,6 +158,7 @@ public void run() {
utils.HibernateUtil.getCurrentSession())) {
java.io.PrintWriter out = new java.io.PrintWriter(System.out);
ThreadLocalOut.push(out);
DirtyCollections.incrementCalculation();
webdsl.generated.functions.updateDerivationsAsyncThread_
.updateDerivationsAsyncThread_(thisThread);
utils.HibernateUtil.getCurrentSession().getTransaction().commit();
Expand All @@ -156,9 +167,11 @@ public void run() {
}
} catch (org.hibernate.StaleStateException
| org.hibernate.exception.LockAcquisitionException ex) {
org.webdsl.logging.Logger
.error("updateDerivationsAsync() database collision, rescheduling");
// org.webdsl.logging.Logger
// .error("updateDerivationsAsync() database collision, rescheduling");

DirtyCollections.incrementCollision();

Settings.reschedule(thisThread);

utils.HibernateUtil.getCurrentSession().getTransaction().rollback();
Expand Down
2 changes: 1 addition & 1 deletion icedust/metaborg.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
id: org.metaborg.lang:icedust:0.8.1
id: org.metaborg.lang:icedust:0.8.2
name: icedust
dependencies:
compile:
Expand Down
4 changes: 2 additions & 2 deletions icedust/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@
<modelVersion>4.0.0</modelVersion>
<groupId>org.metaborg.lang</groupId>
<artifactId>icedust</artifactId>
<version>0.8.1</version>
<version>0.8.2</version>
<packaging>spoofax-language</packaging>

<parent>
<groupId>org.metaborg</groupId>
<artifactId>parent.language</artifactId>
<version>2.3.0</version>
<version>2.4.0</version>
</parent>

<dependencies>
Expand Down
Loading

0 comments on commit bd8c660

Please sign in to comment.