incubator-cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ke4...@apache.org
Subject git commit: Chip Childers patch for fixing license headers - awsapi-setup https://reviews.apache.org/r/5438/
Date Tue, 26 Jun 2012 14:51:29 GMT
Updated Branches:
  refs/heads/master 968752071 -> bc1c89790


Chip Childers patch for fixing license headers - awsapi-setup
https://reviews.apache.org/r/5438/


Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/bc1c8979
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/bc1c8979
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/bc1c8979

Branch: refs/heads/master
Commit: bc1c89790181c233debbdf5bccfac9595d35c1b2
Parents: 9687520
Author: David Nalley <david@gnsa.us>
Authored: Tue Jun 26 10:51:23 2012 -0400
Committer: David Nalley <david@gnsa.us>
Committed: Tue Jun 26 10:51:23 2012 -0400

----------------------------------------------------------------------
 awsapi-setup/db/mysql/cloudbridge_bucketpolicy.sql |   18 +
 awsapi-setup/db/mysql/cloudbridge_db.sql           |   18 +
 awsapi-setup/db/mysql/cloudbridge_index.sql        |  111 +++---
 awsapi-setup/db/mysql/cloudbridge_multipart.sql    |   17 +
 .../db/mysql/cloudbridge_multipart_alter.sql       |   18 +
 awsapi-setup/db/mysql/cloudbridge_offering.sql     |   18 +
 .../db/mysql/cloudbridge_offering_alter.sql        |   18 +
 awsapi-setup/db/mysql/cloudbridge_policy_alter.sql |   18 +
 awsapi-setup/db/mysql/cloudbridge_schema.sql       |  306 ++++++++-------
 awsapi-setup/db/mysql/deploy-db-bridge.sh          |   19 +-
 awsapi-setup/init/debian/cloud-bridge              |   16 +
 awsapi-setup/init/rpm/cloud-bridge                 |   17 +
 awsapi-setup/setup/cloud-setup-bridge              |   17 +
 awsapi-setup/setup/cloudstack-aws-api-register     |   17 +
 14 files changed, 434 insertions(+), 194 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/bc1c8979/awsapi-setup/db/mysql/cloudbridge_bucketpolicy.sql
----------------------------------------------------------------------
diff --git a/awsapi-setup/db/mysql/cloudbridge_bucketpolicy.sql b/awsapi-setup/db/mysql/cloudbridge_bucketpolicy.sql
index 9d6a650..44019f1 100644
--- a/awsapi-setup/db/mysql/cloudbridge_bucketpolicy.sql
+++ b/awsapi-setup/db/mysql/cloudbridge_bucketpolicy.sql
@@ -1,3 +1,21 @@
+-- Licensed to the Apache Software Foundation (ASF) under one
+-- or more contributor license agreements.  See the NOTICE file
+-- distributed with this work for additional information
+-- regarding copyright ownership.  The ASF licenses this file
+-- to you under the Apache License, Version 2.0 (the
+-- "License"); you may not use this file except in compliance
+-- with the License.  You may obtain a copy of the License at
+-- 
+--   http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing,
+-- software distributed under the License is distributed on an
+-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+-- KIND, either express or implied.  See the License for the
+-- specific language governing permissions and limitations
+-- under the License.
+
+
 USE cloudbridge;
 
 -- This file (and cloudbridge_policy_alter.sql) can be applied to an existing cloudbridge


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/bc1c8979/awsapi-setup/db/mysql/cloudbridge_db.sql
----------------------------------------------------------------------
diff --git a/awsapi-setup/db/mysql/cloudbridge_db.sql b/awsapi-setup/db/mysql/cloudbridge_db.sql
index 04ea41a..952a34d 100644
--- a/awsapi-setup/db/mysql/cloudbridge_db.sql
+++ b/awsapi-setup/db/mysql/cloudbridge_db.sql
@@ -1,3 +1,21 @@
+-- Licensed to the Apache Software Foundation (ASF) under one
+-- or more contributor license agreements.  See the NOTICE file
+-- distributed with this work for additional information
+-- regarding copyright ownership.  The ASF licenses this file
+-- to you under the Apache License, Version 2.0 (the
+-- "License"); you may not use this file except in compliance
+-- with the License.  You may obtain a copy of the License at
+-- 
+--   http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing,
+-- software distributed under the License is distributed on an
+-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+-- KIND, either express or implied.  See the License for the
+-- specific language governing permissions and limitations
+-- under the License.
+
+
 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='ANSI';
 
 DROP DATABASE IF EXISTS cloudbridge;

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/bc1c8979/awsapi-setup/db/mysql/cloudbridge_index.sql
----------------------------------------------------------------------
diff --git a/awsapi-setup/db/mysql/cloudbridge_index.sql b/awsapi-setup/db/mysql/cloudbridge_index.sql
index d00e5d8..e099b65 100644
--- a/awsapi-setup/db/mysql/cloudbridge_index.sql
+++ b/awsapi-setup/db/mysql/cloudbridge_index.sql
@@ -1,47 +1,64 @@
-USE cloudbridge;
-
-ALTER TABLE shost ADD UNIQUE shost_uq_host(Host, HostType, ExportRoot);
-ALTER TABLE shost ADD CONSTRAINT FOREIGN KEY shost_fk_mhost_id(MHostID) REFERENCES mhost(ID);
-ALTER TABLE shost ADD INDEX shost_idx_mhost_id(MHostID);
-
-ALTER TABLE sbucket ADD UNIQUE sbucket_uq_name(Name);
-ALTER TABLE sbucket ADD CONSTRAINT FOREIGN KEY sbucket_fk_shost_id(SHostID) REFERENCES shost(ID);
-ALTER TABLE sbucket ADD INDEX sbucket_idx_shost_id(SHostID);
-ALTER TABLE sbucket ADD INDEX sbucket_idx_owner_cid(OwnerCanonicalID);
-ALTER TABLE sbucket ADD INDEX sbucket_idx_create_time(CreateTime);
-
-ALTER TABLE sobject ADD CONSTRAINT FOREIGN KEY sobject_fk_sbuckt_id(SBucketID) REFERENCES
sbucket(ID) ON DELETE CASCADE;
-ALTER TABLE sobject ADD INDEX sobject_idx_bucket_id(SBucketID);
-ALTER TABLE sobject ADD INDEX sobject_idx_owner_cid(OwnerCanonicalID);
-ALTER TABLE sobject ADD UNIQUE sobject_uq_sbucket_id_name_key(SBucketID, NameKey);
-ALTER TABLE sobject ADD INDEX sobject_idx_create_time(CreateTime);
-
-ALTER TABLE sobject_item ADD CONSTRAINT FOREIGN KEY sobject_item_fk_object_id(SObjectID)
REFERENCES sobject(ID) ON DELETE CASCADE;
-ALTER TABLE sobject_item ADD INDEX sobject_item_idx_object_id(SObjectID);
-ALTER TABLE sobject_item ADD UNIQUE sobject_item_uq_sobject_id_version(SObjectID, Version);
-ALTER TABLE sobject_item ADD INDEX sobject_item_idx_create_time(CreateTime);
-ALTER TABLE sobject_item ADD INDEX sobject_item_idx_modify_time(LastModifiedTime);
-ALTER TABLE sobject_item ADD INDEX sobject_item_idx_access_time(LastAccessTime);
-ALTER TABLE sobject_item ADD INDEX sobject_item_idx_stored_size(StoredSize);
-
-ALTER TABLE meta ADD UNIQUE meta_uq_target_name(Target, TargetID, Name);
-ALTER TABLE meta ADD INDEX meta_idx_target(Target, TargetID);
-
-ALTER TABLE usercredentials ADD UNIQUE usercredentials_mappings1(AccessKey);
-ALTER TABLE usercredentials ADD UNIQUE usercredentials_mappings2(CertUniqueId);
-ALTER TABLE usercredentials ADD INDEX usercredentials_idx_access(AccessKey);
-ALTER TABLE usercredentials ADD INDEX usercredentials_idx_cert(CertUniqueId);
-
-ALTER TABLE acl ADD INDEX acl_idx_target(Target, TargetID);
-ALTER TABLE acl ADD INDEX acl_idx_modify_time(LastModifiedTime);
-
-ALTER TABLE mhost ADD UNIQUE mhost_uq_host(Host);
-ALTER TABLE mhost ADD INDEX mhost_idx_mhost_key(MHostKey);
-ALTER TABLE mhost ADD INDEX mhost_idx_heartbeat_time(LastHeartbeatTime);
-
-ALTER TABLE mhost_mount ADD UNIQUE mhost_mnt_uq_mhost_shost(MHostID, SHostID);
-ALTER TABLE mhost_mount ADD CONSTRAINT FOREIGN KEY mhost_mnt_fk_mhost_id(MHostID) REFERENCES
mhost(ID) ON DELETE CASCADE;
-ALTER TABLE mhost_mount ADD CONSTRAINT FOREIGN KEY mhost_mnt_fk_shost_id(SHostID) REFERENCES
shost(ID) ON DELETE CASCADE;
-ALTER TABLE mhost_mount ADD INDEX mhost_mnt_idx_mhost_id(MHostID);
-ALTER TABLE mhost_mount ADD INDEX mhost_mnt_idx_shost_id(SHostID);
-ALTER TABLE mhost_mount ADD INDEX mhost_mnt_idx_mount_time(LastMountTime);
+-- Licensed to the Apache Software Foundation (ASF) under one
+-- or more contributor license agreements.  See the NOTICE file
+-- distributed with this work for additional information
+-- regarding copyright ownership.  The ASF licenses this file
+-- to you under the Apache License, Version 2.0 (the
+-- "License"); you may not use this file except in compliance
+-- with the License.  You may obtain a copy of the License at
+-- 
+--   http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing,
+-- software distributed under the License is distributed on an
+-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+-- KIND, either express or implied.  See the License for the
+-- specific language governing permissions and limitations
+-- under the License.
+
+USE cloudbridge;
+
+ALTER TABLE shost ADD UNIQUE shost_uq_host(Host, HostType, ExportRoot);
+ALTER TABLE shost ADD CONSTRAINT FOREIGN KEY shost_fk_mhost_id(MHostID) REFERENCES mhost(ID);
+ALTER TABLE shost ADD INDEX shost_idx_mhost_id(MHostID);
+
+ALTER TABLE sbucket ADD UNIQUE sbucket_uq_name(Name);
+ALTER TABLE sbucket ADD CONSTRAINT FOREIGN KEY sbucket_fk_shost_id(SHostID) REFERENCES shost(ID);
+ALTER TABLE sbucket ADD INDEX sbucket_idx_shost_id(SHostID);
+ALTER TABLE sbucket ADD INDEX sbucket_idx_owner_cid(OwnerCanonicalID);
+ALTER TABLE sbucket ADD INDEX sbucket_idx_create_time(CreateTime);
+
+ALTER TABLE sobject ADD CONSTRAINT FOREIGN KEY sobject_fk_sbuckt_id(SBucketID) REFERENCES
sbucket(ID) ON DELETE CASCADE;
+ALTER TABLE sobject ADD INDEX sobject_idx_bucket_id(SBucketID);
+ALTER TABLE sobject ADD INDEX sobject_idx_owner_cid(OwnerCanonicalID);
+ALTER TABLE sobject ADD UNIQUE sobject_uq_sbucket_id_name_key(SBucketID, NameKey);
+ALTER TABLE sobject ADD INDEX sobject_idx_create_time(CreateTime);
+
+ALTER TABLE sobject_item ADD CONSTRAINT FOREIGN KEY sobject_item_fk_object_id(SObjectID)
REFERENCES sobject(ID) ON DELETE CASCADE;
+ALTER TABLE sobject_item ADD INDEX sobject_item_idx_object_id(SObjectID);
+ALTER TABLE sobject_item ADD UNIQUE sobject_item_uq_sobject_id_version(SObjectID, Version);
+ALTER TABLE sobject_item ADD INDEX sobject_item_idx_create_time(CreateTime);
+ALTER TABLE sobject_item ADD INDEX sobject_item_idx_modify_time(LastModifiedTime);
+ALTER TABLE sobject_item ADD INDEX sobject_item_idx_access_time(LastAccessTime);
+ALTER TABLE sobject_item ADD INDEX sobject_item_idx_stored_size(StoredSize);
+
+ALTER TABLE meta ADD UNIQUE meta_uq_target_name(Target, TargetID, Name);
+ALTER TABLE meta ADD INDEX meta_idx_target(Target, TargetID);
+
+ALTER TABLE usercredentials ADD UNIQUE usercredentials_mappings1(AccessKey);
+ALTER TABLE usercredentials ADD UNIQUE usercredentials_mappings2(CertUniqueId);
+ALTER TABLE usercredentials ADD INDEX usercredentials_idx_access(AccessKey);
+ALTER TABLE usercredentials ADD INDEX usercredentials_idx_cert(CertUniqueId);
+
+ALTER TABLE acl ADD INDEX acl_idx_target(Target, TargetID);
+ALTER TABLE acl ADD INDEX acl_idx_modify_time(LastModifiedTime);
+
+ALTER TABLE mhost ADD UNIQUE mhost_uq_host(Host);
+ALTER TABLE mhost ADD INDEX mhost_idx_mhost_key(MHostKey);
+ALTER TABLE mhost ADD INDEX mhost_idx_heartbeat_time(LastHeartbeatTime);
+
+ALTER TABLE mhost_mount ADD UNIQUE mhost_mnt_uq_mhost_shost(MHostID, SHostID);
+ALTER TABLE mhost_mount ADD CONSTRAINT FOREIGN KEY mhost_mnt_fk_mhost_id(MHostID) REFERENCES
mhost(ID) ON DELETE CASCADE;
+ALTER TABLE mhost_mount ADD CONSTRAINT FOREIGN KEY mhost_mnt_fk_shost_id(SHostID) REFERENCES
shost(ID) ON DELETE CASCADE;
+ALTER TABLE mhost_mount ADD INDEX mhost_mnt_idx_mhost_id(MHostID);
+ALTER TABLE mhost_mount ADD INDEX mhost_mnt_idx_shost_id(SHostID);
+ALTER TABLE mhost_mount ADD INDEX mhost_mnt_idx_mount_time(LastMountTime);

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/bc1c8979/awsapi-setup/db/mysql/cloudbridge_multipart.sql
----------------------------------------------------------------------
diff --git a/awsapi-setup/db/mysql/cloudbridge_multipart.sql b/awsapi-setup/db/mysql/cloudbridge_multipart.sql
index 27456c4..e30c0ce 100644
--- a/awsapi-setup/db/mysql/cloudbridge_multipart.sql
+++ b/awsapi-setup/db/mysql/cloudbridge_multipart.sql
@@ -1,3 +1,20 @@
+-- Licensed to the Apache Software Foundation (ASF) under one
+-- or more contributor license agreements.  See the NOTICE file
+-- distributed with this work for additional information
+-- regarding copyright ownership.  The ASF licenses this file
+-- to you under the Apache License, Version 2.0 (the
+-- "License"); you may not use this file except in compliance
+-- with the License.  You may obtain a copy of the License at
+-- 
+--   http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing,
+-- software distributed under the License is distributed on an
+-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+-- KIND, either express or implied.  See the License for the
+-- specific language governing permissions and limitations
+-- under the License.
+
 USE cloudbridge;
 
 -- This file can be applied to an existing cloudbridge database.   It is used

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/bc1c8979/awsapi-setup/db/mysql/cloudbridge_multipart_alter.sql
----------------------------------------------------------------------
diff --git a/awsapi-setup/db/mysql/cloudbridge_multipart_alter.sql b/awsapi-setup/db/mysql/cloudbridge_multipart_alter.sql
index 203bf3a..2614aaf 100644
--- a/awsapi-setup/db/mysql/cloudbridge_multipart_alter.sql
+++ b/awsapi-setup/db/mysql/cloudbridge_multipart_alter.sql
@@ -1,3 +1,21 @@
+-- Licensed to the Apache Software Foundation (ASF) under one
+-- or more contributor license agreements.  See the NOTICE file
+-- distributed with this work for additional information
+-- regarding copyright ownership.  The ASF licenses this file
+-- to you under the Apache License, Version 2.0 (the
+-- "License"); you may not use this file except in compliance
+-- with the License.  You may obtain a copy of the License at
+-- 
+--   http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing,
+-- software distributed under the License is distributed on an
+-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+-- KIND, either express or implied.  See the License for the
+-- specific language governing permissions and limitations
+-- under the License.
+
+
 USE cloudbridge;
 
 ALTER TABLE multipart_meta ADD CONSTRAINT FOREIGN KEY meta_uploads_id(UploadID) REFERENCES
multipart_uploads(ID) ON DELETE CASCADE;

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/bc1c8979/awsapi-setup/db/mysql/cloudbridge_offering.sql
----------------------------------------------------------------------
diff --git a/awsapi-setup/db/mysql/cloudbridge_offering.sql b/awsapi-setup/db/mysql/cloudbridge_offering.sql
index 064fd93..f21af5a 100644
--- a/awsapi-setup/db/mysql/cloudbridge_offering.sql
+++ b/awsapi-setup/db/mysql/cloudbridge_offering.sql
@@ -1,3 +1,21 @@
+-- Licensed to the Apache Software Foundation (ASF) under one
+-- or more contributor license agreements.  See the NOTICE file
+-- distributed with this work for additional information
+-- regarding copyright ownership.  The ASF licenses this file
+-- to you under the Apache License, Version 2.0 (the
+-- "License"); you may not use this file except in compliance
+-- with the License.  You may obtain a copy of the License at
+-- 
+--   http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing,
+-- software distributed under the License is distributed on an
+-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+-- KIND, either express or implied.  See the License for the
+-- specific language governing permissions and limitations
+-- under the License.
+
+
 USE cloudbridge;
 
 -- This file (and cloudbridge_offering_alter.sql) can be applied to an existing cloudbridge


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/bc1c8979/awsapi-setup/db/mysql/cloudbridge_offering_alter.sql
----------------------------------------------------------------------
diff --git a/awsapi-setup/db/mysql/cloudbridge_offering_alter.sql b/awsapi-setup/db/mysql/cloudbridge_offering_alter.sql
index c44df79..bffb34d 100644
--- a/awsapi-setup/db/mysql/cloudbridge_offering_alter.sql
+++ b/awsapi-setup/db/mysql/cloudbridge_offering_alter.sql
@@ -1,3 +1,21 @@
+-- Licensed to the Apache Software Foundation (ASF) under one
+-- or more contributor license agreements.  See the NOTICE file
+-- distributed with this work for additional information
+-- regarding copyright ownership.  The ASF licenses this file
+-- to you under the Apache License, Version 2.0 (the
+-- "License"); you may not use this file except in compliance
+-- with the License.  You may obtain a copy of the License at
+-- 
+--   http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing,
+-- software distributed under the License is distributed on an
+-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+-- KIND, either express or implied.  See the License for the
+-- specific language governing permissions and limitations
+-- under the License.
+
+
 USE cloudbridge;
 
 ALTER TABLE offering_bundle ADD UNIQUE one_offering (AmazonEC2Offering);

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/bc1c8979/awsapi-setup/db/mysql/cloudbridge_policy_alter.sql
----------------------------------------------------------------------
diff --git a/awsapi-setup/db/mysql/cloudbridge_policy_alter.sql b/awsapi-setup/db/mysql/cloudbridge_policy_alter.sql
index 311a865..53ab40b 100644
--- a/awsapi-setup/db/mysql/cloudbridge_policy_alter.sql
+++ b/awsapi-setup/db/mysql/cloudbridge_policy_alter.sql
@@ -1,3 +1,21 @@
+-- Licensed to the Apache Software Foundation (ASF) under one
+-- or more contributor license agreements.  See the NOTICE file
+-- distributed with this work for additional information
+-- regarding copyright ownership.  The ASF licenses this file
+-- to you under the Apache License, Version 2.0 (the
+-- "License"); you may not use this file except in compliance
+-- with the License.  You may obtain a copy of the License at
+-- 
+--   http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing,
+-- software distributed under the License is distributed on an
+-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+-- KIND, either express or implied.  See the License for the
+-- specific language governing permissions and limitations
+-- under the License.
+
+
 USE cloudbridge;
 
 ALTER TABLE bucket_policies ADD UNIQUE one_policy_per_bucket(BucketName);

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/bc1c8979/awsapi-setup/db/mysql/cloudbridge_schema.sql
----------------------------------------------------------------------
diff --git a/awsapi-setup/db/mysql/cloudbridge_schema.sql b/awsapi-setup/db/mysql/cloudbridge_schema.sql
index f4b21a0..de22f11 100644
--- a/awsapi-setup/db/mysql/cloudbridge_schema.sql
+++ b/awsapi-setup/db/mysql/cloudbridge_schema.sql
@@ -1,144 +1,162 @@
-USE cloudbridge;
-
-SET foreign_key_checks = 0;
-
-DROP TABLE IF EXISTS shost;
-DROP TABLE IF EXISTS mhost;
-DROP TABLE IF EXISTS mhost_mount;
-DROP TABLE IF EXISTS sbucket;
-DROP TABLE IF EXISTS sobject;
-DROP TABLE IF EXISTS sobject_item;
-DROP TABLE IF EXISTS meta;
-DROP TABLE IF EXISTS acl;
-DROP TABLE IF EXISTS usercredentials;
-
--- storage host
-CREATE TABLE shost (							
-	ID BIGINT NOT NULL AUTO_INCREMENT,
-	
-	Host VARCHAR(128) NOT NULL,
-	HostType INT NOT NULL DEFAULT 0, 	-- 0 : local, 1 : nfs
-	ExportRoot VARCHAR(128) NOT NULL,
-	
-	MHostID BIGINT,						-- when host type is local, MHostID points to its owner management
host												
-	
-	UserOnHost VARCHAR(64),
-	UserPassword VARCHAR(128),
-	PRIMARY KEY(ID)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-
--- management host
-CREATE TABLE mhost (
-	ID BIGINT NOT NULL AUTO_INCREMENT,
-	
-	MHostKey VARCHAR(128) NOT NULL, 	-- host key could be derived from MAC address or named
configuration value
-	Host VARCHAR(128),					-- public host address for redirecting request from/to 
-	
-	Version VARCHAR(64),
-	LastHeartbeatTime DATETIME,
-	
-	PRIMARY KEY(ID)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-
-CREATE TABLE mhost_mount (
-	ID BIGINT NOT NULL AUTO_INCREMENT,
-	MHostID BIGINT NOT NULL,
-	SHostID BIGINT NOT NULL,
-
-	MountPath VARCHAR(256),				-- local mount path
-	LastMountTime DATETIME,				-- null : unmounted, otherwise the mount location
-	
-	PRIMARY KEY(ID)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-
-CREATE TABLE sbucket (
-	ID BIGINT NOT NULL AUTO_INCREMENT,
-	
-	Name VARCHAR(64) NOT NULL,
-	OwnerCanonicalID VARCHAR(150) NOT NULL,
-	
-	SHostID BIGINT,
-	
-	CreateTime DATETIME,
-	
-	VersioningStatus INT NOT NULL DEFAULT 0,  -- 0 : initial not set, 1 : enabled, 2 : suspended

-	
-	PRIMARY KEY(ID)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-
-CREATE TABLE sobject (
-	ID BIGINT NOT NULL AUTO_INCREMENT,
-	
-	SBucketID BIGINT NOT NULL,
-	NameKey VARCHAR(255) NOT NULL,
-	
-	OwnerCanonicalID VARCHAR(150) NOT NULL,
-	NextSequence INT NOT NULL DEFAULT 1,
-	DeletionMark VARCHAR (150), 
- 	
- 	CreateTime DATETIME,
- 	
-	PRIMARY KEY(ID)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-
-CREATE TABLE sobject_item (
-	ID BIGINT NOT NULL AUTO_INCREMENT,
-	
-	SObjectID BIGINT NOT NULL,
- 	Version VARCHAR(64),
- 	
- 	MD5 VARCHAR(128),
- 	StoredPath VARCHAR(256),					-- relative to mount point of the root
- 	StoredSize BIGINT NOT NULL DEFAULT 0,
- 	
- 	CreateTime DATETIME,
- 	LastModifiedTime DATETIME,
- 	LastAccessTime DATETIME,
- 	
-	PRIMARY KEY(ID)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-
-CREATE TABLE meta (
-	ID BIGINT NOT NULL AUTO_INCREMENT,
-	
-	Target VARCHAR(64) NOT NULL,
-	TargetID BIGINT NOT NULL,
-
-	Name VARCHAR(64) NOT NULL,
-	Value VARCHAR(256),
-
-	PRIMARY KEY(ID)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-
-CREATE TABLE acl (
-	ID BIGINT NOT NULL AUTO_INCREMENT,
-	
-	Target VARCHAR(64) NOT NULL,
-	TargetID BIGINT NOT NULL,
-	
-	GranteeType INT NOT NULL DEFAULT 0,			-- 0 : Cloud service user, 1 : Cloud user community,
2: Public user community
-	GranteeCanonicalID VARCHAR(150),            -- make it big enought to hold a Cloud API access
key
-	
-	Permission INT NOT NULL DEFAULT 0,			-- 0 : no permission, 1 : read, 2 : write, 4 : read_acl,
8 : write_acl 
-	GrantOrder INT NOT NULL DEFAULT 0, 
-	
-	CreateTime DATETIME,
-	LastModifiedTime DATETIME,
-
-	PRIMARY KEY(ID)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-
--- each account has to have a separate <AccessKey,SecretKey>
--- each account has to have a separate <CertUniqueID,AccessKey> mappings
-CREATE TABLE usercredentials (
-	ID BIGINT NOT NULL AUTO_INCREMENT,
-	
-	AccessKey VARCHAR(150) NOT NULL,
-	SecretKey VARCHAR(150) NOT NULL,
-	CertUniqueId VARCHAR(200),
-
-	PRIMARY KEY(ID)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-
-SET foreign_key_checks = 1;
-
+-- Licensed to the Apache Software Foundation (ASF) under one
+-- or more contributor license agreements.  See the NOTICE file
+-- distributed with this work for additional information
+-- regarding copyright ownership.  The ASF licenses this file
+-- to you under the Apache License, Version 2.0 (the
+-- "License"); you may not use this file except in compliance
+-- with the License.  You may obtain a copy of the License at
+-- 
+--   http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing,
+-- software distributed under the License is distributed on an
+-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+-- KIND, either express or implied.  See the License for the
+-- specific language governing permissions and limitations
+-- under the License.
+
+
+USE cloudbridge;
+
+SET foreign_key_checks = 0;
+
+DROP TABLE IF EXISTS shost;
+DROP TABLE IF EXISTS mhost;
+DROP TABLE IF EXISTS mhost_mount;
+DROP TABLE IF EXISTS sbucket;
+DROP TABLE IF EXISTS sobject;
+DROP TABLE IF EXISTS sobject_item;
+DROP TABLE IF EXISTS meta;
+DROP TABLE IF EXISTS acl;
+DROP TABLE IF EXISTS usercredentials;
+
+-- storage host
+CREATE TABLE shost (							
+	ID BIGINT NOT NULL AUTO_INCREMENT,
+	
+	Host VARCHAR(128) NOT NULL,
+	HostType INT NOT NULL DEFAULT 0, 	-- 0 : local, 1 : nfs
+	ExportRoot VARCHAR(128) NOT NULL,
+	
+	MHostID BIGINT,						-- when host type is local, MHostID points to its owner management
host												
+	
+	UserOnHost VARCHAR(64),
+	UserPassword VARCHAR(128),
+	PRIMARY KEY(ID)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+
+-- management host
+CREATE TABLE mhost (
+	ID BIGINT NOT NULL AUTO_INCREMENT,
+	
+	MHostKey VARCHAR(128) NOT NULL, 	-- host key could be derived from MAC address or named
configuration value
+	Host VARCHAR(128),					-- public host address for redirecting request from/to 
+	
+	Version VARCHAR(64),
+	LastHeartbeatTime DATETIME,
+	
+	PRIMARY KEY(ID)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+
+CREATE TABLE mhost_mount (
+	ID BIGINT NOT NULL AUTO_INCREMENT,
+	MHostID BIGINT NOT NULL,
+	SHostID BIGINT NOT NULL,
+
+	MountPath VARCHAR(256),				-- local mount path
+	LastMountTime DATETIME,				-- null : unmounted, otherwise the mount location
+	
+	PRIMARY KEY(ID)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+
+CREATE TABLE sbucket (
+	ID BIGINT NOT NULL AUTO_INCREMENT,
+	
+	Name VARCHAR(64) NOT NULL,
+	OwnerCanonicalID VARCHAR(150) NOT NULL,
+	
+	SHostID BIGINT,
+	
+	CreateTime DATETIME,
+	
+	VersioningStatus INT NOT NULL DEFAULT 0,  -- 0 : initial not set, 1 : enabled, 2 : suspended

+	
+	PRIMARY KEY(ID)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+
+CREATE TABLE sobject (
+	ID BIGINT NOT NULL AUTO_INCREMENT,
+	
+	SBucketID BIGINT NOT NULL,
+	NameKey VARCHAR(255) NOT NULL,
+	
+	OwnerCanonicalID VARCHAR(150) NOT NULL,
+	NextSequence INT NOT NULL DEFAULT 1,
+	DeletionMark VARCHAR (150), 
+ 	
+ 	CreateTime DATETIME,
+ 	
+	PRIMARY KEY(ID)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+
+CREATE TABLE sobject_item (
+	ID BIGINT NOT NULL AUTO_INCREMENT,
+	
+	SObjectID BIGINT NOT NULL,
+ 	Version VARCHAR(64),
+ 	
+ 	MD5 VARCHAR(128),
+ 	StoredPath VARCHAR(256),					-- relative to mount point of the root
+ 	StoredSize BIGINT NOT NULL DEFAULT 0,
+ 	
+ 	CreateTime DATETIME,
+ 	LastModifiedTime DATETIME,
+ 	LastAccessTime DATETIME,
+ 	
+	PRIMARY KEY(ID)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+
+CREATE TABLE meta (
+	ID BIGINT NOT NULL AUTO_INCREMENT,
+	
+	Target VARCHAR(64) NOT NULL,
+	TargetID BIGINT NOT NULL,
+
+	Name VARCHAR(64) NOT NULL,
+	Value VARCHAR(256),
+
+	PRIMARY KEY(ID)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+
+CREATE TABLE acl (
+	ID BIGINT NOT NULL AUTO_INCREMENT,
+	
+	Target VARCHAR(64) NOT NULL,
+	TargetID BIGINT NOT NULL,
+	
+	GranteeType INT NOT NULL DEFAULT 0,			-- 0 : Cloud service user, 1 : Cloud user community,
2: Public user community
+	GranteeCanonicalID VARCHAR(150),            -- make it big enought to hold a Cloud API access
key
+	
+	Permission INT NOT NULL DEFAULT 0,			-- 0 : no permission, 1 : read, 2 : write, 4 : read_acl,
8 : write_acl 
+	GrantOrder INT NOT NULL DEFAULT 0, 
+	
+	CreateTime DATETIME,
+	LastModifiedTime DATETIME,
+
+	PRIMARY KEY(ID)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+
+-- each account has to have a separate <AccessKey,SecretKey>
+-- each account has to have a separate <CertUniqueID,AccessKey> mappings
+CREATE TABLE usercredentials (
+	ID BIGINT NOT NULL AUTO_INCREMENT,
+	
+	AccessKey VARCHAR(150) NOT NULL,
+	SecretKey VARCHAR(150) NOT NULL,
+	CertUniqueId VARCHAR(200),
+
+	PRIMARY KEY(ID)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+
+SET foreign_key_checks = 1;
+

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/bc1c8979/awsapi-setup/db/mysql/deploy-db-bridge.sh
----------------------------------------------------------------------
diff --git a/awsapi-setup/db/mysql/deploy-db-bridge.sh b/awsapi-setup/db/mysql/deploy-db-bridge.sh
index abaa19b..2e8ceee 100644
--- a/awsapi-setup/db/mysql/deploy-db-bridge.sh
+++ b/awsapi-setup/db/mysql/deploy-db-bridge.sh
@@ -1,7 +1,20 @@
 #!/usr/bin/env bash
-# deploy-db-bridge.sh -- deploys the cloudbridge database configuration.
-#
-# set -x
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
 
 if [ ! -f cloudbridge_db.sql ]; then
   printf "Error: Unable to find cloudbridge_db.sql\n"

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/bc1c8979/awsapi-setup/init/debian/cloud-bridge
----------------------------------------------------------------------
diff --git a/awsapi-setup/init/debian/cloud-bridge b/awsapi-setup/init/debian/cloud-bridge
index 8fb0fbf..c1bf90b 100644
--- a/awsapi-setup/init/debian/cloud-bridge
+++ b/awsapi-setup/init/debian/cloud-bridge
@@ -1,4 +1,20 @@
 #!/bin/sh
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
 #
 # /etc/init.d/tomcat6 -- startup script for the Tomcat 6 servlet engine
 #

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/bc1c8979/awsapi-setup/init/rpm/cloud-bridge
----------------------------------------------------------------------
diff --git a/awsapi-setup/init/rpm/cloud-bridge b/awsapi-setup/init/rpm/cloud-bridge
index ee9bd51..444b771 100644
--- a/awsapi-setup/init/rpm/cloud-bridge
+++ b/awsapi-setup/init/rpm/cloud-bridge
@@ -1,5 +1,22 @@
 #!/bin/bash
 #
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
 # tomcat6      This shell script takes care of starting and stopping Tomcat
 #
 # chkconfig: - 80 20

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/bc1c8979/awsapi-setup/setup/cloud-setup-bridge
----------------------------------------------------------------------
diff --git a/awsapi-setup/setup/cloud-setup-bridge b/awsapi-setup/setup/cloud-setup-bridge
index ea3fa1f..d25072d 100644
--- a/awsapi-setup/setup/cloud-setup-bridge
+++ b/awsapi-setup/setup/cloud-setup-bridge
@@ -1,5 +1,22 @@
 #!/bin/bash
 #
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
 # Cloud.com Bridge setup script.
 #
 

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/bc1c8979/awsapi-setup/setup/cloudstack-aws-api-register
----------------------------------------------------------------------
diff --git a/awsapi-setup/setup/cloudstack-aws-api-register b/awsapi-setup/setup/cloudstack-aws-api-register
index 859a571..19b53fd 100644
--- a/awsapi-setup/setup/cloudstack-aws-api-register
+++ b/awsapi-setup/setup/cloudstack-aws-api-register
@@ -1,4 +1,21 @@
 #!/cygdrive/c/python26/python
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
 
 import base64
 import hmac


Mime
View raw message