import java.nio.file.Paths;
import java.util.Locale;
import java.util.Objects;
+import java.util.UUID;
import javax.security.auth.Subject;
import javax.security.auth.x500.X500Principal;
private final Subject subject;
private final Locale locale;
+ private UUID uuid;
+
// the single session
private CmsContentSession contentSession;
this.subject = subject;
this.locale = locale;
+
+ // TODO use an UUID factory
+ this.uuid = UUID.randomUUID();
}
@Override
initRootContentProvider(null);
if (contentSession != null)
throw new IllegalStateException("Repository is already started, stop it first.");
- contentSession = new CmsContentSession(this, subject, locale);
+ contentSession = new CmsContentSession(this, uuid, subject, locale);
}
@Override
@Override
protected CmsContentSession newSystemSession() {
- return new CmsContentSession(this, subject, Locale.getDefault());
+ return new CmsContentSession(this, uuid, subject, Locale.getDefault());
}
public static void main(String... args) {