Revision: 3345
Author: ferguson.sebastian
Date: Mon Mar 1 15:40:10 2010
Log: Classes now fire property changes for 'populated' and annotations were
fixed for SQLDatabase. Also, transactions beginning with rollback are
accounted for.
http://code.google.com/p/power-architect/source/detail?r=3345
Modified:
/trunk/src/ca/sqlpower/architect/enterprise/ArchitectClientSideSession.java
=======================================
---
/trunk/src/ca/sqlpower/architect/enterprise/ArchitectClientSideSession.java
Mon Mar 1 08:33:36 2010
+++
/trunk/src/ca/sqlpower/architect/enterprise/ArchitectClientSideSession.java
Mon Mar 1 15:40:10 2010
@@ -595,7 +595,8 @@
URI serverURI = getServerURI();
HttpPost postRequest = new HttpPost(serverURI);
- postRequest.setEntity(new
StringEntity(messageQueue.get(0).toString()));
+ postRequest.setEntity(new
StringEntity(messageQueue.get(0).toString()));
+
postRequest.setHeader("Content-Type", "application/json");
HttpUriRequest request = postRequest;
clear();
@@ -644,7 +645,9 @@
}
public void send(JSONObject content) throws
SPPersistenceException {
- if
(content.toString().equals("{\"uuid\":null,\"method\":\"begin\"}")) {
+ // Transactions can start with a begin or a rollback
+ if
(content.toString().equals("{\"uuid\":null,\"method\":\"begin\"}") ||
+
content.toString().equals("{\"uuid\":null,\"method\":\"rollback\"}")) {
messageQueue.add(new JSONArray());
}
messageQueue.get(messageQueue.size() - 1).put(content);