diff --git a/api/src/com/cloud/api/BaseListDomainResourcesCmd.java b/api/src/com/cloud/api/BaseListDomainResourcesCmd.java index f301d9bea9f..9571e1263c1 100644 --- a/api/src/com/cloud/api/BaseListDomainResourcesCmd.java +++ b/api/src/com/cloud/api/BaseListDomainResourcesCmd.java @@ -18,14 +18,17 @@ package com.cloud.api; public abstract class BaseListDomainResourcesCmd extends BaseListCmd { - @Parameter(name = ApiConstants.LIST_ALL, type = CommandType.BOOLEAN, description = "If set to false, list only resources belonging to the command's caller; if set to true - list resources that the caller is authorized to see. Default value is false") + @Parameter(name = ApiConstants.LIST_ALL, type = CommandType.BOOLEAN, description = "If set to false, " + + "list only resources belonging to the command's caller; if set to true - list resources that the caller is authorized to see. Default value is false") private Boolean listAll; @IdentityMapper(entityTableName = "domain") - @Parameter(name = ApiConstants.DOMAIN_ID, type = CommandType.LONG, description = "list only resources belonging to the domain specified") + @Parameter(name = ApiConstants.DOMAIN_ID, type = CommandType.LONG, description = "list only resources" + + " belonging to the domain specified") private Long domainId; - @Parameter(name = ApiConstants.IS_RECURSIVE, type = CommandType.BOOLEAN, description = "defaults to false, but if true, lists all resources from the parent specified by the domainId till leaves.") + @Parameter(name = ApiConstants.IS_RECURSIVE, type = CommandType.BOOLEAN, description = "defaults to false," + + " but if true, lists all resources from the parent specified by the domainId till leaves.") private Boolean recursive; public boolean listAll() { diff --git a/api/src/com/cloud/api/BaseListProjectAndAccountResourcesCmd.java b/api/src/com/cloud/api/BaseListProjectAndAccountResourcesCmd.java index 8120ad1eb3a..78e70019c9b 100644 --- a/api/src/com/cloud/api/BaseListProjectAndAccountResourcesCmd.java +++ b/api/src/com/cloud/api/BaseListProjectAndAccountResourcesCmd.java @@ -19,7 +19,7 @@ package com.cloud.api; public abstract class BaseListProjectAndAccountResourcesCmd extends BaseListAccountResourcesCmd { @IdentityMapper(entityTableName = "projects") - @Parameter(name = ApiConstants.PROJECT_ID, type = CommandType.LONG, description = "list firewall rules by project") + @Parameter(name = ApiConstants.PROJECT_ID, type = CommandType.LONG, description = "list objects by project") private Long projectId; public Long getProjectId() { diff --git a/api/src/com/cloud/api/BaseListTaggedResourcesCmd.java b/api/src/com/cloud/api/BaseListTaggedResourcesCmd.java new file mode 100644 index 00000000000..9a70b107089 --- /dev/null +++ b/api/src/com/cloud/api/BaseListTaggedResourcesCmd.java @@ -0,0 +1,47 @@ +// Copyright 2012 Citrix Systems, Inc. Licensed under the +// Apache License, Version 2.0 (the "License"); you may not use this +// file except in compliance with the License. Citrix Systems, Inc. +// reserves all rights not expressly granted by 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. +// +// Automatically generated by addcopyright.py at 04/03/2012 +package com.cloud.api; + +import java.util.Collection; +import java.util.HashMap; +import java.util.Iterator; +import java.util.Map; + +import com.cloud.exception.InvalidParameterValueException; + +/** + * @author Alena Prokharchyk + */ +public abstract class BaseListTaggedResourcesCmd extends BaseListProjectAndAccountResourcesCmd{ + @Parameter(name = ApiConstants.TAGS, type = CommandType.MAP, description = "List resources by tags (key/value pairs)") + private Map tags; + + public Map getTags() { + Map tagsMap = null; + if (tags != null && !tags.isEmpty()) { + tagsMap = new HashMap(); + Collection servicesCollection = tags.values(); + Iterator iter = servicesCollection.iterator(); + while (iter.hasNext()) { + HashMap services = (HashMap) iter.next(); + String key = services.get("key"); + String value = services.get("value"); + if (value == null) { + throw new InvalidParameterValueException("No value is passed in for key " + key); + } + tagsMap.put(key, value); + } + } + return tagsMap; + } +} diff --git a/api/src/com/cloud/api/ResponseGenerator.java b/api/src/com/cloud/api/ResponseGenerator.java index 7a29c5ff583..996a5fcfd4b 100755 --- a/api/src/com/cloud/api/ResponseGenerator.java +++ b/api/src/com/cloud/api/ResponseGenerator.java @@ -300,9 +300,10 @@ public interface ResponseGenerator { /** * @param resourceTag + * @param keyValueOnly TODO * @return */ - ResourceTagResponse createResourceTagResponse(ResourceTag resourceTag); + ResourceTagResponse createResourceTagResponse(ResourceTag resourceTag, boolean keyValueOnly); Site2SiteVpnGatewayResponse createSite2SiteVpnGatewayResponse(Site2SiteVpnGateway result); diff --git a/api/src/com/cloud/api/commands/CreateTagsCmd.java b/api/src/com/cloud/api/commands/CreateTagsCmd.java index 5a0b56e544e..f87ae6e96d8 100644 --- a/api/src/com/cloud/api/commands/CreateTagsCmd.java +++ b/api/src/com/cloud/api/commands/CreateTagsCmd.java @@ -1,15 +1,20 @@ -// Copyright 2012 Citrix Systems, Inc. Licensed under the -// Apache License, Version 2.0 (the "License"); you may not use this -// file except in compliance with the License. Citrix Systems, Inc. -// reserves all rights not expressly granted by 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. -// -// Automatically generated by addcopyright.py at 04/03/2012 +// 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. +// package com.cloud.api.commands; import java.util.Collection; diff --git a/api/src/com/cloud/api/commands/DeleteTagsCmd.java b/api/src/com/cloud/api/commands/DeleteTagsCmd.java index a84a09ec38b..df6e173b777 100644 --- a/api/src/com/cloud/api/commands/DeleteTagsCmd.java +++ b/api/src/com/cloud/api/commands/DeleteTagsCmd.java @@ -1,4 +1,20 @@ -// Copyright 2012 Citrix Systems, Inc. Licensed under the +// 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. +// package com.cloud.api.commands; import java.util.Collection; @@ -17,7 +33,6 @@ import com.cloud.api.Parameter; import com.cloud.api.ServerApiException; import com.cloud.api.response.SuccessResponse; import com.cloud.event.EventTypes; -import com.cloud.server.ResourceTag; import com.cloud.server.ResourceTag.TaggedResourceType; /** @@ -28,7 +43,7 @@ import com.cloud.server.ResourceTag.TaggedResourceType; public class DeleteTagsCmd extends BaseAsyncCmd{ public static final Logger s_logger = Logger.getLogger(DeleteTagsCmd.class.getName()); - private static final String s_name = "deleteTagsresponse"; + private static final String s_name = "deletetagsresponse"; // /////////////////////////////////////////////////// // ////////////// API parameters ///////////////////// diff --git a/api/src/com/cloud/api/commands/ListFirewallRulesCmd.java b/api/src/com/cloud/api/commands/ListFirewallRulesCmd.java index b43afd52632..66dcc4d8e35 100644 --- a/api/src/com/cloud/api/commands/ListFirewallRulesCmd.java +++ b/api/src/com/cloud/api/commands/ListFirewallRulesCmd.java @@ -22,7 +22,7 @@ import java.util.List; import org.apache.log4j.Logger; import com.cloud.api.ApiConstants; -import com.cloud.api.BaseListProjectAndAccountResourcesCmd; +import com.cloud.api.BaseListTaggedResourcesCmd; import com.cloud.api.IdentityMapper; import com.cloud.api.Implementation; import com.cloud.api.Parameter; @@ -31,7 +31,7 @@ import com.cloud.api.response.ListResponse; import com.cloud.network.rules.FirewallRule; @Implementation(description="Lists all firewall rules for an IP address.", responseObject=FirewallResponse.class) -public class ListFirewallRulesCmd extends BaseListProjectAndAccountResourcesCmd { +public class ListFirewallRulesCmd extends BaseListTaggedResourcesCmd { public static final Logger s_logger = Logger.getLogger(ListFirewallRulesCmd.class.getName()); private static final String s_name = "listfirewallrulesresponse"; diff --git a/api/src/com/cloud/api/commands/ListIsosCmd.java b/api/src/com/cloud/api/commands/ListIsosCmd.java index 93ef1f10e77..35a996e9df3 100755 --- a/api/src/com/cloud/api/commands/ListIsosCmd.java +++ b/api/src/com/cloud/api/commands/ListIsosCmd.java @@ -24,7 +24,7 @@ import org.apache.log4j.Logger; import com.cloud.api.ApiConstants; import com.cloud.api.BaseCmd.CommandType; -import com.cloud.api.BaseListProjectAndAccountResourcesCmd; +import com.cloud.api.BaseListTaggedResourcesCmd; import com.cloud.api.IdentityMapper; import com.cloud.api.Implementation; import com.cloud.api.Parameter; @@ -37,7 +37,7 @@ import com.cloud.user.UserContext; import com.cloud.utils.Pair; @Implementation(description="Lists all available ISO files.", responseObject=TemplateResponse.class) -public class ListIsosCmd extends BaseListProjectAndAccountResourcesCmd { +public class ListIsosCmd extends BaseListTaggedResourcesCmd { public static final Logger s_logger = Logger.getLogger(ListIsosCmd.class.getName()); private static final String s_name = "listisosresponse"; diff --git a/api/src/com/cloud/api/commands/ListLoadBalancerRulesCmd.java b/api/src/com/cloud/api/commands/ListLoadBalancerRulesCmd.java index d30abdfd3e1..43b05402269 100644 --- a/api/src/com/cloud/api/commands/ListLoadBalancerRulesCmd.java +++ b/api/src/com/cloud/api/commands/ListLoadBalancerRulesCmd.java @@ -22,8 +22,7 @@ import java.util.List; import org.apache.log4j.Logger; import com.cloud.api.ApiConstants; -import com.cloud.api.BaseCmd.CommandType; -import com.cloud.api.BaseListProjectAndAccountResourcesCmd; +import com.cloud.api.BaseListTaggedResourcesCmd; import com.cloud.api.IdentityMapper; import com.cloud.api.Implementation; import com.cloud.api.Parameter; @@ -32,7 +31,7 @@ import com.cloud.api.response.LoadBalancerResponse; import com.cloud.network.rules.LoadBalancer; @Implementation(description = "Lists load balancer rules.", responseObject = LoadBalancerResponse.class) -public class ListLoadBalancerRulesCmd extends BaseListProjectAndAccountResourcesCmd { +public class ListLoadBalancerRulesCmd extends BaseListTaggedResourcesCmd { public static final Logger s_logger = Logger.getLogger(ListLoadBalancerRulesCmd.class.getName()); private static final String s_name = "listloadbalancerrulesresponse"; diff --git a/api/src/com/cloud/api/commands/ListNetworksCmd.java b/api/src/com/cloud/api/commands/ListNetworksCmd.java index 689f1db4e2c..14659dccf1a 100644 --- a/api/src/com/cloud/api/commands/ListNetworksCmd.java +++ b/api/src/com/cloud/api/commands/ListNetworksCmd.java @@ -22,7 +22,7 @@ import java.util.List; import org.apache.log4j.Logger; import com.cloud.api.ApiConstants; -import com.cloud.api.BaseListProjectAndAccountResourcesCmd; +import com.cloud.api.BaseListTaggedResourcesCmd; import com.cloud.api.IdentityMapper; import com.cloud.api.Implementation; import com.cloud.api.Parameter; @@ -32,7 +32,7 @@ import com.cloud.network.Network; @Implementation(description="Lists all available networks.", responseObject=NetworkResponse.class) -public class ListNetworksCmd extends BaseListProjectAndAccountResourcesCmd { +public class ListNetworksCmd extends BaseListTaggedResourcesCmd { public static final Logger s_logger = Logger.getLogger(ListNetworksCmd.class.getName()); private static final String _name = "listnetworksresponse"; diff --git a/api/src/com/cloud/api/commands/ListPortForwardingRulesCmd.java b/api/src/com/cloud/api/commands/ListPortForwardingRulesCmd.java index e75fae5a16b..499a574bffb 100644 --- a/api/src/com/cloud/api/commands/ListPortForwardingRulesCmd.java +++ b/api/src/com/cloud/api/commands/ListPortForwardingRulesCmd.java @@ -22,7 +22,7 @@ import java.util.List; import org.apache.log4j.Logger; import com.cloud.api.ApiConstants; -import com.cloud.api.BaseListProjectAndAccountResourcesCmd; +import com.cloud.api.BaseListTaggedResourcesCmd; import com.cloud.api.IdentityMapper; import com.cloud.api.Implementation; import com.cloud.api.Parameter; @@ -30,12 +30,12 @@ import com.cloud.api.response.FirewallRuleResponse; import com.cloud.api.response.ListResponse; import com.cloud.network.rules.PortForwardingRule; -@Implementation(description="Lists all port forwarding rules for an IP address.", responseObject=FirewallRuleResponse.class) -public class ListPortForwardingRulesCmd extends BaseListProjectAndAccountResourcesCmd { - public static final Logger s_logger = Logger.getLogger(ListPortForwardingRulesCmd.class.getName()); - - private static final String s_name = "listportforwardingrulesresponse"; - +@Implementation(description="Lists all port forwarding rules for an IP address.", responseObject=FirewallRuleResponse.class) +public class ListPortForwardingRulesCmd extends BaseListTaggedResourcesCmd { + public static final Logger s_logger = Logger.getLogger(ListPortForwardingRulesCmd.class.getName()); + + private static final String s_name = "listportforwardingrulesresponse"; + ///////////////////////////////////////////////////// //////////////// API parameters ///////////////////// ///////////////////////////////////////////////////// diff --git a/api/src/com/cloud/api/commands/ListPublicIpAddressesCmd.java b/api/src/com/cloud/api/commands/ListPublicIpAddressesCmd.java index b63a5bcec3a..c6acf97c214 100644 --- a/api/src/com/cloud/api/commands/ListPublicIpAddressesCmd.java +++ b/api/src/com/cloud/api/commands/ListPublicIpAddressesCmd.java @@ -22,7 +22,7 @@ import java.util.List; import org.apache.log4j.Logger; import com.cloud.api.ApiConstants; -import com.cloud.api.BaseListProjectAndAccountResourcesCmd; +import com.cloud.api.BaseListTaggedResourcesCmd; import com.cloud.api.IdentityMapper; import com.cloud.api.Implementation; import com.cloud.api.Parameter; @@ -31,8 +31,9 @@ import com.cloud.api.response.ListResponse; import com.cloud.async.AsyncJob; import com.cloud.network.IpAddress; + @Implementation(description="Lists all public ip addresses", responseObject=IPAddressResponse.class) -public class ListPublicIpAddressesCmd extends BaseListProjectAndAccountResourcesCmd { +public class ListPublicIpAddressesCmd extends BaseListTaggedResourcesCmd { public static final Logger s_logger = Logger.getLogger(ListPublicIpAddressesCmd.class.getName()); private static final String s_name = "listpublicipaddressesresponse"; diff --git a/api/src/com/cloud/api/commands/ListSecurityGroupsCmd.java b/api/src/com/cloud/api/commands/ListSecurityGroupsCmd.java index 5891ada1a9c..6da023af848 100644 --- a/api/src/com/cloud/api/commands/ListSecurityGroupsCmd.java +++ b/api/src/com/cloud/api/commands/ListSecurityGroupsCmd.java @@ -21,8 +21,7 @@ import java.util.List; import org.apache.log4j.Logger; import com.cloud.api.ApiConstants; -import com.cloud.api.BaseCmd.CommandType; -import com.cloud.api.BaseListProjectAndAccountResourcesCmd; +import com.cloud.api.BaseListTaggedResourcesCmd; import com.cloud.api.IdentityMapper; import com.cloud.api.Implementation; import com.cloud.api.Parameter; @@ -31,19 +30,20 @@ import com.cloud.api.response.SecurityGroupResponse; import com.cloud.async.AsyncJob; import com.cloud.network.security.SecurityGroupRules; -@Implementation(description="Lists security groups", responseObject=SecurityGroupResponse.class) -public class ListSecurityGroupsCmd extends BaseListProjectAndAccountResourcesCmd { - public static final Logger s_logger = Logger.getLogger(ListSecurityGroupsCmd.class.getName()); - - private static final String s_name = "listsecuritygroupsresponse"; - - ///////////////////////////////////////////////////// - //////////////// API parameters ///////////////////// - ///////////////////////////////////////////////////// - - @Parameter(name=ApiConstants.SECURITY_GROUP_NAME, type=CommandType.STRING, description="lists security groups by name") - private String securityGroupName; - + +@Implementation(description="Lists security groups", responseObject=SecurityGroupResponse.class) +public class ListSecurityGroupsCmd extends BaseListTaggedResourcesCmd { + public static final Logger s_logger = Logger.getLogger(ListSecurityGroupsCmd.class.getName()); + + private static final String s_name = "listsecuritygroupsresponse"; + + ///////////////////////////////////////////////////// + //////////////// API parameters ///////////////////// + ///////////////////////////////////////////////////// + + @Parameter(name=ApiConstants.SECURITY_GROUP_NAME, type=CommandType.STRING, description="lists security groups by name") + private String securityGroupName; + @IdentityMapper(entityTableName="vm_instance") @Parameter(name=ApiConstants.VIRTUAL_MACHINE_ID, type=CommandType.LONG, description="lists security groups by virtual machine id") private Long virtualMachineId; diff --git a/api/src/com/cloud/api/commands/ListSnapshotsCmd.java b/api/src/com/cloud/api/commands/ListSnapshotsCmd.java index 67ea1877dd1..d7b2c9e05f9 100644 --- a/api/src/com/cloud/api/commands/ListSnapshotsCmd.java +++ b/api/src/com/cloud/api/commands/ListSnapshotsCmd.java @@ -22,7 +22,7 @@ import java.util.List; import org.apache.log4j.Logger; import com.cloud.api.ApiConstants; -import com.cloud.api.BaseListProjectAndAccountResourcesCmd; +import com.cloud.api.BaseListTaggedResourcesCmd; import com.cloud.api.IdentityMapper; import com.cloud.api.Implementation; import com.cloud.api.Parameter; @@ -31,12 +31,13 @@ import com.cloud.api.response.SnapshotResponse; import com.cloud.async.AsyncJob; import com.cloud.storage.Snapshot; -@Implementation(description="Lists all available snapshots for the account.", responseObject=SnapshotResponse.class) -public class ListSnapshotsCmd extends BaseListProjectAndAccountResourcesCmd { - public static final Logger s_logger = Logger.getLogger(ListSnapshotsCmd.class.getName()); - - private static final String s_name = "listsnapshotsresponse"; +@Implementation(description="Lists all available snapshots for the account.", responseObject=SnapshotResponse.class) +public class ListSnapshotsCmd extends BaseListTaggedResourcesCmd { + public static final Logger s_logger = Logger.getLogger(ListSnapshotsCmd.class.getName()); + + private static final String s_name = "listsnapshotsresponse"; + ///////////////////////////////////////////////////// //////////////// API parameters ///////////////////// ///////////////////////////////////////////////////// diff --git a/api/src/com/cloud/api/commands/ListTagsCmd.java b/api/src/com/cloud/api/commands/ListTagsCmd.java index 8b9eae195ed..2c226797cd9 100644 --- a/api/src/com/cloud/api/commands/ListTagsCmd.java +++ b/api/src/com/cloud/api/commands/ListTagsCmd.java @@ -1,15 +1,20 @@ -// Copyright 2012 Citrix Systems, Inc. Licensed under the -// Apache License, Version 2.0 (the "License"); you may not use this -// file except in compliance with the License. Citrix Systems, Inc. -// reserves all rights not expressly granted by 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. -// -// Automatically generated by addcopyright.py at 04/03/2012 +// 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. +// package com.cloud.api.commands; import java.util.ArrayList; @@ -58,7 +63,7 @@ public class ListTagsCmd extends BaseListProjectAndAccountResourcesCmd{ ListResponse response = new ListResponse(); List tagResponses = new ArrayList(); for (ResourceTag tag : tags) { - ResourceTagResponse tagResponse = _responseGenerator.createResourceTagResponse(tag); + ResourceTagResponse tagResponse = _responseGenerator.createResourceTagResponse(tag, false); tagResponses.add(tagResponse); } response.setResponses(tagResponses); diff --git a/api/src/com/cloud/api/commands/ListTemplatesCmd.java b/api/src/com/cloud/api/commands/ListTemplatesCmd.java index 82864923f53..c1002b8b458 100755 --- a/api/src/com/cloud/api/commands/ListTemplatesCmd.java +++ b/api/src/com/cloud/api/commands/ListTemplatesCmd.java @@ -23,7 +23,8 @@ import java.util.Set; import org.apache.log4j.Logger; import com.cloud.api.ApiConstants; -import com.cloud.api.BaseListProjectAndAccountResourcesCmd; +import com.cloud.api.BaseCmd.CommandType; +import com.cloud.api.BaseListTaggedResourcesCmd; import com.cloud.api.IdentityMapper; import com.cloud.api.Implementation; import com.cloud.api.Parameter; @@ -36,7 +37,7 @@ import com.cloud.user.UserContext; import com.cloud.utils.Pair; @Implementation(description="List all public, private, and privileged templates.", responseObject=TemplateResponse.class) -public class ListTemplatesCmd extends BaseListProjectAndAccountResourcesCmd { +public class ListTemplatesCmd extends BaseListTaggedResourcesCmd { public static final Logger s_logger = Logger.getLogger(ListTemplatesCmd.class.getName()); private static final String s_name = "listtemplatesresponse"; diff --git a/api/src/com/cloud/api/commands/ListVMsCmd.java b/api/src/com/cloud/api/commands/ListVMsCmd.java index 402cd1b6233..acc459bed86 100755 --- a/api/src/com/cloud/api/commands/ListVMsCmd.java +++ b/api/src/com/cloud/api/commands/ListVMsCmd.java @@ -24,7 +24,7 @@ import org.apache.log4j.Logger; import com.cloud.api.ApiConstants; import com.cloud.api.ApiConstants.VMDetails; -import com.cloud.api.BaseListProjectAndAccountResourcesCmd; +import com.cloud.api.BaseListTaggedResourcesCmd; import com.cloud.api.IdentityMapper; import com.cloud.api.Implementation; import com.cloud.api.Parameter; @@ -35,7 +35,7 @@ import com.cloud.exception.InvalidParameterValueException; import com.cloud.uservm.UserVm; @Implementation(description="List the virtual machines owned by the account.", responseObject=UserVmResponse.class) -public class ListVMsCmd extends BaseListProjectAndAccountResourcesCmd { +public class ListVMsCmd extends BaseListTaggedResourcesCmd { public static final Logger s_logger = Logger.getLogger(ListVMsCmd.class.getName()); private static final String s_name = "listvirtualmachinesresponse"; diff --git a/api/src/com/cloud/api/commands/ListVolumesCmd.java b/api/src/com/cloud/api/commands/ListVolumesCmd.java index 2f07ea24319..e0393a9b76b 100755 --- a/api/src/com/cloud/api/commands/ListVolumesCmd.java +++ b/api/src/com/cloud/api/commands/ListVolumesCmd.java @@ -22,7 +22,7 @@ import java.util.List; import org.apache.log4j.Logger; import com.cloud.api.ApiConstants; -import com.cloud.api.BaseListProjectAndAccountResourcesCmd; +import com.cloud.api.BaseListTaggedResourcesCmd; import com.cloud.api.IdentityMapper; import com.cloud.api.Implementation; import com.cloud.api.Parameter; @@ -31,12 +31,13 @@ import com.cloud.api.response.VolumeResponse; import com.cloud.async.AsyncJob; import com.cloud.storage.Volume; -@Implementation(description="Lists all volumes.", responseObject=VolumeResponse.class) -public class ListVolumesCmd extends BaseListProjectAndAccountResourcesCmd { - public static final Logger s_logger = Logger.getLogger(ListVolumesCmd.class.getName()); - - private static final String s_name = "listvolumesresponse"; +@Implementation(description="Lists all volumes.", responseObject=VolumeResponse.class) +public class ListVolumesCmd extends BaseListTaggedResourcesCmd { + public static final Logger s_logger = Logger.getLogger(ListVolumesCmd.class.getName()); + + private static final String s_name = "listvolumesresponse"; + ///////////////////////////////////////////////////// //////////////// API parameters ///////////////////// ///////////////////////////////////////////////////// diff --git a/api/src/com/cloud/api/commands/UpgradeSystemVMCmd.java b/api/src/com/cloud/api/commands/UpgradeSystemVMCmd.java index 18e506c42b5..a36844aeb3b 100644 --- a/api/src/com/cloud/api/commands/UpgradeSystemVMCmd.java +++ b/api/src/com/cloud/api/commands/UpgradeSystemVMCmd.java @@ -14,23 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/** - * Copyright (C) 2012 Citrix Systems, Inc. All rights reserved. - * - * This software is licensed under the GNU General Public License v3 or later. - * - * It is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or any later version. - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - * - */ package com.cloud.api.commands; import org.apache.log4j.Logger; diff --git a/api/src/com/cloud/api/response/FirewallResponse.java b/api/src/com/cloud/api/response/FirewallResponse.java index a6fd5970a20..bcb78e2f8f6 100644 --- a/api/src/com/cloud/api/response/FirewallResponse.java +++ b/api/src/com/cloud/api/response/FirewallResponse.java @@ -16,6 +16,8 @@ // under the License. package com.cloud.api.response; +import java.util.List; + import com.cloud.api.ApiConstants; import com.cloud.serializer.Param; import com.cloud.utils.IdentityProxy; @@ -53,6 +55,9 @@ public class FirewallResponse extends BaseResponse { @SerializedName(ApiConstants.ICMP_CODE) @Param(description = "error code for this icmp message") private Integer icmpCode; + @SerializedName(ApiConstants.TAGS) @Param(description="the list of resource tags associated with the rule", responseObject = ResourceTagResponse.class) + private List tags; + public void setId(Long id) { this.id.setValue(id); } @@ -92,4 +97,8 @@ public class FirewallResponse extends BaseResponse { public void setIcmpCode(Integer icmpCode) { this.icmpCode = icmpCode; } + + public void setTags(List tags) { + this.tags = tags; + } } diff --git a/api/src/com/cloud/api/response/FirewallRuleResponse.java b/api/src/com/cloud/api/response/FirewallRuleResponse.java index fe1e4aa7642..252ad0dafe6 100644 --- a/api/src/com/cloud/api/response/FirewallRuleResponse.java +++ b/api/src/com/cloud/api/response/FirewallRuleResponse.java @@ -16,11 +16,14 @@ // under the License. package com.cloud.api.response; +import java.util.List; + import com.cloud.api.ApiConstants; -import com.cloud.utils.IdentityProxy; import com.cloud.serializer.Param; +import com.cloud.utils.IdentityProxy; import com.google.gson.annotations.SerializedName; +@SuppressWarnings("unused") public class FirewallRuleResponse extends BaseResponse{ @SerializedName(ApiConstants.ID) @Param(description="the ID of the port forwarding rule") private IdentityProxy id = new IdentityProxy("firewall_rules"); @@ -61,7 +64,8 @@ public class FirewallRuleResponse extends BaseResponse{ @SerializedName(ApiConstants.CIDR_LIST) @Param(description="the cidr list to forward traffic from") private String cidrList; - + @SerializedName(ApiConstants.TAGS) @Param(description="the list of resource tags associated with the rule", responseObject = ResourceTagResponse.class) + private List tags; public Long getId() { return id.getValue(); @@ -167,4 +171,7 @@ public class FirewallRuleResponse extends BaseResponse{ this.cidrList = cidrs; } + public void setTags(List tags) { + this.tags = tags; + } } diff --git a/api/src/com/cloud/api/response/IPAddressResponse.java b/api/src/com/cloud/api/response/IPAddressResponse.java index a6c9c947481..da73b69ca3d 100644 --- a/api/src/com/cloud/api/response/IPAddressResponse.java +++ b/api/src/com/cloud/api/response/IPAddressResponse.java @@ -17,10 +17,11 @@ package com.cloud.api.response; import java.util.Date; +import java.util.List; import com.cloud.api.ApiConstants; -import com.cloud.utils.IdentityProxy; import com.cloud.serializer.Param; +import com.cloud.utils.IdentityProxy; import com.google.gson.annotations.SerializedName; @SuppressWarnings("unused") @@ -99,6 +100,13 @@ public class IPAddressResponse extends BaseResponse implements ControlledEntityR @SerializedName(ApiConstants.VPC_ID) @Param(description="VPC the ip belongs to") private IdentityProxy vpcId = new IdentityProxy("vpc"); + @SerializedName(ApiConstants.TAGS) @Param(description="the list of resource tags associated with ip address", responseObject = ResourceTagResponse.class) + private List tags; + +/* + @SerializedName(ApiConstants.JOB_ID) @Param(description="shows the current pending asynchronous job ID. This tag is not returned if no current pending jobs are acting on the volume") + private IdentityProxy jobId = new IdentityProxy("async_job"); +*/ public void setIpAddress(String ipAddress) { @@ -214,4 +222,8 @@ public class IPAddressResponse extends BaseResponse implements ControlledEntityR public void setVpcId(Long vpcId) { this.vpcId.setValue(vpcId); } + + public void setTags(List tags) { + this.tags = tags; + } } diff --git a/api/src/com/cloud/api/response/LoadBalancerResponse.java b/api/src/com/cloud/api/response/LoadBalancerResponse.java index ab1d67957e0..016bccc7188 100644 --- a/api/src/com/cloud/api/response/LoadBalancerResponse.java +++ b/api/src/com/cloud/api/response/LoadBalancerResponse.java @@ -16,9 +16,11 @@ // under the License. package com.cloud.api.response; +import java.util.List; + import com.cloud.api.ApiConstants; -import com.cloud.utils.IdentityProxy; import com.cloud.serializer.Param; +import com.cloud.utils.IdentityProxy; import com.google.gson.annotations.SerializedName; @SuppressWarnings("unused") @@ -83,6 +85,9 @@ public class LoadBalancerResponse extends BaseResponse implements ControlledEnti @SerializedName(ApiConstants.ZONE_ID) @Param(description = "the id of the zone the rule belongs to") private IdentityProxy zoneId = new IdentityProxy("data_center"); + + @SerializedName(ApiConstants.TAGS) @Param(description="the list of resource tags associated with load balancer", responseObject = ResourceTagResponse.class) + private List tags; public void setId(Long id) { this.id.setValue(id); @@ -149,5 +154,9 @@ public class LoadBalancerResponse extends BaseResponse implements ControlledEnti public void setProjectName(String projectName) { this.projectName = projectName; } + + public void setTags(List tags) { + this.tags = tags; + } } diff --git a/api/src/com/cloud/api/response/NetworkResponse.java b/api/src/com/cloud/api/response/NetworkResponse.java index 38e4cd42f3a..a4158f16323 100644 --- a/api/src/com/cloud/api/response/NetworkResponse.java +++ b/api/src/com/cloud/api/response/NetworkResponse.java @@ -137,6 +137,9 @@ public class NetworkResponse extends BaseResponse implements ControlledEntityRes @SerializedName(ApiConstants.CAN_USE_FOR_DEPLOY) @Param(description="list networks available for vm deployment") private Boolean canUseForDeploy; + @SerializedName(ApiConstants.TAGS) @Param(description="the list of resource tags associated with network", responseObject = ResourceTagResponse.class) + private List tags; + public void setId(Long id) { this.id.setValue(id); } @@ -286,4 +289,8 @@ public class NetworkResponse extends BaseResponse implements ControlledEntityRes public void setCanUseForDeploy(Boolean canUseForDeploy) { this.canUseForDeploy = canUseForDeploy; } + + public void setTags(List tags) { + this.tags = tags; + } } diff --git a/api/src/com/cloud/api/response/ResourceTagResponse.java b/api/src/com/cloud/api/response/ResourceTagResponse.java index aa69141113e..2c5fd9e6a60 100644 --- a/api/src/com/cloud/api/response/ResourceTagResponse.java +++ b/api/src/com/cloud/api/response/ResourceTagResponse.java @@ -1,15 +1,19 @@ -// Copyright 2012 Citrix Systems, Inc. Licensed under the -// Apache License, Version 2.0 (the "License"); you may not use this -// file except in compliance with the License. Citrix Systems, Inc. -// reserves all rights not expressly granted by 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. -// -// Automatically generated by addcopyright.py at 04/03/2012 +// 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. package com.cloud.api.response; import com.cloud.api.ApiConstants; diff --git a/api/src/com/cloud/api/response/SecurityGroupResponse.java b/api/src/com/cloud/api/response/SecurityGroupResponse.java index 862b0fe203e..5c6deedfb34 100644 --- a/api/src/com/cloud/api/response/SecurityGroupResponse.java +++ b/api/src/com/cloud/api/response/SecurityGroupResponse.java @@ -19,8 +19,8 @@ package com.cloud.api.response; import java.util.List; import com.cloud.api.ApiConstants; -import com.cloud.utils.IdentityProxy; import com.cloud.serializer.Param; +import com.cloud.utils.IdentityProxy; import com.google.gson.annotations.SerializedName; @SuppressWarnings("unused") @@ -55,6 +55,9 @@ public class SecurityGroupResponse extends BaseResponse implements ControlledEnt @SerializedName("egressrule") @Param(description="the list of egress rules associated with the security group", responseObject = SecurityGroupRuleResponse.class) private List egressRules; + @SerializedName(ApiConstants.TAGS) @Param(description="the list of resource tags associated with the rule", responseObject = ResourceTagResponse.class) + private List tags; + public void setId(Long id) { this.id.setValue(id); } @@ -130,4 +133,8 @@ public class SecurityGroupResponse extends BaseResponse implements ControlledEnt public void setProjectName(String projectName) { this.projectName = projectName; } + + public void setTags(List tags) { + this.tags = tags; + } } diff --git a/api/src/com/cloud/api/response/SnapshotResponse.java b/api/src/com/cloud/api/response/SnapshotResponse.java index d945e36df56..71b1b14b8b5 100644 --- a/api/src/com/cloud/api/response/SnapshotResponse.java +++ b/api/src/com/cloud/api/response/SnapshotResponse.java @@ -17,11 +17,12 @@ package com.cloud.api.response; import java.util.Date; +import java.util.List; import com.cloud.api.ApiConstants; -import com.cloud.utils.IdentityProxy; import com.cloud.serializer.Param; import com.cloud.storage.Snapshot; +import com.cloud.utils.IdentityProxy; import com.google.gson.annotations.SerializedName; @SuppressWarnings("unused") @@ -79,6 +80,9 @@ public class SnapshotResponse extends BaseResponse implements ControlledEntityRe @SerializedName(ApiConstants.STATE) @Param(description = "the state of the snapshot. BackedUp means that snapshot is ready to be used; Creating - the snapshot is being allocated on the primary storage; BackingUp - the snapshot is being backed up on secondary storage") private Snapshot.Status state; + + @SerializedName(ApiConstants.TAGS) @Param(description="the list of resource tags associated with snapshot", responseObject = ResourceTagResponse.class) + private List tags; @Override public Long getObjectId() { @@ -154,4 +158,8 @@ public class SnapshotResponse extends BaseResponse implements ControlledEntityRe public void setProjectName(String projectName) { this.projectName = projectName; } + + public void setTags(List tags) { + this.tags = tags; + } } diff --git a/api/src/com/cloud/api/response/TemplateResponse.java b/api/src/com/cloud/api/response/TemplateResponse.java index 8a4456c76db..5c3d3399799 100755 --- a/api/src/com/cloud/api/response/TemplateResponse.java +++ b/api/src/com/cloud/api/response/TemplateResponse.java @@ -17,6 +17,7 @@ package com.cloud.api.response; import java.util.Date; +import java.util.List; import java.util.Map; import com.cloud.api.ApiConstants; @@ -128,6 +129,9 @@ public class TemplateResponse extends BaseResponse implements ControlledEntityRe @SerializedName(ApiConstants.DETAILS) @Param(description="additional key/value details tied with template") private Map details; + @SerializedName(ApiConstants.TAGS) @Param(description="the list of resource tags associated with tempate", responseObject = ResourceTagResponse.class) + private List tags; + @Override public Long getObjectId() { @@ -277,4 +281,8 @@ public class TemplateResponse extends BaseResponse implements ControlledEntityRe public void setDetails(Map details) { this.details = details; } + + public void setTags(List tags) { + this.tags = tags; + } } diff --git a/api/src/com/cloud/api/response/UserVmResponse.java b/api/src/com/cloud/api/response/UserVmResponse.java index e3ec3a3d06d..652e026d72c 100755 --- a/api/src/com/cloud/api/response/UserVmResponse.java +++ b/api/src/com/cloud/api/response/UserVmResponse.java @@ -20,8 +20,8 @@ import java.util.Date; import java.util.List; import com.cloud.api.ApiConstants; -import com.cloud.utils.IdentityProxy; import com.cloud.serializer.Param; +import com.cloud.utils.IdentityProxy; import com.google.gson.annotations.SerializedName; @SuppressWarnings("unused") @@ -154,6 +154,9 @@ public class UserVmResponse extends BaseResponse implements ControlledEntityResp @SerializedName(ApiConstants.INSTANCE_NAME) @Param(description="instance name of the user vm; this parameter is returned to the ROOT admin only", since="3.0.1") private String instanceName; + + @SerializedName(ApiConstants.TAGS) @Param(description="the list of resource tags associated with vm", responseObject = ResourceTagResponse.class) + private List tags; public void setHypervisor(String hypervisor) { this.hypervisor = hypervisor; @@ -341,4 +344,8 @@ public class UserVmResponse extends BaseResponse implements ControlledEntityResp public void setInstanceName(String instanceName) { this.instanceName = instanceName; } + + public void setTags(List tags) { + this.tags = tags; + } } diff --git a/api/src/com/cloud/api/response/VolumeResponse.java b/api/src/com/cloud/api/response/VolumeResponse.java index 926e3688e54..b5633908a81 100755 --- a/api/src/com/cloud/api/response/VolumeResponse.java +++ b/api/src/com/cloud/api/response/VolumeResponse.java @@ -17,10 +17,11 @@ package com.cloud.api.response; import java.util.Date; +import java.util.List; import com.cloud.api.ApiConstants; -import com.cloud.utils.IdentityProxy; import com.cloud.serializer.Param; +import com.cloud.utils.IdentityProxy; import com.google.gson.annotations.SerializedName; @SuppressWarnings("unused") @@ -150,6 +151,9 @@ public class VolumeResponse extends BaseResponse implements ControlledEntityResp @SerializedName(ApiConstants.STATUS) @Param(description="the status of the volume") private String status; + + @SerializedName(ApiConstants.TAGS) @Param(description="the list of resource tags associated with volume", responseObject = ResourceTagResponse.class) + private List tags; @Override public Long getObjectId() { @@ -293,4 +297,8 @@ public class VolumeResponse extends BaseResponse implements ControlledEntityResp public void setProjectName(String projectName) { this.projectName = projectName; } + + public void setTags(List tags) { + this.tags = tags; + } } diff --git a/api/src/com/cloud/server/ResourceTag.java b/api/src/com/cloud/server/ResourceTag.java index c3307b6b17b..640512b3a32 100644 --- a/api/src/com/cloud/server/ResourceTag.java +++ b/api/src/com/cloud/server/ResourceTag.java @@ -1,22 +1,23 @@ -// Copyright 2012 Citrix Systems, Inc. Licensed under the -// Apache License, Version 2.0 (the "License"); you may not use this -// file except in compliance with the License. Citrix Systems, Inc. -// reserves all rights not expressly granted by 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. -// -// Automatically generated by addcopyright.py at 04/03/2012 +// 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. package com.cloud.server; import com.cloud.acl.ControlledEntity; -/** - * @author Alena Prokharchyk - */ public interface ResourceTag extends ControlledEntity{ public enum TaggedResourceType { @@ -63,4 +64,9 @@ public interface ResourceTag extends ControlledEntity{ */ String getCustomer(); + /** + * @return + */ + String getResourceUuid(); + } diff --git a/api/src/com/cloud/server/TaggedResourceService.java b/api/src/com/cloud/server/TaggedResourceService.java index d76d19265df..51a4779de27 100644 --- a/api/src/com/cloud/server/TaggedResourceService.java +++ b/api/src/com/cloud/server/TaggedResourceService.java @@ -1,17 +1,23 @@ -// Copyright 2012 Citrix Systems, Inc. Licensed under the -// Apache License, Version 2.0 (the "License"); you may not use this -// file except in compliance with the License. Citrix Systems, Inc. -// reserves all rights not expressly granted by 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. -// -// Automatically generated by addcopyright.py at 04/03/2012 +// 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.package com.cloud.server; + package com.cloud.server; + import java.util.List; import java.util.Map; @@ -54,4 +60,6 @@ public interface TaggedResourceService { * @return */ boolean deleteTags(List resourceIds, TaggedResourceType resourceType, Map tags); + + List listByResourceTypeAndId(TaggedResourceType type, long resourceId); } diff --git a/awsapi/src/com/cloud/bridge/auth/ec2/AuthenticationHandler.java b/awsapi/src/com/cloud/bridge/auth/ec2/AuthenticationHandler.java index f17e49393cd..3b28c001b7d 100644 --- a/awsapi/src/com/cloud/bridge/auth/ec2/AuthenticationHandler.java +++ b/awsapi/src/com/cloud/bridge/auth/ec2/AuthenticationHandler.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.auth.ec2; import org.apache.axiom.soap.SOAPEnvelope; diff --git a/awsapi/src/com/cloud/bridge/auth/ec2/AuthenticationModule.java b/awsapi/src/com/cloud/bridge/auth/ec2/AuthenticationModule.java index 7c446d25bde..2f728300820 100644 --- a/awsapi/src/com/cloud/bridge/auth/ec2/AuthenticationModule.java +++ b/awsapi/src/com/cloud/bridge/auth/ec2/AuthenticationModule.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.auth.ec2; import org.apache.axis2.modules.Module; diff --git a/awsapi/src/com/cloud/bridge/auth/s3/AuthenticationHandler.java b/awsapi/src/com/cloud/bridge/auth/s3/AuthenticationHandler.java index ac2fa55c789..f7a1a7e8c6e 100644 --- a/awsapi/src/com/cloud/bridge/auth/s3/AuthenticationHandler.java +++ b/awsapi/src/com/cloud/bridge/auth/s3/AuthenticationHandler.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.auth.s3; import java.sql.SQLException; diff --git a/awsapi/src/com/cloud/bridge/auth/s3/AuthenticationModule.java b/awsapi/src/com/cloud/bridge/auth/s3/AuthenticationModule.java index 3e6bcacb620..b830902e044 100644 --- a/awsapi/src/com/cloud/bridge/auth/s3/AuthenticationModule.java +++ b/awsapi/src/com/cloud/bridge/auth/s3/AuthenticationModule.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.auth.s3; import org.apache.axis2.modules.Module; diff --git a/awsapi/src/com/cloud/bridge/io/FileRangeDataSource.java b/awsapi/src/com/cloud/bridge/io/FileRangeDataSource.java index 8e62a43a35d..2932ecd30c0 100644 --- a/awsapi/src/com/cloud/bridge/io/FileRangeDataSource.java +++ b/awsapi/src/com/cloud/bridge/io/FileRangeDataSource.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.io; import java.io.File; diff --git a/awsapi/src/com/cloud/bridge/io/FileRangeInputStream.java b/awsapi/src/com/cloud/bridge/io/FileRangeInputStream.java index 383fbd558a9..4d3c50ee9fe 100644 --- a/awsapi/src/com/cloud/bridge/io/FileRangeInputStream.java +++ b/awsapi/src/com/cloud/bridge/io/FileRangeInputStream.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.io; import java.io.File; diff --git a/awsapi/src/com/cloud/bridge/io/MultiPartDimeInputStream.java b/awsapi/src/com/cloud/bridge/io/MultiPartDimeInputStream.java index 6373c036204..03688fe3bb9 100644 --- a/awsapi/src/com/cloud/bridge/io/MultiPartDimeInputStream.java +++ b/awsapi/src/com/cloud/bridge/io/MultiPartDimeInputStream.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.io; import org.apache.log4j.Logger; diff --git a/awsapi/src/com/cloud/bridge/io/S3FileSystemBucketAdapter.java b/awsapi/src/com/cloud/bridge/io/S3FileSystemBucketAdapter.java index fe08d1460fc..d4856a560ce 100644 --- a/awsapi/src/com/cloud/bridge/io/S3FileSystemBucketAdapter.java +++ b/awsapi/src/com/cloud/bridge/io/S3FileSystemBucketAdapter.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.io; import java.io.File; diff --git a/awsapi/src/com/cloud/bridge/lifecycle/ServiceEngineLifecycle.java b/awsapi/src/com/cloud/bridge/lifecycle/ServiceEngineLifecycle.java index 9aef8d7926b..22adfb8df5c 100644 --- a/awsapi/src/com/cloud/bridge/lifecycle/ServiceEngineLifecycle.java +++ b/awsapi/src/com/cloud/bridge/lifecycle/ServiceEngineLifecycle.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.lifecycle; import org.apache.axis2.context.ConfigurationContext; diff --git a/awsapi/src/com/cloud/bridge/model/MHost.java b/awsapi/src/com/cloud/bridge/model/MHost.java index 6c59bf04c29..2832e1aa83a 100644 --- a/awsapi/src/com/cloud/bridge/model/MHost.java +++ b/awsapi/src/com/cloud/bridge/model/MHost.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.model; import java.io.Serializable; diff --git a/awsapi/src/com/cloud/bridge/model/MHostMount.java b/awsapi/src/com/cloud/bridge/model/MHostMount.java index f70b1dc6f02..d532568087f 100644 --- a/awsapi/src/com/cloud/bridge/model/MHostMount.java +++ b/awsapi/src/com/cloud/bridge/model/MHostMount.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.model; import java.io.Serializable; diff --git a/awsapi/src/com/cloud/bridge/model/SAcl.java b/awsapi/src/com/cloud/bridge/model/SAcl.java index 5008e730231..bff7906acc5 100644 --- a/awsapi/src/com/cloud/bridge/model/SAcl.java +++ b/awsapi/src/com/cloud/bridge/model/SAcl.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.model; import java.io.Serializable; diff --git a/awsapi/src/com/cloud/bridge/model/SBucket.java b/awsapi/src/com/cloud/bridge/model/SBucket.java index 894f750a985..5f63a77fe9a 100644 --- a/awsapi/src/com/cloud/bridge/model/SBucket.java +++ b/awsapi/src/com/cloud/bridge/model/SBucket.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.model; import java.io.Serializable; diff --git a/awsapi/src/com/cloud/bridge/model/SHost.java b/awsapi/src/com/cloud/bridge/model/SHost.java index 5c8734a2aaf..874b09566d6 100644 --- a/awsapi/src/com/cloud/bridge/model/SHost.java +++ b/awsapi/src/com/cloud/bridge/model/SHost.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.model; import java.io.Serializable; diff --git a/awsapi/src/com/cloud/bridge/model/SMeta.java b/awsapi/src/com/cloud/bridge/model/SMeta.java index 248e1f9adc6..8962771c507 100644 --- a/awsapi/src/com/cloud/bridge/model/SMeta.java +++ b/awsapi/src/com/cloud/bridge/model/SMeta.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.model; import java.io.Serializable; diff --git a/awsapi/src/com/cloud/bridge/model/SObject.java b/awsapi/src/com/cloud/bridge/model/SObject.java index 94743c660ce..73a2c9a4c64 100644 --- a/awsapi/src/com/cloud/bridge/model/SObject.java +++ b/awsapi/src/com/cloud/bridge/model/SObject.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.model; import java.io.Serializable; diff --git a/awsapi/src/com/cloud/bridge/model/SObjectItem.java b/awsapi/src/com/cloud/bridge/model/SObjectItem.java index 1f5b523d76f..14290897cba 100644 --- a/awsapi/src/com/cloud/bridge/model/SObjectItem.java +++ b/awsapi/src/com/cloud/bridge/model/SObjectItem.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.model; import java.io.Serializable; diff --git a/awsapi/src/com/cloud/bridge/model/UserCredentials.java b/awsapi/src/com/cloud/bridge/model/UserCredentials.java index 5d0c6871ee5..b674f40c191 100644 --- a/awsapi/src/com/cloud/bridge/model/UserCredentials.java +++ b/awsapi/src/com/cloud/bridge/model/UserCredentials.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.model; import java.io.Serializable; diff --git a/awsapi/src/com/cloud/bridge/persist/EntityDao.java b/awsapi/src/com/cloud/bridge/persist/EntityDao.java index c040138a50d..c7943a6c135 100644 --- a/awsapi/src/com/cloud/bridge/persist/EntityDao.java +++ b/awsapi/src/com/cloud/bridge/persist/EntityDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist; import java.io.Serializable; diff --git a/awsapi/src/com/cloud/bridge/persist/GMTDateTimeUserType.java b/awsapi/src/com/cloud/bridge/persist/GMTDateTimeUserType.java index d8e0946bf53..b39f29821a8 100644 --- a/awsapi/src/com/cloud/bridge/persist/GMTDateTimeUserType.java +++ b/awsapi/src/com/cloud/bridge/persist/GMTDateTimeUserType.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist; import java.io.Serializable; diff --git a/awsapi/src/com/cloud/bridge/persist/PersistContext.java b/awsapi/src/com/cloud/bridge/persist/PersistContext.java index 8efccac127d..8abc5dab6d1 100644 --- a/awsapi/src/com/cloud/bridge/persist/PersistContext.java +++ b/awsapi/src/com/cloud/bridge/persist/PersistContext.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist; import java.sql.Connection; diff --git a/awsapi/src/com/cloud/bridge/persist/PersistException.java b/awsapi/src/com/cloud/bridge/persist/PersistException.java index b7c5bfb758f..e2acfd2cc12 100644 --- a/awsapi/src/com/cloud/bridge/persist/PersistException.java +++ b/awsapi/src/com/cloud/bridge/persist/PersistException.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist; /** diff --git a/awsapi/src/com/cloud/bridge/persist/dao/BaseDao.java b/awsapi/src/com/cloud/bridge/persist/dao/BaseDao.java index c3988e54255..83679fa002d 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/BaseDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/BaseDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import java.io.File; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/BucketPolicyDao.java b/awsapi/src/com/cloud/bridge/persist/dao/BucketPolicyDao.java index 7705044bde6..dda0e2d7128 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/BucketPolicyDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/BucketPolicyDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import java.io.File; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/CloudStackAccountDao.java b/awsapi/src/com/cloud/bridge/persist/dao/CloudStackAccountDao.java index 40d6f436802..31a5be873e7 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/CloudStackAccountDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/CloudStackAccountDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import org.apache.log4j.Logger; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/CloudStackConfigurationDao.java b/awsapi/src/com/cloud/bridge/persist/dao/CloudStackConfigurationDao.java index 0e3c4673fcd..ed16974dbf1 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/CloudStackConfigurationDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/CloudStackConfigurationDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import org.apache.log4j.Logger; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/CloudStackSvcOfferingDao.java b/awsapi/src/com/cloud/bridge/persist/dao/CloudStackSvcOfferingDao.java index fed8a6d8005..5013eac88d7 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/CloudStackSvcOfferingDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/CloudStackSvcOfferingDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import org.apache.log4j.Logger; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/MHostDao.java b/awsapi/src/com/cloud/bridge/persist/dao/MHostDao.java index 42559f647f3..1c5e81c1a31 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/MHostDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/MHostDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import com.cloud.bridge.model.MHost; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/MHostMountDao.java b/awsapi/src/com/cloud/bridge/persist/dao/MHostMountDao.java index d1cc84303ab..6753e9c95c5 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/MHostMountDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/MHostMountDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import com.cloud.bridge.model.MHostMount; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/MultipartLoadDao.java b/awsapi/src/com/cloud/bridge/persist/dao/MultipartLoadDao.java index ba212bca02e..0ab83ebcf69 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/MultipartLoadDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/MultipartLoadDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import java.io.File; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/OfferingDao.java b/awsapi/src/com/cloud/bridge/persist/dao/OfferingDao.java index eff3ffc40f2..358ce3d797f 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/OfferingDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/OfferingDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import java.io.File; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/SAclDao.java b/awsapi/src/com/cloud/bridge/persist/dao/SAclDao.java index 934384729f6..37f18f36ade 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/SAclDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/SAclDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import java.util.Date; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/SBucketDao.java b/awsapi/src/com/cloud/bridge/persist/dao/SBucketDao.java index 94b2b719780..25845970c0f 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/SBucketDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/SBucketDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import java.util.List; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/SHostDao.java b/awsapi/src/com/cloud/bridge/persist/dao/SHostDao.java index 45fe5952529..2641fdb3435 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/SHostDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/SHostDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import com.cloud.bridge.model.SHost; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/SMetaDao.java b/awsapi/src/com/cloud/bridge/persist/dao/SMetaDao.java index 889ab8dd70b..1bc7933936e 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/SMetaDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/SMetaDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import java.util.List; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/SObjectDao.java b/awsapi/src/com/cloud/bridge/persist/dao/SObjectDao.java index cc972251d61..ac00e03b835 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/SObjectDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/SObjectDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/SObjectItemDao.java b/awsapi/src/com/cloud/bridge/persist/dao/SObjectItemDao.java index 7ccb684ecbe..62b424eb678 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/SObjectItemDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/SObjectItemDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import com.cloud.bridge.model.SObjectItem; diff --git a/awsapi/src/com/cloud/bridge/persist/dao/UserCredentialsDao.java b/awsapi/src/com/cloud/bridge/persist/dao/UserCredentialsDao.java index 1ec322e7615..4beb7a3604f 100644 --- a/awsapi/src/com/cloud/bridge/persist/dao/UserCredentialsDao.java +++ b/awsapi/src/com/cloud/bridge/persist/dao/UserCredentialsDao.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.persist.dao; import java.sql.*; diff --git a/awsapi/src/com/cloud/bridge/service/EC2RestServlet.java b/awsapi/src/com/cloud/bridge/service/EC2RestServlet.java index e372e5cd0bc..ceaf59d4abd 100644 --- a/awsapi/src/com/cloud/bridge/service/EC2RestServlet.java +++ b/awsapi/src/com/cloud/bridge/service/EC2RestServlet.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service; import java.io.ByteArrayInputStream; @@ -1861,4 +1846,4 @@ public class EC2RestServlet extends HttpServlet { xmlWriter.close(); os.close(); } -} \ No newline at end of file +} diff --git a/awsapi/src/com/cloud/bridge/service/EC2SoapService.java b/awsapi/src/com/cloud/bridge/service/EC2SoapService.java index 0a5ed9e443d..1f7f612b4f1 100644 --- a/awsapi/src/com/cloud/bridge/service/EC2SoapService.java +++ b/awsapi/src/com/cloud/bridge/service/EC2SoapService.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service; import org.apache.log4j.Logger; @@ -583,4 +568,4 @@ public class EC2SoapService implements AmazonEC2SkeletonInterface { AmazonEC2SkeletonInterface ec2Service = ServiceProvider.getInstance().getServiceImpl(AmazonEC2SkeletonInterface.class); return ec2Service.importVolume(importVolume); } -} \ No newline at end of file +} diff --git a/awsapi/src/com/cloud/bridge/service/EC2SoapServiceImpl.java b/awsapi/src/com/cloud/bridge/service/EC2SoapServiceImpl.java index 01c78a89373..9e10e0929a3 100644 --- a/awsapi/src/com/cloud/bridge/service/EC2SoapServiceImpl.java +++ b/awsapi/src/com/cloud/bridge/service/EC2SoapServiceImpl.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service; import java.util.ArrayList; @@ -2299,4 +2284,4 @@ public class EC2SoapServiceImpl implements AmazonEC2SkeletonInterface { public ResetSnapshotAttributeResponse resetSnapshotAttribute(ResetSnapshotAttribute resetSnapshotAttribute) { throw new EC2ServiceException(ClientError.Unsupported, "This operation is not available"); } -} \ No newline at end of file +} diff --git a/awsapi/src/com/cloud/bridge/service/S3Constants.java b/awsapi/src/com/cloud/bridge/service/S3Constants.java index c42c652cbea..a86f3f913e1 100644 --- a/awsapi/src/com/cloud/bridge/service/S3Constants.java +++ b/awsapi/src/com/cloud/bridge/service/S3Constants.java @@ -14,27 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service; -/** - * @author Kelven Yang - * Constants used in S3 implementation, one place to hold commonly used constants - */ public interface S3Constants { public final String BUCKET_ATTR_KEY = "s3-bucket"; public final String OBJECT_ATTR_KEY = "s3-object-key"; diff --git a/awsapi/src/com/cloud/bridge/service/S3RestServlet.java b/awsapi/src/com/cloud/bridge/service/S3RestServlet.java index 370b2bea31e..282385b063e 100644 --- a/awsapi/src/com/cloud/bridge/service/S3RestServlet.java +++ b/awsapi/src/com/cloud/bridge/service/S3RestServlet.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service; import java.io.ByteArrayInputStream; @@ -82,9 +67,6 @@ import com.cloud.bridge.util.HeaderParam; import com.cloud.bridge.util.RestAuth; import com.cloud.bridge.util.S3SoapAuth; -/** - * @author Kelven Yang, Mark Joseph, John Zucker - */ public class S3RestServlet extends HttpServlet { private static final long serialVersionUID = -6168996266762804877L; public static final String ENABLE_S3_API="enable.s3.api"; @@ -886,4 +868,4 @@ private S3ObjectAction routePlainPostRequest (HttpServletRequest request) logger.info( "- End of request -" ); } } -} \ No newline at end of file +} diff --git a/awsapi/src/com/cloud/bridge/service/UserContext.java b/awsapi/src/com/cloud/bridge/service/UserContext.java index 7d587e9e76f..74e4259bfce 100644 --- a/awsapi/src/com/cloud/bridge/service/UserContext.java +++ b/awsapi/src/com/cloud/bridge/service/UserContext.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service; import javax.servlet.http.HttpServletRequest; @@ -38,9 +23,6 @@ import org.apache.log4j.Logger; import com.cloud.bridge.service.exception.InternalErrorException; import com.cloud.bridge.util.StringHelper; -/** - * @author Kelven Yang - */ public class UserContext { protected final static Logger logger = Logger.getLogger(UserContext.class); diff --git a/awsapi/src/com/cloud/bridge/service/UserInfo.java b/awsapi/src/com/cloud/bridge/service/UserInfo.java index 8761e5387f3..bab10cdbd51 100644 --- a/awsapi/src/com/cloud/bridge/service/UserInfo.java +++ b/awsapi/src/com/cloud/bridge/service/UserInfo.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service; -/** - * @author Kelven Yang - */ public class UserInfo { private String accessKey; private String secretKey; diff --git a/awsapi/src/com/cloud/bridge/service/controller/s3/S3BucketAction.java b/awsapi/src/com/cloud/bridge/service/controller/s3/S3BucketAction.java index 00120b4cf72..39b5cf675db 100644 --- a/awsapi/src/com/cloud/bridge/service/controller/s3/S3BucketAction.java +++ b/awsapi/src/com/cloud/bridge/service/controller/s3/S3BucketAction.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.controller.s3; import java.io.BufferedReader; diff --git a/awsapi/src/com/cloud/bridge/service/controller/s3/S3ObjectAction.java b/awsapi/src/com/cloud/bridge/service/controller/s3/S3ObjectAction.java index 727752d4767..0aba4ba8deb 100644 --- a/awsapi/src/com/cloud/bridge/service/controller/s3/S3ObjectAction.java +++ b/awsapi/src/com/cloud/bridge/service/controller/s3/S3ObjectAction.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.controller.s3; import java.io.BufferedReader; @@ -1274,4 +1259,4 @@ public class S3ObjectAction implements ServletAction { return new OrderedPair(500, e.toString()); } } -} \ No newline at end of file +} diff --git a/awsapi/src/com/cloud/bridge/service/controller/s3/S3SerializableServiceImplementation.java b/awsapi/src/com/cloud/bridge/service/controller/s3/S3SerializableServiceImplementation.java index b930f68efcd..1bb5834624f 100644 --- a/awsapi/src/com/cloud/bridge/service/controller/s3/S3SerializableServiceImplementation.java +++ b/awsapi/src/com/cloud/bridge/service/controller/s3/S3SerializableServiceImplementation.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.controller.s3; import java.util.Calendar; diff --git a/awsapi/src/com/cloud/bridge/service/controller/s3/ServiceProvider.java b/awsapi/src/com/cloud/bridge/service/controller/s3/ServiceProvider.java index b44a88e0384..7a36a4b9bf8 100644 --- a/awsapi/src/com/cloud/bridge/service/controller/s3/ServiceProvider.java +++ b/awsapi/src/com/cloud/bridge/service/controller/s3/ServiceProvider.java @@ -14,23 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/** - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved - * - * This software is licensed under the GNU General Public License v3 or later. - * - * It is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or any later version. - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - * - */ package com.cloud.bridge.service.controller.s3; diff --git a/awsapi/src/com/cloud/bridge/service/controller/s3/ServletAction.java b/awsapi/src/com/cloud/bridge/service/controller/s3/ServletAction.java index 50cfbc330f6..1f73d365215 100644 --- a/awsapi/src/com/cloud/bridge/service/controller/s3/ServletAction.java +++ b/awsapi/src/com/cloud/bridge/service/controller/s3/ServletAction.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.controller.s3; import java.io.IOException; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/DiskOffer.java b/awsapi/src/com/cloud/bridge/service/core/ec2/DiskOffer.java index 96102c96839..e384f1f8019 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/DiskOffer.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/DiskOffer.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.Calendar; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/DiskOfferings.java b/awsapi/src/com/cloud/bridge/service/core/ec2/DiskOfferings.java index 47e313c4aac..9e2d7adddd9 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/DiskOfferings.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/DiskOfferings.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Address.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Address.java index 313d6244354..38e5ddccf2a 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Address.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Address.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2AddressFilterSet.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2AddressFilterSet.java index 6a930bd3591..e6000efa8be 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2AddressFilterSet.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2AddressFilterSet.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2AssociateAddress.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2AssociateAddress.java index c176d4a3d55..3b79e9061bf 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2AssociateAddress.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2AssociateAddress.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2AvailabilityZonesFilterSet.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2AvailabilityZonesFilterSet.java index b4d4bd36b66..994b721203a 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2AvailabilityZonesFilterSet.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2AvailabilityZonesFilterSet.java @@ -14,24 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * 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. - */ package com.cloud.bridge.service.core.ec2; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateImage.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateImage.java index f98fe7ab20e..b68928d0d0f 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateImage.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateImage.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; public class EC2CreateImage { diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateImageResponse.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateImageResponse.java index 868786bb8f0..355312d2d14 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateImageResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateImageResponse.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; public class EC2CreateImageResponse { diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateKeyPair.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateKeyPair.java index 07068926177..e21941f8dec 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateKeyPair.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateKeyPair.java @@ -14,28 +14,9 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; -/** - * @author slriv - * - */ public class EC2CreateKeyPair { private String keyName; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateVolume.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateVolume.java index cba0b01d11a..db9d956e7b4 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateVolume.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2CreateVolume.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import org.apache.log4j.Logger; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DeleteKeyPair.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DeleteKeyPair.java index 02ee7d368ee..35eed1e51e9 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DeleteKeyPair.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DeleteKeyPair.java @@ -14,28 +14,9 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; -/** - * @author slriv - * - */ public class EC2DeleteKeyPair { private String keyName; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAddresses.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAddresses.java index 4cf2b87b8ce..f97ea2aa4c7 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAddresses.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAddresses.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.HashSet; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAddressesResponse.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAddressesResponse.java index 361df225932..60263822c89 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAddressesResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAddressesResponse.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAvailabilityZones.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAvailabilityZones.java index 447872b6b7f..d447518c7e3 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAvailabilityZones.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAvailabilityZones.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAvailabilityZonesResponse.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAvailabilityZonesResponse.java index 5ca3d8c229e..ae0c233f83f 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAvailabilityZonesResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeAvailabilityZonesResponse.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeImageAttribute.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeImageAttribute.java index 39db585e3ec..1158b7aa359 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeImageAttribute.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeImageAttribute.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeImages.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeImages.java index 563af92ad59..9c51b68df7f 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeImages.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeImages.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeImagesResponse.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeImagesResponse.java index 33bfab4d645..25e4ad0deed 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeImagesResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeImagesResponse.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeInstances.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeInstances.java index b88a65b1dff..e79cd9da870 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeInstances.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeInstances.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeInstancesResponse.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeInstancesResponse.java index f381072f698..c7533bfb7d1 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeInstancesResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeInstancesResponse.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeKeyPairs.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeKeyPairs.java index d18234127f1..d75d38e5f11 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeKeyPairs.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeKeyPairs.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeKeyPairsResponse.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeKeyPairsResponse.java index 7a2dbabb65c..cfa0262b41f 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeKeyPairsResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeKeyPairsResponse.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeSnapshots.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeSnapshots.java index 71f0bac716e..1bf6e3783e1 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeSnapshots.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeSnapshots.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeSnapshotsResponse.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeSnapshotsResponse.java index 09512a3835b..beb213fe2f3 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeSnapshotsResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeSnapshotsResponse.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeVolumes.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeVolumes.java index 0a810156bd3..04145fa36c7 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeVolumes.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeVolumes.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeVolumesResponse.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeVolumesResponse.java index 60b450370f4..28d8f93f7fc 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeVolumesResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DescribeVolumesResponse.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DisassociateAddress.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DisassociateAddress.java index 23f833b7705..09048735d79 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DisassociateAddress.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2DisassociateAddress.java @@ -14,27 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; -/** - * @author slriv - * - */ public class EC2DisassociateAddress { private String publicIp; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Engine.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Engine.java index b15cb7b3915..0d2e713d83f 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Engine.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Engine.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.io.File; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Filter.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Filter.java index d729be4ed7a..bdd814e0773 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Filter.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Filter.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2GroupFilterSet.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2GroupFilterSet.java index 69c8e0fa17e..149d25f6151 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2GroupFilterSet.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2GroupFilterSet.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.text.ParseException; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Image.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Image.java index b011a5170d2..75e792b1a1b 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Image.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Image.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; /** diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ImageAttributes.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ImageAttributes.java index c0897900547..d8b2f45038f 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ImageAttributes.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ImageAttributes.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.List; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ImportKeyPair.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ImportKeyPair.java index 1e9b1b653a2..376a63ee59e 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ImportKeyPair.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ImportKeyPair.java @@ -14,28 +14,9 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; -/** - * @author slriv - * - */ public class EC2ImportKeyPair { private String keyName; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Instance.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Instance.java index 65306258aca..064d7e077a6 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Instance.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Instance.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2InstanceFilterSet.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2InstanceFilterSet.java index 3db621a3387..6d5255ab2d8 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2InstanceFilterSet.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2InstanceFilterSet.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.text.ParseException; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2IpPermission.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2IpPermission.java index 5e14c3b9bd4..4149e1714ec 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2IpPermission.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2IpPermission.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2KeyPairFilterSet.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2KeyPairFilterSet.java index 3faefaf6735..16237038bda 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2KeyPairFilterSet.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2KeyPairFilterSet.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ModifyImageAttribute.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ModifyImageAttribute.java index 76d6235b64f..16f5ef750c7 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ModifyImageAttribute.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ModifyImageAttribute.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RebootInstances.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RebootInstances.java index 67e0513b72e..a331bfa4dd2 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RebootInstances.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RebootInstances.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RegisterImage.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RegisterImage.java index dd46717fe6f..3fd36ba358b 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RegisterImage.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RegisterImage.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; public class EC2RegisterImage { diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ReleaseAddress.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ReleaseAddress.java index 754aecac6dd..61826347f0b 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ReleaseAddress.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2ReleaseAddress.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RunInstances.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RunInstances.java index 36e39ee1e00..e3735b5a12e 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RunInstances.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RunInstances.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RunInstancesResponse.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RunInstancesResponse.java index 23839c24dee..f6873169e44 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RunInstancesResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2RunInstancesResponse.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Snapshot.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Snapshot.java index 8812160a9df..339506deda0 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Snapshot.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Snapshot.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.Calendar; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2SnapshotFilterSet.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2SnapshotFilterSet.java index 3803bece29e..1c428f029cc 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2SnapshotFilterSet.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2SnapshotFilterSet.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.text.ParseException; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StartInstances.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StartInstances.java index 6cecfff2988..3e4a5a85c5c 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StartInstances.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StartInstances.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StartInstancesResponse.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StartInstancesResponse.java index ce255db792d..e424027f6f7 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StartInstancesResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StartInstancesResponse.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StopInstances.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StopInstances.java index 52630e7e4e0..13e23d1a51f 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StopInstances.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StopInstances.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StopInstancesResponse.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StopInstancesResponse.java index bdee3824782..cf3ad518ebc 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StopInstancesResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2StopInstancesResponse.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Volume.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Volume.java index 599a7e3dca8..009c17aa687 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Volume.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2Volume.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2VolumeFilterSet.java b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2VolumeFilterSet.java index 28f939ffa2e..95d306f7c00 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/EC2VolumeFilterSet.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/EC2VolumeFilterSet.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.text.ParseException; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/IpForwardingRuleResponse.java b/awsapi/src/com/cloud/bridge/service/core/ec2/IpForwardingRuleResponse.java index f7f3bf3e278..d04c3492e72 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/IpForwardingRuleResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/IpForwardingRuleResponse.java @@ -14,23 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/** - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved - * - * This software is licensed under the GNU General Public License v3 or later. - * - * It is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or any later version. - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - * - */ package com.cloud.bridge.service.core.ec2; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/OfferingBundle.java b/awsapi/src/com/cloud/bridge/service/core/ec2/OfferingBundle.java index aa765841afe..05b2c03c24b 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/OfferingBundle.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/OfferingBundle.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; public class OfferingBundle { diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/ServiceOffer.java b/awsapi/src/com/cloud/bridge/service/core/ec2/ServiceOffer.java index 12ed19e2f75..c7027f4a2ee 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/ServiceOffer.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/ServiceOffer.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.Calendar; diff --git a/awsapi/src/com/cloud/bridge/service/core/ec2/ServiceOfferings.java b/awsapi/src/com/cloud/bridge/service/core/ec2/ServiceOfferings.java index 370c7c52e69..a5bb0fc2e33 100644 --- a/awsapi/src/com/cloud/bridge/service/core/ec2/ServiceOfferings.java +++ b/awsapi/src/com/cloud/bridge/service/core/ec2/ServiceOfferings.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.ec2; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3AccessControlList.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3AccessControlList.java index 4918c673a6b..a66d6a4895d 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3AccessControlList.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3AccessControlList.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3AccessControlPolicy.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3AccessControlPolicy.java index 94d996e143b..8dcb3116cc8 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3AccessControlPolicy.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3AccessControlPolicy.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; /** diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3BucketAdapter.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3BucketAdapter.java index 20634b08938..f4bd06e96a7 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3BucketAdapter.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3BucketAdapter.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.io.InputStream; @@ -38,9 +23,6 @@ import javax.activation.DataHandler; import com.cloud.bridge.util.OrderedPair; -/** - * @author Kelven Yang - */ public interface S3BucketAdapter { void createContainer(String mountedRoot, String bucket); void deleteContainer(String mountedRoot, String bucket); diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3BucketPolicy.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3BucketPolicy.java index eb2a5060dba..e0b51666ce0 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3BucketPolicy.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3BucketPolicy.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3CanonicalUser.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3CanonicalUser.java index a59c8bb0317..f2b502a8783 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3CanonicalUser.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3CanonicalUser.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import com.cloud.bridge.util.XElement; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3ConditionFactory.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3ConditionFactory.java index d9d2cf30e1e..1bbba5c249a 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3ConditionFactory.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3ConditionFactory.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.HashMap; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3CopyObjectRequest.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3CopyObjectRequest.java index 1746db79a8f..590aca8c7e3 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3CopyObjectRequest.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3CopyObjectRequest.java @@ -14,15 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/** - * - */ package com.cloud.bridge.service.core.s3; -/** - * @author Mark - * - */ public class S3CopyObjectRequest extends S3Request { public enum MetadataDirective { COPY, REPLACE }; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3CreateBucketConfiguration.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3CreateBucketConfiguration.java index 5b47b3a4727..7b48f8ae4e0 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3CreateBucketConfiguration.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3CreateBucketConfiguration.java @@ -14,29 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import com.cloud.bridge.util.XElement; import com.cloud.bridge.util.XSerializer; -/** - * @author Kelven Yang - */ public class S3CreateBucketConfiguration { @XElement(name="LocationConstraint") private String location; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3CreateBucketRequest.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3CreateBucketRequest.java index fba27946ebb..01ee973c4be 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3CreateBucketRequest.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3CreateBucketRequest.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; -/** - * @author Kelven Yang - */ public class S3CreateBucketRequest extends S3Request { protected String bucketName; protected S3CreateBucketConfiguration config; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3CreateBucketResponse.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3CreateBucketResponse.java index 232a80f3ebe..4003709e8cf 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3CreateBucketResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3CreateBucketResponse.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; -/** - * @author Kelven Yang - */ public class S3CreateBucketResponse extends S3Response { protected String bucketName; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3DeleteBucketRequest.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3DeleteBucketRequest.java index 67d4f2d3946..a5ae0a26400 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3DeleteBucketRequest.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3DeleteBucketRequest.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; -/** - * @author Kelven Yang - */ public class S3DeleteBucketRequest extends S3Request { protected String bucketName; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3DeleteObjectRequest.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3DeleteObjectRequest.java index b4e69560224..e4aaf586062 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3DeleteObjectRequest.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3DeleteObjectRequest.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; -/** - * @author Kelven Yang - */ public class S3DeleteObjectRequest extends S3Request { protected String bucketName; protected String key; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3Engine.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3Engine.java index 73a1aac054c..e8b73a42439 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3Engine.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3Engine.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.io.IOException; @@ -98,7 +83,6 @@ import com.cloud.bridge.util.OrderedPair; import com.cloud.bridge.util.Triple; /** - * @author Kelven Yang, John Zucker * The CRUD control actions to be invoked from S3BucketAction or S3ObjectAction. */ public class S3Engine { diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3GetBucketAccessControlPolicyRequest.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3GetBucketAccessControlPolicyRequest.java index cf5a55b7191..cca25c2d7a3 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3GetBucketAccessControlPolicyRequest.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3GetBucketAccessControlPolicyRequest.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; -/** - * @author Kelven Yang - */ public class S3GetBucketAccessControlPolicyRequest extends S3Request { protected String bucketName; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3GetObjectAccessControlPolicyRequest.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3GetObjectAccessControlPolicyRequest.java index c3df8739ea9..6ecd8193054 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3GetObjectAccessControlPolicyRequest.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3GetObjectAccessControlPolicyRequest.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; -/** - * @author Kelven Yang - */ public class S3GetObjectAccessControlPolicyRequest extends S3Request { protected String bucketName; protected String key; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3GetObjectRequest.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3GetObjectRequest.java index a889078a8bb..b6c0c6dd349 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3GetObjectRequest.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3GetObjectRequest.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; -/** - * @author Kelven Yang - */ public class S3GetObjectRequest extends S3Request { private String bucketName; private String key; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3GetObjectResponse.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3GetObjectResponse.java index 25f6d99860e..2f1911553bd 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3GetObjectResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3GetObjectResponse.java @@ -14,30 +14,12 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.Calendar; import javax.activation.DataHandler; -/** - * @author Kelven Yang - */ public class S3GetObjectResponse extends S3Response { protected String ETag; protected Calendar lastModified; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3Grant.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3Grant.java index 265586f0ef6..b3c07beb16a 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3Grant.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3Grant.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.List; @@ -38,7 +23,6 @@ import com.cloud.bridge.model.SBucket; import com.cloud.bridge.service.exception.UnsupportedException; /** - * @author Kelven Yang, John Zucker * Each relation holds * a grantee - which is one of SAcl.GRANTEE_USER, SAcl.GRANTEE_ALLUSERS, SAcl.GRANTEE_AUTHENTICATED * a permission - which is one of SAcl.PERMISSION_PASS, SAcl.PERMISSION_NONE, SAcl.PERMISSION_READ, diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3HostCallingFormat.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3HostCallingFormat.java index d8c31613b0e..03c07a11559 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3HostCallingFormat.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3HostCallingFormat.java @@ -21,7 +21,7 @@ import java.net.URL; import java.util.Iterator; import java.util.Map; -/* @auth John Zucker +/* * Provide a suitable subclass of format class to reflect the choice of bucket referencing format supported by * AWS S3 in constructing the URL for requesting RESTful services. The three possibilities are * (*) hostname followed by bucket as path information (sometimes termed the path style) @@ -154,4 +154,4 @@ public abstract class S3HostCallingFormat return bucket.length() != 0; } } -} \ No newline at end of file +} diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3ListAllMyBucketsEntry.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3ListAllMyBucketsEntry.java index 01743e5123e..d561fb0f939 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3ListAllMyBucketsEntry.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3ListAllMyBucketsEntry.java @@ -14,29 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.Calendar; import java.util.TimeZone; -/** - * @author Kelven Yang - */ public class S3ListAllMyBucketsEntry { private String name; private Calendar creationDate; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3ListAllMyBucketsRequest.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3ListAllMyBucketsRequest.java index 4c6d661b281..9eac964eab7 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3ListAllMyBucketsRequest.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3ListAllMyBucketsRequest.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; -/** - * @author Kelven Yang - */ public class S3ListAllMyBucketsRequest extends S3Request { public S3ListAllMyBucketsRequest() { super(); diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3ListAllMyBucketsResponse.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3ListAllMyBucketsResponse.java index 30a2f1f2138..35d81e0d558 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3ListAllMyBucketsResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3ListAllMyBucketsResponse.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; -/** - * @author Kelven Yang - */ public class S3ListAllMyBucketsResponse extends S3Response { private S3CanonicalUser owner; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketObjectEntry.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketObjectEntry.java index cf14662194a..3486965a21b 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketObjectEntry.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketObjectEntry.java @@ -14,30 +14,12 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.Calendar; import com.cloud.bridge.util.XElement; -/** - * @author Kelven Yang - */ public class S3ListBucketObjectEntry { @XElement(name="Key") diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketPrefixEntry.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketPrefixEntry.java index 97189c9939d..f08e2c18bc5 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketPrefixEntry.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketPrefixEntry.java @@ -14,28 +14,10 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import com.cloud.bridge.util.XElement; -/** - * @author Kelven Yang - */ public class S3ListBucketPrefixEntry { @XElement(name="Prefix") diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketRequest.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketRequest.java index d91d559c85e..d395f919a0b 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketRequest.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketRequest.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; -/** - * @author Kelven Yang - */ public class S3ListBucketRequest extends S3Request { protected String bucketName; protected String prefix; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketResponse.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketResponse.java index 3f312ec404f..bfae0a50dfd 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3ListBucketResponse.java @@ -14,28 +14,10 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import com.cloud.bridge.util.XElement; -/** - * @author Kelven Yang - */ public class S3ListBucketResponse extends S3Response { @XElement(name="Name") diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3MetaDataEntry.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3MetaDataEntry.java index da11747652f..c4505f62228 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3MetaDataEntry.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3MetaDataEntry.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; -/** - * @author Kelven - */ public class S3MetaDataEntry { private String name; private String value; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3MultipartPart.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3MultipartPart.java index 73ab2a769ee..a4350622d3e 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3MultipartPart.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3MultipartPart.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.Calendar; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3MultipartUpload.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3MultipartUpload.java index bc566cd761e..ea47ce58929 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3MultipartUpload.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3MultipartUpload.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.Calendar; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyAction.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyAction.java index 4a4d5d7c88b..cc3283ffbcb 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyAction.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyAction.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyArnCondition.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyArnCondition.java index 5e2226c338d..50634374387 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyArnCondition.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyArnCondition.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.text.ParseException; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyBoolCondition.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyBoolCondition.java index cb63b3caea3..9a957884e87 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyBoolCondition.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyBoolCondition.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.text.ParseException; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyCondition.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyCondition.java index 38a6a868508..6ab5dec0945 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyCondition.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyCondition.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.Set; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyConditionBlock.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyConditionBlock.java index 6ab8f794a6b..a884ea6d6e6 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyConditionBlock.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyConditionBlock.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyContext.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyContext.java index c63d0c09a52..b83c7f4d53a 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyContext.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyContext.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.HashMap; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyDateCondition.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyDateCondition.java index a48e12b3655..56a7d7bfe6a 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyDateCondition.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyDateCondition.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.text.ParseException; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyIPAddressCondition.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyIPAddressCondition.java index 1c31715756a..01705324377 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyIPAddressCondition.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyIPAddressCondition.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.io.IOException; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyNumericCondition.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyNumericCondition.java index 33d05d6b9f3..a2089241b05 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyNumericCondition.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyNumericCondition.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.text.ParseException; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyPrincipal.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyPrincipal.java index 52702899127..e277847af31 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyPrincipal.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyPrincipal.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyStatement.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyStatement.java index 5532566c4aa..12ff0ff5673 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyStatement.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyStatement.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import com.cloud.bridge.service.core.s3.S3BucketPolicy.PolicyAccess; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyStringCondition.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyStringCondition.java index 6950c18692c..d046db9e3b3 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyStringCondition.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PolicyStringCondition.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.text.ParseException; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectInlineRequest.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectInlineRequest.java index 46f0ec525d7..c3a0debca50 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectInlineRequest.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectInlineRequest.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.io.ByteArrayInputStream; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectInlineResponse.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectInlineResponse.java index c376d8a6a7d..b75ee05c781 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectInlineResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectInlineResponse.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.Calendar; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectRequest.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectRequest.java index d2e82b8e289..076e61a6830 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectRequest.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectRequest.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.io.InputStream; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectResponse.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectResponse.java index bc6899c8563..28385e396f2 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectResponse.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3PutObjectResponse.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.Calendar; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3Request.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3Request.java index a1ecb5c2346..439b98d3ac9 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3Request.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3Request.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; import java.util.Calendar; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3Response.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3Response.java index fe6b0af689a..c014c067ae9 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3Response.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3Response.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; -/** - * @author Kelven Yang - */ public class S3Response { protected int resultCode; protected String version; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3SetBucketAccessControlPolicyRequest.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3SetBucketAccessControlPolicyRequest.java index 0dbe47f5c68..b2091c4f1a3 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3SetBucketAccessControlPolicyRequest.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3SetBucketAccessControlPolicyRequest.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; -/** - * @author Kelven Yang - */ public class S3SetBucketAccessControlPolicyRequest extends S3Request { protected String bucketName; protected S3AccessControlList acl; diff --git a/awsapi/src/com/cloud/bridge/service/core/s3/S3SetObjectAccessControlPolicyRequest.java b/awsapi/src/com/cloud/bridge/service/core/s3/S3SetObjectAccessControlPolicyRequest.java index 4fafdaa601b..2683eb7b242 100644 --- a/awsapi/src/com/cloud/bridge/service/core/s3/S3SetObjectAccessControlPolicyRequest.java +++ b/awsapi/src/com/cloud/bridge/service/core/s3/S3SetObjectAccessControlPolicyRequest.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.core.s3; -/** - * @author Kelven Yang - */ public class S3SetObjectAccessControlPolicyRequest extends S3Request { protected String bucketName; protected String key; diff --git a/awsapi/src/com/cloud/bridge/service/exception/ConfigurationException.java b/awsapi/src/com/cloud/bridge/service/exception/ConfigurationException.java index 74dc3445172..982e1cd13fc 100644 --- a/awsapi/src/com/cloud/bridge/service/exception/ConfigurationException.java +++ b/awsapi/src/com/cloud/bridge/service/exception/ConfigurationException.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.exception; -/** - * @author Kelven Yang - */ public class ConfigurationException extends RuntimeException { private static final long serialVersionUID = 6810626920539827556L; diff --git a/awsapi/src/com/cloud/bridge/service/exception/EC2ServiceException.java b/awsapi/src/com/cloud/bridge/service/exception/EC2ServiceException.java index b7578b85931..f40278d25e2 100644 --- a/awsapi/src/com/cloud/bridge/service/exception/EC2ServiceException.java +++ b/awsapi/src/com/cloud/bridge/service/exception/EC2ServiceException.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.exception; import javax.xml.namespace.QName; diff --git a/awsapi/src/com/cloud/bridge/service/exception/FileNotExistException.java b/awsapi/src/com/cloud/bridge/service/exception/FileNotExistException.java index 6bdf79e73a5..c35412f30a3 100644 --- a/awsapi/src/com/cloud/bridge/service/exception/FileNotExistException.java +++ b/awsapi/src/com/cloud/bridge/service/exception/FileNotExistException.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.exception; -/** - * @author Kelven Yang - */ public class FileNotExistException extends RuntimeException { private static final long serialVersionUID = 5512751425783765269L; diff --git a/awsapi/src/com/cloud/bridge/service/exception/HostNotMountedException.java b/awsapi/src/com/cloud/bridge/service/exception/HostNotMountedException.java index af69b43857c..71667be8948 100644 --- a/awsapi/src/com/cloud/bridge/service/exception/HostNotMountedException.java +++ b/awsapi/src/com/cloud/bridge/service/exception/HostNotMountedException.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.exception; -/** - * @author Kelven Yang - */ public class HostNotMountedException extends RuntimeException { private static final long serialVersionUID = 1798153102422117938L; diff --git a/awsapi/src/com/cloud/bridge/service/exception/InternalErrorException.java b/awsapi/src/com/cloud/bridge/service/exception/InternalErrorException.java index f025ce79200..88916c5cdc8 100644 --- a/awsapi/src/com/cloud/bridge/service/exception/InternalErrorException.java +++ b/awsapi/src/com/cloud/bridge/service/exception/InternalErrorException.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.exception; -/** - * @author Kelven Yang - */ public class InternalErrorException extends RuntimeException { private static final long serialVersionUID = 2996134346433756736L; diff --git a/awsapi/src/com/cloud/bridge/service/exception/InvalidRequestContentException.java b/awsapi/src/com/cloud/bridge/service/exception/InvalidRequestContentException.java index f80ceb7cd57..841f19e38da 100644 --- a/awsapi/src/com/cloud/bridge/service/exception/InvalidRequestContentException.java +++ b/awsapi/src/com/cloud/bridge/service/exception/InvalidRequestContentException.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.exception; -/** - * @author Kelven Yang - */ public class InvalidRequestContentException extends RuntimeException { private static final long serialVersionUID = -3047694313765739359L; diff --git a/awsapi/src/com/cloud/bridge/service/exception/NetworkIOException.java b/awsapi/src/com/cloud/bridge/service/exception/NetworkIOException.java index 27d0cf8780b..6d0c9260fd5 100644 --- a/awsapi/src/com/cloud/bridge/service/exception/NetworkIOException.java +++ b/awsapi/src/com/cloud/bridge/service/exception/NetworkIOException.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.exception; -/** - * @author Kelven Yang - */ public class NetworkIOException extends RuntimeException { private static final long serialVersionUID = 1797775871115398024L; diff --git a/awsapi/src/com/cloud/bridge/service/exception/NoSuchObjectException.java b/awsapi/src/com/cloud/bridge/service/exception/NoSuchObjectException.java index 50ba8200d08..be9b58d4e97 100644 --- a/awsapi/src/com/cloud/bridge/service/exception/NoSuchObjectException.java +++ b/awsapi/src/com/cloud/bridge/service/exception/NoSuchObjectException.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.exception; -/** - * @author Kelven Yang - */ public class NoSuchObjectException extends RuntimeException { private static final long serialVersionUID = -5727022800215753259L; diff --git a/awsapi/src/com/cloud/bridge/service/exception/ObjectAlreadyExistsException.java b/awsapi/src/com/cloud/bridge/service/exception/ObjectAlreadyExistsException.java index f469de83510..6358cba0f8e 100644 --- a/awsapi/src/com/cloud/bridge/service/exception/ObjectAlreadyExistsException.java +++ b/awsapi/src/com/cloud/bridge/service/exception/ObjectAlreadyExistsException.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.exception; -/** - * @author Kelven - */ public class ObjectAlreadyExistsException extends RuntimeException { private static final long serialVersionUID = 2705708093384620824L; diff --git a/awsapi/src/com/cloud/bridge/service/exception/OutOfServiceException.java b/awsapi/src/com/cloud/bridge/service/exception/OutOfServiceException.java index 1d103d2971c..c680bb94da7 100644 --- a/awsapi/src/com/cloud/bridge/service/exception/OutOfServiceException.java +++ b/awsapi/src/com/cloud/bridge/service/exception/OutOfServiceException.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.exception; -/** - * @author Kelven - */ public class OutOfServiceException extends RuntimeException { private static final long serialVersionUID = 8457313467757867680L; diff --git a/awsapi/src/com/cloud/bridge/service/exception/OutOfStorageException.java b/awsapi/src/com/cloud/bridge/service/exception/OutOfStorageException.java index d1fe0d8e4b1..2d2f46217e6 100644 --- a/awsapi/src/com/cloud/bridge/service/exception/OutOfStorageException.java +++ b/awsapi/src/com/cloud/bridge/service/exception/OutOfStorageException.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.exception; -/** - * @author Kelven Yang - */ public class OutOfStorageException extends RuntimeException { private static final long serialVersionUID = -2236697888220815218L; diff --git a/awsapi/src/com/cloud/bridge/service/exception/PermissionDeniedException.java b/awsapi/src/com/cloud/bridge/service/exception/PermissionDeniedException.java index 21e42148851..95d20e9bdfb 100644 --- a/awsapi/src/com/cloud/bridge/service/exception/PermissionDeniedException.java +++ b/awsapi/src/com/cloud/bridge/service/exception/PermissionDeniedException.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.service.exception; -/** - * @author Kelven Yang - */ public class PermissionDeniedException extends RuntimeException { private static final long serialVersionUID = -5816172859594116468L; diff --git a/awsapi/src/com/cloud/bridge/tool/CloudS3CmdTool.java b/awsapi/src/com/cloud/bridge/tool/CloudS3CmdTool.java index f7e1b202a3c..ab27c1d3f33 100644 --- a/awsapi/src/com/cloud/bridge/tool/CloudS3CmdTool.java +++ b/awsapi/src/com/cloud/bridge/tool/CloudS3CmdTool.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.tool; import java.io.File; @@ -59,9 +44,6 @@ import com.amazon.s3.client.AmazonS3Stub.PutObjectInline; import com.amazon.s3.client.AmazonS3Stub.PutObjectInlineResponse; import com.amazon.s3.client.AmazonS3Stub.Status; -/** - * @author Kelven Yang - */ public class CloudS3CmdTool { private String serviceUrl; diff --git a/awsapi/src/com/cloud/bridge/util/AuthenticationUtils.java b/awsapi/src/com/cloud/bridge/util/AuthenticationUtils.java index 3e0fee3fb67..fb2fc393691 100644 --- a/awsapi/src/com/cloud/bridge/util/AuthenticationUtils.java +++ b/awsapi/src/com/cloud/bridge/util/AuthenticationUtils.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import org.apache.log4j.Logger; diff --git a/awsapi/src/com/cloud/bridge/util/CalendarDateParam.java b/awsapi/src/com/cloud/bridge/util/CalendarDateParam.java index 5edc8ca8133..a5d92b748f5 100644 --- a/awsapi/src/com/cloud/bridge/util/CalendarDateParam.java +++ b/awsapi/src/com/cloud/bridge/util/CalendarDateParam.java @@ -14,28 +14,10 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.util.Calendar; -/** - * @author Kelven Yang - */ public class CalendarDateParam { private Calendar dateValue; diff --git a/awsapi/src/com/cloud/bridge/util/CloudSessionFactory.java b/awsapi/src/com/cloud/bridge/util/CloudSessionFactory.java index 7b85836b530..404f4636a8b 100644 --- a/awsapi/src/com/cloud/bridge/util/CloudSessionFactory.java +++ b/awsapi/src/com/cloud/bridge/util/CloudSessionFactory.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.io.File; @@ -44,9 +29,6 @@ import org.jasypt.encryption.pbe.StandardPBEStringEncryptor; import org.jasypt.properties.EncryptableProperties; import org.apache.log4j.Logger; -/** - * @author Kelven Yang - */ public class CloudSessionFactory { private static CloudSessionFactory instance; public static final Logger logger = Logger.getLogger(CloudSessionFactory.class); diff --git a/awsapi/src/com/cloud/bridge/util/CloudStackSessionFactory.java b/awsapi/src/com/cloud/bridge/util/CloudStackSessionFactory.java index 457881854c2..a5e97b81fd6 100644 --- a/awsapi/src/com/cloud/bridge/util/CloudStackSessionFactory.java +++ b/awsapi/src/com/cloud/bridge/util/CloudStackSessionFactory.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.io.File; diff --git a/awsapi/src/com/cloud/bridge/util/ConfigurationHelper.java b/awsapi/src/com/cloud/bridge/util/ConfigurationHelper.java index b31437ee902..0d96c30c449 100644 --- a/awsapi/src/com/cloud/bridge/util/ConfigurationHelper.java +++ b/awsapi/src/com/cloud/bridge/util/ConfigurationHelper.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.io.File; @@ -40,9 +25,6 @@ import org.apache.axis2.context.MessageContext; import org.apache.axis2.transport.http.HTTPConstants; -/** - h* @author Kelven Yang - */ public class ConfigurationHelper { private static String configPath; diff --git a/awsapi/src/com/cloud/bridge/util/Converter.java b/awsapi/src/com/cloud/bridge/util/Converter.java index 1687af4ca6a..2640c5f3480 100644 --- a/awsapi/src/com/cloud/bridge/util/Converter.java +++ b/awsapi/src/com/cloud/bridge/util/Converter.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; -/** - * @author Kelven Yang - */ public class Converter { public static boolean toBool(String value, boolean defaultValue) { if(value != null && !value.isEmpty()) { diff --git a/awsapi/src/com/cloud/bridge/util/CryptoHelper.java b/awsapi/src/com/cloud/bridge/util/CryptoHelper.java index bf54a28509a..f759a06cc01 100644 --- a/awsapi/src/com/cloud/bridge/util/CryptoHelper.java +++ b/awsapi/src/com/cloud/bridge/util/CryptoHelper.java @@ -14,25 +14,7 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; -/** - * @author Kelven Yang - */ public class CryptoHelper { } diff --git a/awsapi/src/com/cloud/bridge/util/DatabindingConverterUtil.java b/awsapi/src/com/cloud/bridge/util/DatabindingConverterUtil.java index a6cfd6fa420..1d990965dd3 100644 --- a/awsapi/src/com/cloud/bridge/util/DatabindingConverterUtil.java +++ b/awsapi/src/com/cloud/bridge/util/DatabindingConverterUtil.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; @@ -39,7 +24,6 @@ import java.util.Date; import org.apache.axis2.databinding.utils.ConverterUtil; /** - * @author John Zucker * Custom subclass of org.apache.axis2.databinding.utils.ConverterUtil, i.e. the data conversion utility for * databindings in the ADB framework of Axis2. The purpose of a custom class is to provide specific value * format conversions for certain datatypes, especially dates, timestamps and calendars for which the default diff --git a/awsapi/src/com/cloud/bridge/util/DateHelper.java b/awsapi/src/com/cloud/bridge/util/DateHelper.java index 561ffd6c2e9..2f16ef8159c 100644 --- a/awsapi/src/com/cloud/bridge/util/DateHelper.java +++ b/awsapi/src/com/cloud/bridge/util/DateHelper.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.text.DateFormat; @@ -38,9 +23,6 @@ import java.util.Calendar; import java.util.Date; import java.util.TimeZone; -/** - * @author Kelven Yang - */ public class DateHelper { public static final TimeZone GMT_TIMEZONE = TimeZone.getTimeZone("GMT"); public static final String YYYYMMDD_FORMAT = "yyyyMMddHHmmss"; diff --git a/awsapi/src/com/cloud/bridge/util/EC2RestAuth.java b/awsapi/src/com/cloud/bridge/util/EC2RestAuth.java index e9154124a65..67b60765a26 100644 --- a/awsapi/src/com/cloud/bridge/util/EC2RestAuth.java +++ b/awsapi/src/com/cloud/bridge/util/EC2RestAuth.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.io.UnsupportedEncodingException; diff --git a/awsapi/src/com/cloud/bridge/util/EntityParam.java b/awsapi/src/com/cloud/bridge/util/EntityParam.java index c11f4b98a39..8a4274daee2 100644 --- a/awsapi/src/com/cloud/bridge/util/EntityParam.java +++ b/awsapi/src/com/cloud/bridge/util/EntityParam.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; -/** - * @author Kelven Yang - */ public class EntityParam { private Object entity; diff --git a/awsapi/src/com/cloud/bridge/util/ISO8601SimpleDateTimeFormat.java b/awsapi/src/com/cloud/bridge/util/ISO8601SimpleDateTimeFormat.java index 2c34bce2c94..18764198f61 100644 --- a/awsapi/src/com/cloud/bridge/util/ISO8601SimpleDateTimeFormat.java +++ b/awsapi/src/com/cloud/bridge/util/ISO8601SimpleDateTimeFormat.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; diff --git a/awsapi/src/com/cloud/bridge/util/IpAddressRange.java b/awsapi/src/com/cloud/bridge/util/IpAddressRange.java index ffd17b4a940..e8a6d82a33d 100644 --- a/awsapi/src/com/cloud/bridge/util/IpAddressRange.java +++ b/awsapi/src/com/cloud/bridge/util/IpAddressRange.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.io.IOException; diff --git a/awsapi/src/com/cloud/bridge/util/IteratorHelper.java b/awsapi/src/com/cloud/bridge/util/IteratorHelper.java index 03267cfbfae..42befd37de4 100644 --- a/awsapi/src/com/cloud/bridge/util/IteratorHelper.java +++ b/awsapi/src/com/cloud/bridge/util/IteratorHelper.java @@ -14,29 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.util.Enumeration; import java.util.Iterator; -/** - * @author Kelven Yang - */ public class IteratorHelper { public static Iterable enumerationAsIterable(final Enumeration e) { return new Iterable () { diff --git a/awsapi/src/com/cloud/bridge/util/JsonAccessor.java b/awsapi/src/com/cloud/bridge/util/JsonAccessor.java index 127a4018d4f..c7720f659fa 100644 --- a/awsapi/src/com/cloud/bridge/util/JsonAccessor.java +++ b/awsapi/src/com/cloud/bridge/util/JsonAccessor.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.math.BigDecimal; @@ -50,7 +35,6 @@ import com.google.gson.JsonPrimitive; * rootobj.level1obj[1].property * this[0].level1obj[1].property * - * @author Kelven Yang */ public class JsonAccessor { private JsonElement _json; diff --git a/awsapi/src/com/cloud/bridge/util/NetHelper.java b/awsapi/src/com/cloud/bridge/util/NetHelper.java index 5041277c8f9..caddec2f25d 100644 --- a/awsapi/src/com/cloud/bridge/util/NetHelper.java +++ b/awsapi/src/com/cloud/bridge/util/NetHelper.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.net.InetAddress; @@ -41,9 +26,6 @@ import java.util.List; import org.apache.log4j.Logger; -/** - * @author Kelven Yang - */ public class NetHelper { protected final static Logger logger = Logger.getLogger(NetHelper.class); diff --git a/awsapi/src/com/cloud/bridge/util/OrderedPair.java b/awsapi/src/com/cloud/bridge/util/OrderedPair.java index 0ef08811ff4..3c8d0d55903 100644 --- a/awsapi/src/com/cloud/bridge/util/OrderedPair.java +++ b/awsapi/src/com/cloud/bridge/util/OrderedPair.java @@ -14,25 +14,9 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; /** - * @author Kelven Yang, John Zucker * Reusable class whose instances encode any ordered pair (or 2-tuple) of values of types T1 and T2 * Provide getters: getFirst(), getSecond() * Provide setters: setFirst(val), setSecond(val) diff --git a/awsapi/src/com/cloud/bridge/util/PolicyParser.java b/awsapi/src/com/cloud/bridge/util/PolicyParser.java index ef7013c36f7..4d9a507190a 100644 --- a/awsapi/src/com/cloud/bridge/util/PolicyParser.java +++ b/awsapi/src/com/cloud/bridge/util/PolicyParser.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright 2011 Cloud.com, Inc. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.util.ArrayList; diff --git a/awsapi/src/com/cloud/bridge/util/QueryHelper.java b/awsapi/src/com/cloud/bridge/util/QueryHelper.java index 6f0a6a1a87f..1a1b58290e1 100644 --- a/awsapi/src/com/cloud/bridge/util/QueryHelper.java +++ b/awsapi/src/com/cloud/bridge/util/QueryHelper.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.io.Serializable; @@ -41,9 +26,6 @@ import java.util.Locale; import org.hibernate.Query; -/** - * @author Kelven Yang - */ public class QueryHelper { public static void bindParameters(Query query, Object[] params) { int pos = 0; diff --git a/awsapi/src/com/cloud/bridge/util/RestAuth.java b/awsapi/src/com/cloud/bridge/util/RestAuth.java index 32794a3f2e7..33d2d479a67 100644 --- a/awsapi/src/com/cloud/bridge/util/RestAuth.java +++ b/awsapi/src/com/cloud/bridge/util/RestAuth.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.security.InvalidKeyException; @@ -53,7 +38,6 @@ import org.apache.log4j.Logger; * This class is used for the Authentication check for REST requests and Query String * Authentication requests. * - * @author Kelven Yang, John Zucker, Salvatore Orlando */ public class RestAuth { diff --git a/awsapi/src/com/cloud/bridge/util/S3SoapAuth.java b/awsapi/src/com/cloud/bridge/util/S3SoapAuth.java index 4f49bb30722..69549d0eb14 100644 --- a/awsapi/src/com/cloud/bridge/util/S3SoapAuth.java +++ b/awsapi/src/com/cloud/bridge/util/S3SoapAuth.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import javax.crypto.Mac; diff --git a/awsapi/src/com/cloud/bridge/util/ServletRequestDataSource.java b/awsapi/src/com/cloud/bridge/util/ServletRequestDataSource.java index 04c0323e82d..209feb3b8e7 100644 --- a/awsapi/src/com/cloud/bridge/util/ServletRequestDataSource.java +++ b/awsapi/src/com/cloud/bridge/util/ServletRequestDataSource.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.io.IOException; @@ -40,9 +25,6 @@ import javax.servlet.http.HttpServletRequest; import org.apache.log4j.Logger; -/** - * @author Kelven Yang - */ public class ServletRequestDataSource implements DataSource { protected final static Logger logger = Logger.getLogger(ServletRequestDataSource.class); diff --git a/awsapi/src/com/cloud/bridge/util/StringHelper.java b/awsapi/src/com/cloud/bridge/util/StringHelper.java index eeb38d4fb79..30317197744 100644 --- a/awsapi/src/com/cloud/bridge/util/StringHelper.java +++ b/awsapi/src/com/cloud/bridge/util/StringHelper.java @@ -14,28 +14,12 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.io.IOException; import java.io.InputStream; /** - * @author Kelven, John Zucker * Provide converters for regexp (case independent tokens) * Also provide upper case or lower case (default) converters for byte array b[] to hex String */ diff --git a/awsapi/src/com/cloud/bridge/util/TextParam.java b/awsapi/src/com/cloud/bridge/util/TextParam.java index 7b85a68e5ee..0ac631115ec 100644 --- a/awsapi/src/com/cloud/bridge/util/TextParam.java +++ b/awsapi/src/com/cloud/bridge/util/TextParam.java @@ -14,26 +14,8 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; -/** - * @author Kelven - */ public class TextParam { private String textValue; diff --git a/awsapi/src/com/cloud/bridge/util/TimeParam.java b/awsapi/src/com/cloud/bridge/util/TimeParam.java index af630e51bdd..fb01612bd69 100644 --- a/awsapi/src/com/cloud/bridge/util/TimeParam.java +++ b/awsapi/src/com/cloud/bridge/util/TimeParam.java @@ -14,28 +14,10 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.util.Date; -/** - * @author Kelven Yang - */ public class TimeParam { private Date timeValue; diff --git a/awsapi/src/com/cloud/bridge/util/TimestampParam.java b/awsapi/src/com/cloud/bridge/util/TimestampParam.java index 64d5d44bc7a..e1b2d315589 100644 --- a/awsapi/src/com/cloud/bridge/util/TimestampParam.java +++ b/awsapi/src/com/cloud/bridge/util/TimestampParam.java @@ -14,28 +14,10 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.util.Date; -/** - * @author Kelven Yang - */ public class TimestampParam { private Date timestampValue; diff --git a/awsapi/src/com/cloud/bridge/util/Triple.java b/awsapi/src/com/cloud/bridge/util/Triple.java index dbeaa74a26c..dd5aae7f41d 100644 --- a/awsapi/src/com/cloud/bridge/util/Triple.java +++ b/awsapi/src/com/cloud/bridge/util/Triple.java @@ -14,25 +14,9 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; /** - * @author Kelven Yang, John Zucker * Reusable class whose instances encode any triple (or 3-tuple) of values of types T1, T2 and T3 * Provide getters: getFirst(), getSecond(), getThird() * Provide setters: setFirst(val), setSecond(val), setThird(val) @@ -77,4 +61,4 @@ public class Triple { third = t3; return this; } -} \ No newline at end of file +} diff --git a/awsapi/src/com/cloud/bridge/util/XElement.java b/awsapi/src/com/cloud/bridge/util/XElement.java index 782657bc482..7fc70a39e1f 100644 --- a/awsapi/src/com/cloud/bridge/util/XElement.java +++ b/awsapi/src/com/cloud/bridge/util/XElement.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.lang.annotation.ElementType; @@ -36,9 +21,6 @@ import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; -/** - * @author Kelven Yang - */ @Target({ElementType.TYPE, ElementType.FIELD}) @Retention(RetentionPolicy.RUNTIME) public @interface XElement { diff --git a/awsapi/src/com/cloud/bridge/util/XFlatten.java b/awsapi/src/com/cloud/bridge/util/XFlatten.java index bb338e44a3b..d9c894554d0 100644 --- a/awsapi/src/com/cloud/bridge/util/XFlatten.java +++ b/awsapi/src/com/cloud/bridge/util/XFlatten.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.lang.annotation.ElementType; diff --git a/awsapi/src/com/cloud/bridge/util/XOmitNull.java b/awsapi/src/com/cloud/bridge/util/XOmitNull.java index 3efe781eec8..60b879c99e2 100644 --- a/awsapi/src/com/cloud/bridge/util/XOmitNull.java +++ b/awsapi/src/com/cloud/bridge/util/XOmitNull.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.lang.annotation.ElementType; @@ -36,9 +21,6 @@ import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; -/** - * @author Kelven Yang - */ @Target({ElementType.FIELD}) @Retention(RetentionPolicy.RUNTIME) public @interface XOmitNull { diff --git a/awsapi/src/com/cloud/bridge/util/XSerializable.java b/awsapi/src/com/cloud/bridge/util/XSerializable.java index 303bdd1efbd..2451e9c8fbf 100644 --- a/awsapi/src/com/cloud/bridge/util/XSerializable.java +++ b/awsapi/src/com/cloud/bridge/util/XSerializable.java @@ -14,30 +14,12 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.io.PrintWriter; import org.w3c.dom.Node; -/** - * @author Kelven Yang - */ public interface XSerializable { void serializeTo(XSerializer serializer, int indentLevel, PrintWriter writer); void serializeFrom(XSerializer serializer, Object object, Node node); diff --git a/awsapi/src/com/cloud/bridge/util/XSerializer.java b/awsapi/src/com/cloud/bridge/util/XSerializer.java index 73ca3a5e5b6..12c74013964 100644 --- a/awsapi/src/com/cloud/bridge/util/XSerializer.java +++ b/awsapi/src/com/cloud/bridge/util/XSerializer.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.io.IOException; @@ -54,9 +39,6 @@ import org.w3c.dom.Document; import org.w3c.dom.Node; import org.w3c.dom.NodeList; -/** - * @author Kelven Yang - */ public class XSerializer { protected final static Logger logger = Logger.getLogger(XSerializer.class); diff --git a/awsapi/src/com/cloud/bridge/util/XSerializerAdapter.java b/awsapi/src/com/cloud/bridge/util/XSerializerAdapter.java index 6672eb4aa5f..a695412a01e 100644 --- a/awsapi/src/com/cloud/bridge/util/XSerializerAdapter.java +++ b/awsapi/src/com/cloud/bridge/util/XSerializerAdapter.java @@ -14,29 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.io.PrintWriter; import java.lang.reflect.Field; -/** - * @author Kelven Yang - */ public interface XSerializerAdapter { void setSerializer(XSerializer serializer); diff --git a/awsapi/src/com/cloud/bridge/util/XSerializerJsonAdapter.java b/awsapi/src/com/cloud/bridge/util/XSerializerJsonAdapter.java index ddafb0af17e..9662f507142 100644 --- a/awsapi/src/com/cloud/bridge/util/XSerializerJsonAdapter.java +++ b/awsapi/src/com/cloud/bridge/util/XSerializerJsonAdapter.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.io.PrintWriter; @@ -38,9 +23,6 @@ import java.util.Collection; import java.util.Date; import java.util.Iterator; -/** - * @author Kelven Yang - */ public class XSerializerJsonAdapter implements XSerializerAdapter { private XSerializer serializer; diff --git a/awsapi/src/com/cloud/bridge/util/XSerializerXmlAdapter.java b/awsapi/src/com/cloud/bridge/util/XSerializerXmlAdapter.java index d02ee63fedb..212b70e0422 100644 --- a/awsapi/src/com/cloud/bridge/util/XSerializerXmlAdapter.java +++ b/awsapi/src/com/cloud/bridge/util/XSerializerXmlAdapter.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.io.PrintWriter; @@ -38,9 +23,6 @@ import java.util.Collection; import java.util.Date; import java.util.Iterator; -/** - * @author Kelven - */ public class XSerializerXmlAdapter implements XSerializerAdapter { private XSerializer serializer; diff --git a/awsapi/src/com/cloud/bridge/util/XmlHelper.java b/awsapi/src/com/cloud/bridge/util/XmlHelper.java index 1d02101c700..d8f6b94d9ce 100644 --- a/awsapi/src/com/cloud/bridge/util/XmlHelper.java +++ b/awsapi/src/com/cloud/bridge/util/XmlHelper.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.bridge.util; import java.io.ByteArrayInputStream; @@ -57,9 +42,6 @@ import javax.xml.transform.TransformerFactory; import javax.xml.transform.dom.DOMSource; import javax.xml.transform.stream.StreamResult; -/** - * @author Kelven Yang - */ public class XmlHelper { protected static Logger logger = Logger.getLogger(XmlHelper.class); diff --git a/awsapi/src/com/cloud/stack/CloudStackApi.java b/awsapi/src/com/cloud/stack/CloudStackApi.java index 095a29a009e..65db1397973 100644 --- a/awsapi/src/com/cloud/stack/CloudStackApi.java +++ b/awsapi/src/com/cloud/stack/CloudStackApi.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack; @@ -72,7 +57,6 @@ import com.google.gson.reflect.TypeToken; /** * The goal here is to wrap the actual CloudStack API calls... * - * @author slriv * */ public class CloudStackApi { diff --git a/awsapi/src/com/cloud/stack/CloudStackClient.java b/awsapi/src/com/cloud/stack/CloudStackClient.java index a4c7c6331c2..5002aa593e7 100644 --- a/awsapi/src/com/cloud/stack/CloudStackClient.java +++ b/awsapi/src/com/cloud/stack/CloudStackClient.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack; import java.io.IOException; @@ -51,7 +36,6 @@ import com.google.gson.JsonParser; * CloudStackClient implements a simple CloudStack client object, it can be used to execute CloudStack commands * with JSON response * - * @author Kelven Yang */ public class CloudStackClient { protected final static Logger logger = Logger.getLogger(CloudStackClient.class); diff --git a/awsapi/src/com/cloud/stack/CloudStackCommand.java b/awsapi/src/com/cloud/stack/CloudStackCommand.java index 492ea950fdd..ea73df47fd2 100644 --- a/awsapi/src/com/cloud/stack/CloudStackCommand.java +++ b/awsapi/src/com/cloud/stack/CloudStackCommand.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack; import java.io.UnsupportedEncodingException; @@ -48,7 +33,6 @@ import org.apache.commons.codec.binary.Base64; /** * CloudStackCommand wraps command properties that are being sent to CloudStack * - * @author Kelven Yang */ public class CloudStackCommand { Map _params = new HashMap(); diff --git a/awsapi/src/com/cloud/stack/models/ApiConstants.java b/awsapi/src/com/cloud/stack/models/ApiConstants.java index 6a6df712a09..3305843f3e1 100644 --- a/awsapi/src/com/cloud/stack/models/ApiConstants.java +++ b/awsapi/src/com/cloud/stack/models/ApiConstants.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; public class ApiConstants { diff --git a/awsapi/src/com/cloud/stack/models/CloudStackAccount.java b/awsapi/src/com/cloud/stack/models/CloudStackAccount.java index 633337bf3a0..0da846ccaf4 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackAccount.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackAccount.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackAccount { @SerializedName(ApiConstants.ID) private String id; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackCapabilities.java b/awsapi/src/com/cloud/stack/models/CloudStackCapabilities.java index c4dbff9f2a8..629fa95900b 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackCapabilities.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackCapabilities.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackCapabilities { @SerializedName(ApiConstants.CLOUD_STACK_VERSION) private String cloudStackVersion; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackDiskOffering.java b/awsapi/src/com/cloud/stack/models/CloudStackDiskOffering.java index 9c51070e06d..308941c7ef6 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackDiskOffering.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackDiskOffering.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackDiskOffering { @SerializedName(ApiConstants.ID) private String id; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackEvent.java b/awsapi/src/com/cloud/stack/models/CloudStackEvent.java index 96073a271d4..6b986760e57 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackEvent.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackEvent.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackEvent { @SerializedName(ApiConstants.ID) private Long id; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackEventType.java b/awsapi/src/com/cloud/stack/models/CloudStackEventType.java index b01fba8592d..81202e233ee 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackEventType.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackEventType.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackEventType { @SerializedName(ApiConstants.NAME) private String name; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackExtractTemplate.java b/awsapi/src/com/cloud/stack/models/CloudStackExtractTemplate.java index 5841572dba7..c0974c036ad 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackExtractTemplate.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackExtractTemplate.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackExtractTemplate { @SerializedName(ApiConstants.ID) Long id; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackIdentifier.java b/awsapi/src/com/cloud/stack/models/CloudStackIdentifier.java index e893c5d6f49..5fa450ee9e0 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackIdentifier.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackIdentifier.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackIdentifier { @SerializedName(ApiConstants.CLOUD_IDENTIFIER) private String cloudIdentifier; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackInfoResponse.java b/awsapi/src/com/cloud/stack/models/CloudStackInfoResponse.java index 147bfa92232..f78482a77fe 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackInfoResponse.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackInfoResponse.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackIngressRule.java b/awsapi/src/com/cloud/stack/models/CloudStackIngressRule.java index de6e1021f79..68d54620147 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackIngressRule.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackIngressRule.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackInstanceGroup.java b/awsapi/src/com/cloud/stack/models/CloudStackInstanceGroup.java index b42a776ef15..cf012e51d2d 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackInstanceGroup.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackInstanceGroup.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackInstanceGroup { @SerializedName(ApiConstants.ID) private Long id; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackIpAddress.java b/awsapi/src/com/cloud/stack/models/CloudStackIpAddress.java index f02817d9349..72a3d515189 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackIpAddress.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackIpAddress.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackKeyPair.java b/awsapi/src/com/cloud/stack/models/CloudStackKeyPair.java index cadf46fc983..221f0ddfa2b 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackKeyPair.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackKeyPair.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackKeyValue.java b/awsapi/src/com/cloud/stack/models/CloudStackKeyValue.java index 132d830eb6b..9ce2d884554 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackKeyValue.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackKeyValue.java @@ -14,28 +14,9 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; -/** - * @author slriv - * - */ public class CloudStackKeyValue { private String key; private String value; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackLoadBalancerRule.java b/awsapi/src/com/cloud/stack/models/CloudStackLoadBalancerRule.java index 180eafacc82..9e4451e0994 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackLoadBalancerRule.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackLoadBalancerRule.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackLoadBalancerRule { @SerializedName(ApiConstants.ID) private String id; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackNetwork.java b/awsapi/src/com/cloud/stack/models/CloudStackNetwork.java index e175065fc7a..bbc0cefac7d 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackNetwork.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackNetwork.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; @@ -36,10 +21,6 @@ import java.util.List; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackNetwork { @SerializedName(ApiConstants.ID) private String id; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackNetworkOffering.java b/awsapi/src/com/cloud/stack/models/CloudStackNetworkOffering.java index e9f41ceec3a..576b426cb96 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackNetworkOffering.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackNetworkOffering.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackNetworkOffering { @SerializedName(ApiConstants.ID) private String id; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackNetworkService.java b/awsapi/src/com/cloud/stack/models/CloudStackNetworkService.java index e4ee48bf050..81f6a090ce7 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackNetworkService.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackNetworkService.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; @@ -36,10 +21,6 @@ import java.util.List; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackNetworkService { @SerializedName(ApiConstants.NAME) diff --git a/awsapi/src/com/cloud/stack/models/CloudStackNetworkServiceCapability.java b/awsapi/src/com/cloud/stack/models/CloudStackNetworkServiceCapability.java index c9781308350..e59898c3bf0 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackNetworkServiceCapability.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackNetworkServiceCapability.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackNetworkServiceCapability { @SerializedName(ApiConstants.NAME) private String name; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackNic.java b/awsapi/src/com/cloud/stack/models/CloudStackNic.java index e910e903600..a3fde39f7fb 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackNic.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackNic.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackOsCategory.java b/awsapi/src/com/cloud/stack/models/CloudStackOsCategory.java index 2f441020378..715c34e3e1f 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackOsCategory.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackOsCategory.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackOsCategory { @SerializedName(ApiConstants.ID) private Long id; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackOsType.java b/awsapi/src/com/cloud/stack/models/CloudStackOsType.java index 9a74ade87e7..65ad90e5f55 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackOsType.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackOsType.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackOsType { @SerializedName(ApiConstants.ID) private String id; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackPasswordData.java b/awsapi/src/com/cloud/stack/models/CloudStackPasswordData.java index 49d506c79a1..115125c5072 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackPasswordData.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackPasswordData.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackPasswordData { @SerializedName(ApiConstants.ENCRYPTED_PASSWORD) diff --git a/awsapi/src/com/cloud/stack/models/CloudStackPortForwardingRule.java b/awsapi/src/com/cloud/stack/models/CloudStackPortForwardingRule.java index 3f57952b074..19aedfac9e0 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackPortForwardingRule.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackPortForwardingRule.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackPortForwardingRule { @SerializedName(ApiConstants.ID) private String id; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackResourceLimit.java b/awsapi/src/com/cloud/stack/models/CloudStackResourceLimit.java index 6a654806fea..9ca45ae7a17 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackResourceLimit.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackResourceLimit.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackSecurityGroup.java b/awsapi/src/com/cloud/stack/models/CloudStackSecurityGroup.java index c0922068675..72ba5529670 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackSecurityGroup.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackSecurityGroup.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import java.util.List; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackSecurityGroupIngress.java b/awsapi/src/com/cloud/stack/models/CloudStackSecurityGroupIngress.java index 987e608045f..a8690ee68c5 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackSecurityGroupIngress.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackSecurityGroupIngress.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackSecurityGroupIngress { @SerializedName(ApiConstants.ACCOUNT) private String account; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackServiceOffering.java b/awsapi/src/com/cloud/stack/models/CloudStackServiceOffering.java index b914184b338..3dcf011ef5b 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackServiceOffering.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackServiceOffering.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackServiceOffering { @SerializedName(ApiConstants.ID) private String id; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackSnapshot.java b/awsapi/src/com/cloud/stack/models/CloudStackSnapshot.java index 1a2e53fbdf3..73dc4cd13ae 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackSnapshot.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackSnapshot.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackSnapshotPolicy.java b/awsapi/src/com/cloud/stack/models/CloudStackSnapshotPolicy.java index a9f883a72c2..b494d742bd6 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackSnapshotPolicy.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackSnapshotPolicy.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackSnapshotPolicy { @SerializedName(ApiConstants.ID) diff --git a/awsapi/src/com/cloud/stack/models/CloudStackTemplate.java b/awsapi/src/com/cloud/stack/models/CloudStackTemplate.java index a0f65e6eeb9..14d6e823cd4 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackTemplate.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackTemplate.java @@ -14,30 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackTemplate { @SerializedName(ApiConstants.ID) private String id; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackTemplatePermission.java b/awsapi/src/com/cloud/stack/models/CloudStackTemplatePermission.java index aab8774459a..5d7652d1d75 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackTemplatePermission.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackTemplatePermission.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; @@ -36,10 +21,6 @@ import java.util.List; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackTemplatePermission { @SerializedName(ApiConstants.ID) private String id; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackUser.java b/awsapi/src/com/cloud/stack/models/CloudStackUser.java index f8852b94e34..cdcfdae2850 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackUser.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackUser.java @@ -14,29 +14,10 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; -/** - * @author slriv - * - */ public class CloudStackUser { @SerializedName(ApiConstants.ID) diff --git a/awsapi/src/com/cloud/stack/models/CloudStackUserVm.java b/awsapi/src/com/cloud/stack/models/CloudStackUserVm.java index ac8915a2fb6..f72e1b62b22 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackUserVm.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackUserVm.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import java.util.List; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackVolume.java b/awsapi/src/com/cloud/stack/models/CloudStackVolume.java index dabd6359823..13d87f4bec8 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackVolume.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackVolume.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; diff --git a/awsapi/src/com/cloud/stack/models/CloudStackZone.java b/awsapi/src/com/cloud/stack/models/CloudStackZone.java index 1388a278bc5..a369840f986 100644 --- a/awsapi/src/com/cloud/stack/models/CloudStackZone.java +++ b/awsapi/src/com/cloud/stack/models/CloudStackZone.java @@ -14,21 +14,6 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -/* - * Copyright (C) 2011 Citrix Systems, Inc. All rights reserved. - * - * Licensed 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. - */ package com.cloud.stack.models; import com.google.gson.annotations.SerializedName; diff --git a/build.xml b/build.xml index 9e217ff5080..4b103b2e0a7 100755 --- a/build.xml +++ b/build.xml @@ -27,7 +27,7 @@ - + diff --git a/build/build-clouddev.xml b/build/build-devcloud.xml similarity index 73% rename from build/build-clouddev.xml rename to build/build-devcloud.xml index 20de53def36..b65e9e4d8ae 100644 --- a/build/build-clouddev.xml +++ b/build/build-devcloud.xml @@ -30,28 +30,30 @@ - + - + + + - + - + @@ -63,33 +65,33 @@ - + - + - + - + - + - + diff --git a/client/WEB-INF/classes/resources/messages.properties b/client/WEB-INF/classes/resources/messages.properties index 52e6900d963..35fe56849d9 100644 --- a/client/WEB-INF/classes/resources/messages.properties +++ b/client/WEB-INF/classes/resources/messages.properties @@ -7,8 +7,8 @@ message.action.disable.physical.network=Please confirm that you want to disable #modified labels (begin) ***************************************************************************************** - - +label.memory.mb=Memory (in MB) +label.cpu.mhz=CPU (in MHz) #modified labels (end) ******************************************************************************************* @@ -903,7 +903,6 @@ label.code=Code label.confirmation=Confirmation label.cpu.allocated.for.VMs=CPU Allocated for VMs label.cpu.allocated=CPU Allocated -label.cpu.mhz=CPU label.cpu.utilized=CPU Utilized label.cpu=CPU label.created=Created @@ -1023,7 +1022,6 @@ label.lun=LUN label.manage=Manage label.maximum=Maximum label.memory.allocated=Memory Allocated -label.memory.mb=Memory label.memory.total=Memory Total label.memory.used=Memory Used label.memory=Memory diff --git a/cloud.spec b/cloud.spec index f4ca068e644..773a729ae06 100644 --- a/cloud.spec +++ b/cloud.spec @@ -427,6 +427,8 @@ fi %{_javadir}/%{name}-user-authenticator-plaintext.jar %{_javadir}/%{name}-vmware.jar %{_javadir}/%{name}-xen.jar +%{_javadir}/%{name}-plugin-elb.jar +%{_javadir}/%{name}-plugin-netapp.jar %config(noreplace) %{_sysconfdir}/%{name}/server/* %files agent-scripts diff --git a/docs/runbook/en-US/Environment.xml b/docs/runbook/en-US/Environment.xml index df7a471e0f5..9048e1aa0a2 100644 --- a/docs/runbook/en-US/Environment.xml +++ b/docs/runbook/en-US/Environment.xml @@ -212,7 +212,7 @@ STATD_PORT=662 STATD_OUTGOING_PORT=2020 Now we need to configure the firewall to permit incoming NFS connections. - Edit the file /etc/sysconfig/nfs + Edit the file /etc/sysconfig/iptables -A INPUT -m state --state NEW -p udp --dport 111 -j ACCEPT diff --git a/docs/runbook/en-US/Management.xml b/docs/runbook/en-US/Management.xml index 6001c283c74..d95108e2ee1 100644 --- a/docs/runbook/en-US/Management.xml +++ b/docs/runbook/en-US/Management.xml @@ -108,7 +108,7 @@ binlog-format = 'ROW' with the mount command run on the management server: - # mount -t nfs 172.16.10.2/secondary /mnt/secondary + # mount -t nfs 172.16.10.2:/secondary /mnt/secondary Now we need to download the system VM template and deploy that to the diff --git a/docs/runbook/en-US/Overview.xml b/docs/runbook/en-US/Overview.xml index 87b249ade33..9b64f05e9c5 100644 --- a/docs/runbook/en-US/Overview.xml +++ b/docs/runbook/en-US/Overview.xml @@ -37,7 +37,8 @@ This runbook will focus on building a CloudStack cloud using KVM with CentOS 6.2 with NFS storage on a flat layer-2 network utilizing - layer-3 network isolation (aka Security Groups). + layer-3 network isolation (aka Security Groups), and doing it all + on a single piece of hardware. KVM, or Kernel-based Virtual Machine is a virtualization technology @@ -49,7 +50,17 @@ to a group of virtual machines. - +
+ High level overview of the process + + Before we actually get to installing CloudStack, we'll start with + installing our base operating system, and then configuring that to act + as an NFS server for several types of storage. We'll install the + management server, download the systemVMs, and finally install the agent + software. Finally we'll spend a good deal of time configuring the entire + cloud in the CloudStack web interface. + +
Prerequisites @@ -62,8 +73,9 @@ - The CentOS 6.2 x86_64 minimal installation CD available from here: + The + CentOS 6.2 x86_64 minimal install CD @@ -75,8 +87,9 @@ - Copy of CloudStack 3.0.2 for Red Hat Enterprise Linux (RHEL) and CentOS 6.2 available here: + Copy of + CloudStack 3.0.2 for RHEL and CentOS 6.2 diff --git a/ovm/.project b/ovm/.project new file mode 100644 index 00000000000..6ef55a50063 --- /dev/null +++ b/ovm/.project @@ -0,0 +1,23 @@ + + + ovm + + + + + + org.python.pydev.PyDevBuilder + + + + + org.eclipse.jdt.core.javabuilder + + + + + + org.eclipse.jdt.core.javanature + org.python.pydev.pythonNature + + diff --git a/patches/systemvm/debian/buildsystemvm.sh b/patches/systemvm/debian/buildsystemvm.sh index dff86017d84..090a0827e6b 100755 --- a/patches/systemvm/debian/buildsystemvm.sh +++ b/patches/systemvm/debian/buildsystemvm.sh @@ -1,16 +1,20 @@ #!/bin/bash -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 -e diff --git a/patches/systemvm/debian/convert.sh b/patches/systemvm/debian/convert.sh index 4687fd821ce..27098a13445 100755 --- a/patches/systemvm/debian/convert.sh +++ b/patches/systemvm/debian/convert.sh @@ -1,16 +1,20 @@ #!/bin/bash -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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. diff --git a/patches/systemvm/debian/qemuconvert.sh b/patches/systemvm/debian/qemuconvert.sh index 19e3b9caf9d..dc8eb15b3ab 100755 --- a/patches/systemvm/debian/qemuconvert.sh +++ b/patches/systemvm/debian/qemuconvert.sh @@ -1,16 +1,20 @@ #!/bin/bash -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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. diff --git a/patches/systemvm/debian/vhdconvert.sh b/patches/systemvm/debian/vhdconvert.sh index e10b9b8966e..0b0dbfb1724 100755 --- a/patches/systemvm/debian/vhdconvert.sh +++ b/patches/systemvm/debian/vhdconvert.sh @@ -1,16 +1,20 @@ #!/bin/bash -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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. diff --git a/plugins/file-systems/netapp/src/com/cloud/netapp/dao/VolumeDaoImpl.java b/plugins/file-systems/netapp/src/com/cloud/netapp/dao/VolumeDaoImpl.java index 9c23410eb0f..4a834294b6f 100644 --- a/plugins/file-systems/netapp/src/com/cloud/netapp/dao/VolumeDaoImpl.java +++ b/plugins/file-systems/netapp/src/com/cloud/netapp/dao/VolumeDaoImpl.java @@ -96,4 +96,5 @@ public class VolumeDaoImpl extends GenericDaoBase implemen return listBy(sc, searchFilter); } + } diff --git a/plugins/hypervisors/vmware/src/com/cloud/network/CiscoNexusVSMDeviceVO.java b/plugins/hypervisors/vmware/src/com/cloud/network/CiscoNexusVSMDeviceVO.java index 6165ec17953..c01dae0eb0b 100644 --- a/plugins/hypervisors/vmware/src/com/cloud/network/CiscoNexusVSMDeviceVO.java +++ b/plugins/hypervisors/vmware/src/com/cloud/network/CiscoNexusVSMDeviceVO.java @@ -58,7 +58,7 @@ public class CiscoNexusVSMDeviceVO implements CiscoNexusVSMDevice, Identity{ @Column(name = "username") private String vsmUserName; - @Column(name = "password") + @Column(name = "password", encryptable=true) private String vsmPassword; @Column(name = "ipaddr") diff --git a/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XcpOssResource.java b/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XcpOssResource.java index ef44f5effa0..d4260c72930 100644 --- a/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XcpOssResource.java +++ b/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XcpOssResource.java @@ -31,10 +31,18 @@ import com.cloud.agent.api.Answer; import com.cloud.agent.api.Command; import com.cloud.agent.api.NetworkUsageAnswer; import com.cloud.agent.api.NetworkUsageCommand; +import com.cloud.agent.api.StartAnswer; +import com.cloud.agent.api.StartCommand; import com.cloud.agent.api.StartupRoutingCommand; +import com.cloud.agent.api.StopAnswer; +import com.cloud.agent.api.StopCommand; +import com.cloud.agent.api.to.NicTO; +import com.cloud.agent.api.to.VirtualMachineTO; +import com.cloud.network.Networks.TrafficType; import com.cloud.resource.ServerResource; import com.cloud.utils.exception.CloudRuntimeException; import com.cloud.utils.script.Script; +import com.cloud.vm.VirtualMachine; import com.xensource.xenapi.Connection; import com.xensource.xenapi.Types; import com.xensource.xenapi.VBD; @@ -124,4 +132,35 @@ public class XcpOssResource extends CitrixResourceBase { return super.executeRequest(cmd); } } + + @Override + public StartAnswer execute(StartCommand cmd) { + StartAnswer answer = super.execute(cmd); + + VirtualMachineTO vmSpec = cmd.getVirtualMachine(); + if (vmSpec.getType() == VirtualMachine.Type.ConsoleProxy) { + Connection conn = getConnection(); + String publicIp = null; + for (NicTO nic : vmSpec.getNics()) { + if (nic.getType() == TrafficType.Guest) { + publicIp = nic.getIp(); + } + } + callHostPlugin(conn, "vmops", "setDNATRule", "ip", publicIp, "port", "8443", "add", "true"); + } + + return answer; + } + + @Override + public StopAnswer execute(StopCommand cmd) { + StopAnswer answer = super.execute(cmd); + String vmName = cmd.getVmName(); + if (vmName.startsWith("v-")) { + Connection conn = getConnection(); + callHostPlugin(conn, "vmops", "setDNATRule", "add", "false"); + } + return answer; + } + } diff --git a/scripts/vm/hypervisor/xenserver/xcposs/vmops b/scripts/vm/hypervisor/xenserver/xcposs/vmops index 3ea127e88ba..c8e6013f532 100644 --- a/scripts/vm/hypervisor/xenserver/xcposs/vmops +++ b/scripts/vm/hypervisor/xenserver/xcposs/vmops @@ -1450,6 +1450,18 @@ def bumpUpPriority(session, args): txt = '' return txt + +@echo +def setDNATRule(session, args): + add = args["add"] + if add == "false": + util.pread2(["iptables", "-t", "nat", "-F"]) + else: + ip = args["ip"] + port = args["port"] + util.pread2(["iptables", "-t", "nat", "-F"]) + util.pread2(["iptables", "-t", "nat", "-A", "PREROUTING", "-i", "xenbr0", "-p", "tcp", "--dport", port, "-m", "state", "--state", "NEW", "-j", "DNAT", "--to-destination", ip +":443"]) + return "" @echo def createISOVHD(session, args): @@ -1533,4 +1545,5 @@ if __name__ == "__main__": "cleanup_rules":cleanup_rules, "checkRouter":checkRouter, "bumpUpPriority":bumpUpPriority, "getDomRVersion":getDomRVersion, "kill_copy_process":kill_copy_process, - "createISOVHD":createISOVHD}) + "createISOVHD":createISOVHD, + "setDNATRule":setDNATRule}) diff --git a/scripts/vm/hypervisor/xenserver/xcpserver/patch b/scripts/vm/hypervisor/xenserver/xcpserver/patch index 68f7ed84eaa..b7961bb525c 100644 --- a/scripts/vm/hypervisor/xenserver/xcpserver/patch +++ b/scripts/vm/hypervisor/xenserver/xcpserver/patch @@ -59,3 +59,6 @@ create_privatetemplate_from_snapshot.sh=..,0755,/opt/xensource/bin upgrade_snapshot.sh=..,0755,/opt/xensource/bin cloud-clean-vlan.sh=..,0755,/opt/xensource/bin cloud-prepare-upgrade.sh=..,0755,/opt/xensource/bin +getRouterStatus.sh=../../../../network/domr/,0755,/opt/xensource/bin +bumpUpPriority.sh=../../../../network/domr/,0755,/opt/xensource/bin +getDomRVersion.sh=../../../../network/domr/,0755,/opt/xensource/bin diff --git a/server/src/com/cloud/api/ApiDBUtils.java b/server/src/com/cloud/api/ApiDBUtils.java index 69eadbcc511..f116681c131 100755 --- a/server/src/com/cloud/api/ApiDBUtils.java +++ b/server/src/com/cloud/api/ApiDBUtils.java @@ -83,6 +83,7 @@ import com.cloud.projects.ProjectService; import com.cloud.resource.ResourceManager; import com.cloud.server.Criteria; import com.cloud.server.ManagementServer; +import com.cloud.server.ResourceTag; import com.cloud.server.ResourceTag.TaggedResourceType; import com.cloud.server.StatsCollector; import com.cloud.server.TaggedResourceService; @@ -305,7 +306,7 @@ public class ApiDBUtils { } public static List searchForUserVMs(Criteria c, List permittedAccounts) { - return _userVmMgr.searchForUserVMs(c, _accountDao.findById(Account.ACCOUNT_ID_SYSTEM), null, false, permittedAccounts, false, null); + return _userVmMgr.searchForUserVMs(c, _accountDao.findById(Account.ACCOUNT_ID_SYSTEM), null, false, permittedAccounts, false, null, null); } public static List searchForStoragePools(Criteria c) { @@ -782,4 +783,8 @@ public class ApiDBUtils { boolean vpcProvider = _configMgr.isOfferingForVpc(offering); return vpcProvider; } + + public static List listByResourceTypeAndId(TaggedResourceType type, long resourceId) { + return _taggedResourceService.listByResourceTypeAndId(type, resourceId); + } } diff --git a/server/src/com/cloud/api/ApiResponseHelper.java b/server/src/com/cloud/api/ApiResponseHelper.java index b9c5444546f..5dfc64791ca 100755 --- a/server/src/com/cloud/api/ApiResponseHelper.java +++ b/server/src/com/cloud/api/ApiResponseHelper.java @@ -172,6 +172,7 @@ import com.cloud.projects.ProjectAccount; import com.cloud.projects.ProjectInvitation; import com.cloud.server.Criteria; import com.cloud.server.ResourceTag; +import com.cloud.server.ResourceTag.TaggedResourceType; import com.cloud.storage.DiskOfferingVO; import com.cloud.storage.GuestOS; import com.cloud.storage.GuestOSCategoryVO; @@ -548,6 +549,16 @@ public class ApiResponseHelper implements ResponseGenerator { snapshotResponse.setName(snapshot.getName()); snapshotResponse.setIntervalType(ApiDBUtils.getSnapshotIntervalTypes(snapshot.getId())); snapshotResponse.setState(snapshot.getStatus()); + + //set tag information + List tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.Snapshot, snapshot.getId()); + List tagResponses = new ArrayList(); + for (ResourceTag tag : tags) { + ResourceTagResponse tagResponse = createResourceTagResponse(tag, true); + tagResponses.add(tagResponse); + } + snapshotResponse.setTags(tagResponses); + snapshotResponse.setObjectName("snapshot"); return snapshotResponse; } @@ -819,6 +830,15 @@ public class ApiResponseHelper implements ResponseGenerator { } } + //set tag information + List tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.PublicIpAddress, ipAddr.getId()); + List tagResponses = new ArrayList(); + for (ResourceTag tag : tags) { + ResourceTagResponse tagResponse = createResourceTagResponse(tag, true); + tagResponses.add(tagResponse); + } + ipResponse.setTags(tagResponses); + ipResponse.setObjectName("ipaddress"); return ipResponse; } @@ -847,6 +867,15 @@ public class ApiResponseHelper implements ResponseGenerator { populateOwner(lbResponse, loadBalancer); lbResponse.setZoneId(publicIp.getDataCenterId()); + //set tag information + List tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.UserVm, loadBalancer.getId()); + List tagResponses = new ArrayList(); + for (ResourceTag tag : tags) { + ResourceTagResponse tagResponse = createResourceTagResponse(tag, true); + tagResponses.add(tagResponse); + } + lbResponse.setTags(tagResponses); + lbResponse.setObjectName("loadbalancer"); return lbResponse; } @@ -1134,6 +1163,15 @@ public class ApiResponseHelper implements ResponseGenerator { } } + //set tag information + List tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.Volume, volume.getId()); + List tagResponses = new ArrayList(); + for (ResourceTag tag : tags) { + ResourceTagResponse tagResponse = createResourceTagResponse(tag, true); + tagResponses.add(tagResponse); + } + volResponse.setTags(tagResponses); + volResponse.setExtractable(isExtractable); volResponse.setObjectName("volume"); return volResponse; @@ -1281,6 +1319,16 @@ public class ApiResponseHelper implements ResponseGenerator { if (state.equals(FirewallRule.State.Revoke)) { stateToSet = "Deleting"; } + + //set tag information + List tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.PortForwardingRule, fwRule.getId()); + List tagResponses = new ArrayList(); + for (ResourceTag tag : tags) { + ResourceTagResponse tagResponse = createResourceTagResponse(tag, true); + tagResponses.add(tagResponse); + } + response.setTags(tagResponses); + response.setState(stateToSet); response.setObjectName("portforwardingrule"); return response; @@ -1557,6 +1605,15 @@ public class ApiResponseHelper implements ResponseGenerator { userVmResponse.setNics(nicResponses); } + //set tag information + List tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.UserVm, userVm.getId()); + List tagResponses = new ArrayList(); + for (ResourceTag tag : tags) { + ResourceTagResponse tagResponse = createResourceTagResponse(tag, true); + tagResponses.add(tagResponse); + } + userVmResponse.setTags(tagResponses); + IpAddress ip = ApiDBUtils.findIpByAssociatedVmId(userVm.getId()); if (ip != null) { userVmResponse.setPublicIpId(ip.getId()); @@ -1835,6 +1892,21 @@ public class ApiResponseHelper implements ResponseGenerator { populateAccount(response, owner.getId()); populateDomain(response, owner.getDomainId()); + //set tag information + List tags = null; + if (result.getFormat() == ImageFormat.ISO) { + tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.ISO, result.getId()); + } else { + tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.Template, result.getId()); + } + + List tagResponses = new ArrayList(); + for (ResourceTag tag : tags) { + ResourceTagResponse tagResponse = createResourceTagResponse(tag, true); + tagResponses.add(tagResponse); + } + response.setTags(tagResponses); + response.setObjectName("iso"); return response; } @@ -2021,6 +2093,20 @@ public class ApiResponseHelper implements ResponseGenerator { templateResponse.setTemplateTag(template.getTemplateTag()); + //set tag information + List tags = null; + if (template.getFormat() == ImageFormat.ISO) { + tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.ISO, template.getId()); + } else { + tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.Template, template.getId()); + } + List tagResponses = new ArrayList(); + for (ResourceTag tag : tags) { + ResourceTagResponse tagResponse = createResourceTagResponse(tag, true); + tagResponses.add(tagResponse); + } + templateResponse.setTags(tagResponses); + templateResponse.setObjectName("template"); responses.add(templateResponse); return responses; @@ -2258,6 +2344,15 @@ public class ApiResponseHelper implements ResponseGenerator { egressRulesResponse.add(ruleData); } } + //set tag information + List tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.UserVm, networkGroup.getId()); + List tagResponses = new ArrayList(); + for (ResourceTag tag : tags) { + ResourceTagResponse tagResponse = createResourceTagResponse(tag, true); + tagResponses.add(tagResponse); + } + netGrpResponse.setTags(tagResponses); + netGrpResponse .setSecurityGroupIngressRules(ingressRulesResponse); netGrpResponse.setSecurityGroupEgressRules(egressRulesResponse); @@ -2914,6 +3009,15 @@ public class ApiResponseHelper implements ResponseGenerator { response.setVpcId(network.getVpcId()); response.setCanUseForDeploy(ApiDBUtils.canUseForDeploy(network)); + //set tag information + List tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.Network, network.getId()); + List tagResponses = new ArrayList(); + for (ResourceTag tag : tags) { + ResourceTagResponse tagResponse = createResourceTagResponse(tag, true); + tagResponses.add(tagResponse); + } + response.setTags(tagResponses); + response.setObjectName("network"); return response; } @@ -2976,6 +3080,15 @@ public class ApiResponseHelper implements ResponseGenerator { response.setIcmpCode(fwRule.getIcmpCode()); response.setIcmpType(fwRule.getIcmpType()); + //set tag information + List tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.FirewallRule, fwRule.getId()); + List tagResponses = new ArrayList(); + for (ResourceTag tag : tags) { + ResourceTagResponse tagResponse = createResourceTagResponse(tag, true); + tagResponses.add(tagResponse); + } + response.setTags(tagResponses); + response.setState(stateToSet); response.setObjectName("firewallrule"); return response; @@ -3131,6 +3244,15 @@ public class ApiResponseHelper implements ResponseGenerator { userVmResponse.setPublicIpId(userVmData.getPublicIpId()); userVmResponse.setPublicIp(userVmData.getPublicIp()); + //set tag information + List tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.UserVm, userVmData.getId()); + List tagResponses = new ArrayList(); + for (ResourceTag tag : tags) { + ResourceTagResponse tagResponse = createResourceTagResponse(tag, true); + tagResponses.add(tagResponse); + } + userVmResponse.setTags(tagResponses); + return userVmResponse; } @@ -3462,10 +3584,12 @@ public class ApiResponseHelper implements ResponseGenerator { } @Override - public ResourceTagResponse createResourceTagResponse(ResourceTag resourceTag) { + public ResourceTagResponse createResourceTagResponse(ResourceTag resourceTag, boolean keyValueOnly) { ResourceTagResponse response = new ResourceTagResponse(); response.setKey(resourceTag.getKey()); response.setValue(resourceTag.getValue()); + + if (!keyValueOnly) { response.setResourceType(resourceTag.getResourceType().toString()); response.setId(ApiDBUtils.getUuid(String.valueOf(resourceTag.getResourceId()),resourceTag.getResourceType())); Long accountId = resourceTag.getAccountId(); @@ -3489,6 +3613,7 @@ public class ApiResponseHelper implements ResponseGenerator { } response.setCustomer(resourceTag.getCustomer()); + } response.setObjectName("tag"); diff --git a/server/src/com/cloud/consoleproxy/ConsoleProxyManagerImpl.java b/server/src/com/cloud/consoleproxy/ConsoleProxyManagerImpl.java index 229c1a823a9..1d160dbcabf 100755 --- a/server/src/com/cloud/consoleproxy/ConsoleProxyManagerImpl.java +++ b/server/src/com/cloud/consoleproxy/ConsoleProxyManagerImpl.java @@ -263,6 +263,8 @@ public class ConsoleProxyManagerImpl implements ConsoleProxyManager, ConsoleProx private Map _zoneVmCountMap; // map private String _hashKey; + private String _staticPublicIp; + private int _staticPort; private final GlobalLock _allocProxyLock = GlobalLock.getInternLock(getAllocProxyLockName()); @@ -467,7 +469,11 @@ public class ConsoleProxyManagerImpl implements ConsoleProxyManager, ConsoleProx KeystoreVO ksVo = _ksDao.findByName(ConsoleProxyManager.CERTIFICATE_NAME); assert (ksVo != null); + if (_staticPublicIp == null) { return new ConsoleProxyInfo(proxy.isSslEnabled(), proxy.getPublicIpAddress(), _consoleProxyPort, proxy.getPort(), ksVo.getDomainSuffix()); + } else { + return new ConsoleProxyInfo(proxy.isSslEnabled(), _staticPublicIp, _consoleProxyPort, _staticPort, ksVo.getDomainSuffix()); + } } public ConsoleProxyVO doAssignProxy(long dataCenterId, long vmId) { @@ -1531,6 +1537,11 @@ public class ConsoleProxyManagerImpl implements ConsoleProxyManager, ConsoleProx _loadScanner.initScan(STARTUP_DELAY, _capacityScanInterval); _resourceMgr.registerResourceStateAdapter(this.getClass().getSimpleName(), this); + _staticPublicIp = _configDao.getValue("consoleproxy.static.publicIp"); + if (_staticPublicIp != null) { + _staticPort = NumbersUtil.parseInt(_configDao.getValue("consoleproxy.static.port"), 8443); + } + if (s_logger.isInfoEnabled()) { s_logger.info("Console Proxy Manager is configured."); } diff --git a/server/src/com/cloud/dc/ClusterDetailsDaoImpl.java b/server/src/com/cloud/dc/ClusterDetailsDaoImpl.java index e488695d711..4ee63c42890 100755 --- a/server/src/com/cloud/dc/ClusterDetailsDaoImpl.java +++ b/server/src/com/cloud/dc/ClusterDetailsDaoImpl.java @@ -22,6 +22,7 @@ import java.util.Map; import javax.ejb.Local; +import com.cloud.utils.crypt.DBEncryptionUtil; import com.cloud.utils.db.GenericDaoBase; import com.cloud.utils.db.SearchBuilder; import com.cloud.utils.db.SearchCriteria; @@ -31,12 +32,12 @@ import com.cloud.utils.db.Transaction; public class ClusterDetailsDaoImpl extends GenericDaoBase implements ClusterDetailsDao { protected final SearchBuilder ClusterSearch; protected final SearchBuilder DetailSearch; - + protected ClusterDetailsDaoImpl() { ClusterSearch = createSearchBuilder(); ClusterSearch.and("clusterId", ClusterSearch.entity().getClusterId(), SearchCriteria.Op.EQ); ClusterSearch.done(); - + DetailSearch = createSearchBuilder(); DetailSearch.and("clusterId", DetailSearch.entity().getClusterId(), SearchCriteria.Op.EQ); DetailSearch.and("name", DetailSearch.entity().getName(), SearchCriteria.Op.EQ); @@ -48,32 +49,40 @@ public class ClusterDetailsDaoImpl extends GenericDaoBase sc = DetailSearch.create(); sc.setParameters("clusterId", clusterId); sc.setParameters("name", name); - - return findOneIncludingRemovedBy(sc); + + ClusterDetailsVO detail = findOneIncludingRemovedBy(sc); + if("password".equals(name) && detail != null){ + detail.setValue(DBEncryptionUtil.decrypt(detail.getValue())); + } + return detail; } - + @Override public Map findDetails(long clusterId) { SearchCriteria sc = ClusterSearch.create(); sc.setParameters("clusterId", clusterId); - + List results = search(sc, null); Map details = new HashMap(results.size()); for (ClusterDetailsVO result : results) { - details.put(result.getName(), result.getValue()); + if("password".equals(result.getName())){ + details.put(result.getName(), DBEncryptionUtil.decrypt(result.getValue())); + } else { + details.put(result.getName(), result.getValue()); + } } return details; } - + @Override public void deleteDetails(long clusterId) { SearchCriteria sc = ClusterSearch.create(); sc.setParameters("clusterId", clusterId); - + List results = search(sc, null); for (ClusterDetailsVO result : results) { - remove(result.getId()); + remove(result.getId()); } } @@ -84,9 +93,13 @@ public class ClusterDetailsDaoImpl extends GenericDaoBase sc = ClusterSearch.create(); sc.setParameters("clusterId", clusterId); expunge(sc); - + for (Map.Entry detail : details.entrySet()) { - ClusterDetailsVO vo = new ClusterDetailsVO(clusterId, detail.getKey(), detail.getValue()); + String value = detail.getValue(); + if("password".equals(detail.getKey())){ + value = DBEncryptionUtil.encrypt(value); + } + ClusterDetailsVO vo = new ClusterDetailsVO(clusterId, detail.getKey(), value); persist(vo); } txn.commit(); @@ -100,10 +113,10 @@ public class ClusterDetailsDaoImpl extends GenericDaoBase _systemNetworks = new HashMap(5); private static Long _privateOfferingId = null; @@ -3127,6 +3132,7 @@ public class NetworkManagerImpl implements NetworkManager, NetworkService, Manag Boolean specifyIpRanges = cmd.getSpecifyIpRanges(); Long vpcId = cmd.getVpcId(); Boolean canUseForDeploy = cmd.canUseForDeploy(); + Map tags = cmd.getTags(); // 1) default is system to false if not specified // 2) reset parameter to false if it's specified by the regular user @@ -3211,6 +3217,18 @@ public class NetworkManagerImpl implements NetworkManager, NetworkService, Manag sb.join("zoneSearch", zoneSearch, sb.entity().getDataCenterId(), zoneSearch.entity().getId(), JoinBuilder.JoinType.INNER); sb.and("removed", sb.entity().getRemoved(), Op.NULL); + if (tags != null && !tags.isEmpty()) { + SearchBuilder tagSearch = _resourceTagDao.createSearchBuilder(); + for (int count=0; count < tags.size(); count++) { + tagSearch.or().op("key" + String.valueOf(count), tagSearch.entity().getKey(), SearchCriteria.Op.EQ); + tagSearch.and("value" + String.valueOf(count), tagSearch.entity().getValue(), SearchCriteria.Op.EQ); + tagSearch.cp(); + } + tagSearch.and("resourceType", tagSearch.entity().getResourceType(), SearchCriteria.Op.EQ); + sb.groupBy(sb.entity().getId()); + sb.join("tagSearch", tagSearch, sb.entity().getId(), tagSearch.entity().getResourceId(), JoinBuilder.JoinType.INNER); + } + if (permittedAccounts.isEmpty()) { SearchBuilder domainSearch = _domainDao.createSearchBuilder(); domainSearch.and("path", domainSearch.entity().getPath(), SearchCriteria.Op.LIKE); @@ -3231,24 +3249,24 @@ public class NetworkManagerImpl implements NetworkManager, NetworkService, Manag networksToReturn .addAll(listDomainLevelNetworks( buildNetworkSearchCriteria(sb, keyword, id, isSystem, zoneId, guestIpType, trafficType, - physicalNetworkId, aclType, skipProjectNetworks, restartRequired, specifyIpRanges, vpcId), searchFilter, + physicalNetworkId, aclType, skipProjectNetworks, restartRequired, specifyIpRanges, vpcId, tags), searchFilter, domainId)); } if (!permittedAccounts.isEmpty()) { networksToReturn.addAll(listAccountSpecificNetworks( buildNetworkSearchCriteria(sb, keyword, id, isSystem, zoneId, guestIpType, trafficType, - physicalNetworkId, aclType, skipProjectNetworks, restartRequired, specifyIpRanges, vpcId), searchFilter, + physicalNetworkId, aclType, skipProjectNetworks, restartRequired, specifyIpRanges, vpcId, tags), searchFilter, permittedAccounts)); } else if (domainId == null || listAll) { networksToReturn.addAll(listAccountSpecificNetworksByDomainPath( buildNetworkSearchCriteria(sb, keyword, id, isSystem, zoneId, guestIpType, trafficType, - physicalNetworkId, aclType, skipProjectNetworks, restartRequired, specifyIpRanges, vpcId), searchFilter, path, + physicalNetworkId, aclType, skipProjectNetworks, restartRequired, specifyIpRanges, vpcId, tags), searchFilter, path, isRecursive)); } } else { networksToReturn = _networksDao.search(buildNetworkSearchCriteria(sb, keyword, id, isSystem, zoneId, - guestIpType, trafficType, physicalNetworkId, null, skipProjectNetworks, restartRequired, specifyIpRanges, vpcId), + guestIpType, trafficType, physicalNetworkId, null, skipProjectNetworks, restartRequired, specifyIpRanges, vpcId, tags), searchFilter); } @@ -3306,7 +3324,8 @@ public class NetworkManagerImpl implements NetworkManager, NetworkService, Manag private SearchCriteria buildNetworkSearchCriteria(SearchBuilder sb, String keyword, Long id, Boolean isSystem, Long zoneId, String guestIpType, String trafficType, Long physicalNetworkId, - String aclType, boolean skipProjectNetworks, Boolean restartRequired, Boolean specifyIpRanges, Long vpcId) { + String aclType, boolean skipProjectNetworks, Boolean restartRequired, Boolean specifyIpRanges, Long vpcId, Map tags) { + SearchCriteria sc = sb.create(); if (isSystem != null) { @@ -3358,6 +3377,16 @@ public class NetworkManagerImpl implements NetworkManager, NetworkService, Manag if (vpcId != null) { sc.addAnd("vpcId", SearchCriteria.Op.EQ, vpcId); } + + if (tags != null && !tags.isEmpty()) { + int count = 0; + sc.setJoinParameters("tagSearch", "resourceType", TaggedResourceType.Network.toString()); + for (String key : tags.keySet()) { + sc.setJoinParameters("tagSearch", "key" + String.valueOf(count), key); + sc.setJoinParameters("tagSearch", "value" + String.valueOf(count), tags.get(key)); + count++; + } + } return sc; } diff --git a/server/src/com/cloud/network/dao/FirewallRulesDaoImpl.java b/server/src/com/cloud/network/dao/FirewallRulesDaoImpl.java index ea1eb4fc65c..be6bc701e66 100644 --- a/server/src/com/cloud/network/dao/FirewallRulesDaoImpl.java +++ b/server/src/com/cloud/network/dao/FirewallRulesDaoImpl.java @@ -27,6 +27,8 @@ import com.cloud.network.rules.FirewallRule.Purpose; import com.cloud.network.rules.FirewallRule.State; import com.cloud.network.rules.FirewallRule.TrafficType; import com.cloud.network.rules.FirewallRuleVO; +import com.cloud.server.ResourceTag.TaggedResourceType; +import com.cloud.tags.dao.ResourceTagsDaoImpl; import com.cloud.utils.component.ComponentLocator; import com.cloud.utils.db.DB; import com.cloud.utils.db.GenericDaoBase; @@ -50,6 +52,7 @@ public class FirewallRulesDaoImpl extends GenericDaoBase i protected final GenericSearchBuilder RulesByIpCount; protected final FirewallRulesCidrsDaoImpl _firewallRulesCidrsDao = ComponentLocator.inject(FirewallRulesCidrsDaoImpl.class); + ResourceTagsDaoImpl _tagsDao = ComponentLocator.inject(ResourceTagsDaoImpl.class); protected FirewallRulesDaoImpl() { super(); @@ -285,5 +288,23 @@ public class FirewallRulesDaoImpl extends GenericDaoBase i return listBy(sc); } + @DB + public boolean remove(Long id) { + Transaction txn = Transaction.currentTxn(); + txn.start(); + FirewallRuleVO entry = findById(id); + if (entry != null) { + if (entry.getPurpose() == Purpose.LoadBalancing) { + _tagsDao.removeByIdAndType(id, TaggedResourceType.LoadBalancer); + } else if (entry.getPurpose() == Purpose.PortForwarding) { + _tagsDao.removeByIdAndType(id, TaggedResourceType.PortForwardingRule); + } else if (entry.getPurpose() == Purpose.Firewall) { + _tagsDao.removeByIdAndType(id, TaggedResourceType.FirewallRule); + } + } + boolean result = super.remove(id); + txn.commit(); + return result; + } } diff --git a/server/src/com/cloud/network/dao/IPAddressDaoImpl.java b/server/src/com/cloud/network/dao/IPAddressDaoImpl.java index 9a4345ee091..dba3566d1fb 100755 --- a/server/src/com/cloud/network/dao/IPAddressDaoImpl.java +++ b/server/src/com/cloud/network/dao/IPAddressDaoImpl.java @@ -30,6 +30,8 @@ import com.cloud.dc.VlanVO; import com.cloud.dc.dao.VlanDaoImpl; import com.cloud.network.IPAddressVO; import com.cloud.network.IpAddress.State; +import com.cloud.server.ResourceTag.TaggedResourceType; +import com.cloud.tags.dao.ResourceTagsDaoImpl; import com.cloud.utils.component.ComponentLocator; import com.cloud.utils.db.DB; import com.cloud.utils.db.GenericDaoBase; @@ -55,6 +57,7 @@ public class IPAddressDaoImpl extends GenericDaoBase implemen protected final GenericSearchBuilder AllocatedIpCountForAccount; protected final VlanDaoImpl _vlanDao = ComponentLocator.inject(VlanDaoImpl.class); protected GenericSearchBuilder CountFreePublicIps; + ResourceTagsDaoImpl _tagsDao = ComponentLocator.inject(ResourceTagsDaoImpl.class); // make it public for JUnit test @@ -325,4 +328,18 @@ public class IPAddressDaoImpl extends GenericDaoBase implemen sc.setParameters("networkId", networkId); return customSearch(sc, null).get(0); } + + @Override + @DB + public boolean remove(Long id) { + Transaction txn = Transaction.currentTxn(); + txn.start(); + IPAddressVO entry = findById(id); + if (entry != null) { + _tagsDao.removeByIdAndType(id, TaggedResourceType.SecurityGroup); + } + boolean result = super.remove(id); + txn.commit(); + return result; + } } diff --git a/server/src/com/cloud/network/dao/LoadBalancerDaoImpl.java b/server/src/com/cloud/network/dao/LoadBalancerDaoImpl.java index e08b7869cf0..f624bfa92de 100644 --- a/server/src/com/cloud/network/dao/LoadBalancerDaoImpl.java +++ b/server/src/com/cloud/network/dao/LoadBalancerDaoImpl.java @@ -132,5 +132,5 @@ public class LoadBalancerDaoImpl extends GenericDaoBase im sc.setParameters("state", State.Add.toString(), State.Revoke.toString()); return listBy(sc); } - + } diff --git a/server/src/com/cloud/network/dao/NetworkDaoImpl.java b/server/src/com/cloud/network/dao/NetworkDaoImpl.java index 05111d2fe60..1796559b230 100644 --- a/server/src/com/cloud/network/dao/NetworkDaoImpl.java +++ b/server/src/com/cloud/network/dao/NetworkDaoImpl.java @@ -39,6 +39,8 @@ import com.cloud.network.Networks.TrafficType; import com.cloud.offering.NetworkOffering; import com.cloud.offerings.NetworkOfferingVO; import com.cloud.offerings.dao.NetworkOfferingDaoImpl; +import com.cloud.server.ResourceTag.TaggedResourceType; +import com.cloud.tags.dao.ResourceTagsDaoImpl; import com.cloud.utils.component.ComponentLocator; import com.cloud.utils.db.DB; import com.cloud.utils.db.GenericDaoBase; @@ -69,7 +71,7 @@ public class NetworkDaoImpl extends GenericDaoBase implements N private final GenericSearchBuilder NetworksCount; final SearchBuilder SourceNATSearch; final GenericSearchBuilder CountByZoneAndURI; - + ResourceTagsDaoImpl _tagsDao = ComponentLocator.inject(ResourceTagsDaoImpl.class); NetworkAccountDaoImpl _accountsDao = ComponentLocator.inject(NetworkAccountDaoImpl.class); NetworkDomainDaoImpl _domainsDao = ComponentLocator.inject(NetworkDomainDaoImpl.class); @@ -512,4 +514,16 @@ public class NetworkDaoImpl extends GenericDaoBase implements N return findOneBy(sc); } + @DB + public boolean remove(Long id) { + Transaction txn = Transaction.currentTxn(); + txn.start(); + NetworkVO entry = findById(id); + if (entry != null) { + _tagsDao.removeByIdAndType(id, TaggedResourceType.Network); + } + boolean result = super.remove(id); + txn.commit(); + return result; + } } diff --git a/server/src/com/cloud/network/firewall/FirewallManagerImpl.java b/server/src/com/cloud/network/firewall/FirewallManagerImpl.java index 857ab3f422c..2d297584396 100644 --- a/server/src/com/cloud/network/firewall/FirewallManagerImpl.java +++ b/server/src/com/cloud/network/firewall/FirewallManagerImpl.java @@ -58,6 +58,9 @@ import com.cloud.network.rules.FirewallRuleVO; import com.cloud.network.rules.PortForwardingRuleVO; import com.cloud.network.rules.dao.PortForwardingRulesDao; import com.cloud.projects.Project.ListProjectResourcesCriteria; +import com.cloud.server.ResourceTag.TaggedResourceType; +import com.cloud.tags.ResourceTagVO; +import com.cloud.tags.dao.ResourceTagDao; import com.cloud.user.Account; import com.cloud.user.AccountManager; import com.cloud.user.DomainManager; @@ -67,6 +70,7 @@ import com.cloud.utils.component.Inject; import com.cloud.utils.component.Manager; import com.cloud.utils.db.DB; import com.cloud.utils.db.Filter; +import com.cloud.utils.db.JoinBuilder; import com.cloud.utils.db.SearchBuilder; import com.cloud.utils.db.SearchCriteria; import com.cloud.utils.db.SearchCriteria.Op; @@ -105,6 +109,8 @@ public class FirewallManagerImpl implements FirewallService, FirewallManager, Ma PortForwardingRulesDao _pfRulesDao; @Inject UserVmDao _vmDao; + @Inject + ResourceTagDao _resourceTagDao; private boolean _elbEnabled = false; @@ -200,6 +206,7 @@ public class FirewallManagerImpl implements FirewallService, FirewallManager, Ma public List listFirewallRules(ListFirewallRulesCmd cmd) { Long ipId = cmd.getIpAddressId(); Long id = cmd.getId(); + Map tags = cmd.getTags(); Account caller = UserContext.current().getCaller(); List permittedAccounts = new ArrayList(); @@ -226,6 +233,19 @@ public class FirewallManagerImpl implements FirewallService, FirewallManager, Ma sb.and("ip", sb.entity().getSourceIpAddressId(), Op.EQ); sb.and("purpose", sb.entity().getPurpose(), Op.EQ); + + if (tags != null && !tags.isEmpty()) { + SearchBuilder tagSearch = _resourceTagDao.createSearchBuilder(); + for (int count=0; count < tags.size(); count++) { + tagSearch.or().op("key" + String.valueOf(count), tagSearch.entity().getKey(), SearchCriteria.Op.EQ); + tagSearch.and("value" + String.valueOf(count), tagSearch.entity().getValue(), SearchCriteria.Op.EQ); + tagSearch.cp(); + } + tagSearch.and("resourceType", tagSearch.entity().getResourceType(), SearchCriteria.Op.EQ); + sb.groupBy(sb.entity().getId()); + sb.join("tagSearch", tagSearch, sb.entity().getId(), tagSearch.entity().getResourceId(), JoinBuilder.JoinType.INNER); + } + SearchCriteria sc = sb.create(); _accountMgr.buildACLSearchCriteria(sc, domainId, isRecursive, permittedAccounts, listProjectResourcesCriteria); @@ -233,6 +253,16 @@ public class FirewallManagerImpl implements FirewallService, FirewallManager, Ma sc.setParameters("id", id); } + if (tags != null && !tags.isEmpty()) { + int count = 0; + sc.setJoinParameters("tagSearch", "resourceType", TaggedResourceType.FirewallRule.toString()); + for (String key : tags.keySet()) { + sc.setJoinParameters("tagSearch", "key" + String.valueOf(count), key); + sc.setJoinParameters("tagSearch", "value" + String.valueOf(count), tags.get(key)); + count++; + } + } + if (ipId != null) { sc.setParameters("ip", ipId); } diff --git a/server/src/com/cloud/network/lb/LoadBalancingRulesManagerImpl.java b/server/src/com/cloud/network/lb/LoadBalancingRulesManagerImpl.java index 557314818c7..58907272e7f 100755 --- a/server/src/com/cloud/network/lb/LoadBalancingRulesManagerImpl.java +++ b/server/src/com/cloud/network/lb/LoadBalancingRulesManagerImpl.java @@ -85,6 +85,9 @@ import com.cloud.network.rules.RulesManager; import com.cloud.network.rules.StickinessPolicy; import com.cloud.offering.NetworkOffering; import com.cloud.projects.Project.ListProjectResourcesCriteria; +import com.cloud.server.ResourceTag.TaggedResourceType; +import com.cloud.tags.ResourceTagVO; +import com.cloud.tags.dao.ResourceTagDao; import com.cloud.user.Account; import com.cloud.user.AccountManager; import com.cloud.user.DomainService; @@ -160,6 +163,8 @@ public class LoadBalancingRulesManagerImpl implements LoadBalancingRulesMa ExternalLoadBalancerUsageManager _externalLBUsageMgr; @Inject NetworkServiceMapDao _ntwkSrvcDao; + @Inject + ResourceTagDao _resourceTagDao; private String getLBStickinessCapability(long networkid) { Map> serviceCapabilitiesMap = _networkMgr.getNetworkCapabilities(networkid); @@ -1231,6 +1236,7 @@ public class LoadBalancingRulesManagerImpl implements LoadBalancingRulesMa String name = cmd.getLoadBalancerRuleName(); String keyword = cmd.getKeyword(); Long instanceId = cmd.getVirtualMachineId(); + Map tags = cmd.getTags(); Account caller = UserContext.current().getCaller(); List permittedAccounts = new ArrayList(); @@ -1261,6 +1267,18 @@ public class LoadBalancingRulesManagerImpl implements LoadBalancingRulesMa sb.join("ipSearch", ipSearch, sb.entity().getSourceIpAddressId(), ipSearch.entity().getId(), JoinBuilder.JoinType.INNER); } + if (tags != null && !tags.isEmpty()) { + SearchBuilder tagSearch = _resourceTagDao.createSearchBuilder(); + for (int count=0; count < tags.size(); count++) { + tagSearch.or().op("key" + String.valueOf(count), tagSearch.entity().getKey(), SearchCriteria.Op.EQ); + tagSearch.and("value" + String.valueOf(count), tagSearch.entity().getValue(), SearchCriteria.Op.EQ); + tagSearch.cp(); + } + tagSearch.and("resourceType", tagSearch.entity().getResourceType(), SearchCriteria.Op.EQ); + sb.groupBy(sb.entity().getId()); + sb.join("tagSearch", tagSearch, sb.entity().getId(), tagSearch.entity().getResourceId(), JoinBuilder.JoinType.INNER); + } + SearchCriteria sc = sb.create(); _accountMgr.buildACLSearchCriteria(sc, domainId, isRecursive, permittedAccounts, listProjectResourcesCriteria); @@ -1291,6 +1309,17 @@ public class LoadBalancingRulesManagerImpl implements LoadBalancingRulesMa sc.setJoinParameters("ipSearch", "zoneId", zoneId); } + + if (tags != null && !tags.isEmpty()) { + int count = 0; + sc.setJoinParameters("tagSearch", "resourceType", TaggedResourceType.LoadBalancer.toString()); + for (String key : tags.keySet()) { + sc.setJoinParameters("tagSearch", "key" + String.valueOf(count), key); + sc.setJoinParameters("tagSearch", "value" + String.valueOf(count), tags.get(key)); + count++; + } + } + return _lbDao.search(sc, searchFilter); } diff --git a/server/src/com/cloud/network/rules/RulesManagerImpl.java b/server/src/com/cloud/network/rules/RulesManagerImpl.java index 738cd8dcf2f..cda37d34ef5 100755 --- a/server/src/com/cloud/network/rules/RulesManagerImpl.java +++ b/server/src/com/cloud/network/rules/RulesManagerImpl.java @@ -52,6 +52,9 @@ import com.cloud.network.rules.FirewallRule.Purpose; import com.cloud.network.rules.dao.PortForwardingRulesDao; import com.cloud.offering.NetworkOffering; import com.cloud.projects.Project.ListProjectResourcesCriteria; +import com.cloud.server.ResourceTag.TaggedResourceType; +import com.cloud.tags.ResourceTagVO; +import com.cloud.tags.dao.ResourceTagDao; import com.cloud.user.Account; import com.cloud.user.AccountManager; import com.cloud.user.DomainManager; @@ -69,7 +72,6 @@ import com.cloud.utils.db.SearchCriteria.Op; import com.cloud.utils.db.Transaction; import com.cloud.utils.exception.CloudRuntimeException; import com.cloud.utils.net.Ip; -import com.cloud.utils.AnnotationHelper; import com.cloud.vm.Nic; import com.cloud.vm.UserVmVO; import com.cloud.vm.VirtualMachine; @@ -110,6 +112,8 @@ public class RulesManagerImpl implements RulesManager, RulesService, Manager { ConfigurationManager _configMgr; @Inject NicDao _nicDao; + @Inject + ResourceTagDao _resourceTagDao; @Override public void checkIpAndUserVm(IpAddress ipAddress, UserVm userVm, Account caller) { @@ -633,6 +637,7 @@ public class RulesManagerImpl implements RulesManager, RulesService, Manager { public List listPortForwardingRules(ListPortForwardingRulesCmd cmd) { Long ipId = cmd.getIpAddressId(); Long id = cmd.getId(); + Map tags = cmd.getTags(); Account caller = UserContext.current().getCaller(); List permittedAccounts = new ArrayList(); @@ -659,6 +664,19 @@ public class RulesManagerImpl implements RulesManager, RulesService, Manager { sb.and("ip", sb.entity().getSourceIpAddressId(), Op.EQ); sb.and("purpose", sb.entity().getPurpose(), Op.EQ); + if (tags != null && !tags.isEmpty()) { + SearchBuilder tagSearch = _resourceTagDao.createSearchBuilder(); + for (int count=0; count < tags.size(); count++) { + tagSearch.or().op("key" + String.valueOf(count), tagSearch.entity().getKey(), SearchCriteria.Op.EQ); + tagSearch.and("value" + String.valueOf(count), tagSearch.entity().getValue(), SearchCriteria.Op.EQ); + tagSearch.cp(); + } + tagSearch.and("resourceType", tagSearch.entity().getResourceType(), SearchCriteria.Op.EQ); + sb.groupBy(sb.entity().getId()); + sb.join("tagSearch", tagSearch, sb.entity().getId(), tagSearch.entity().getResourceId(), JoinBuilder.JoinType.INNER); + } + + SearchCriteria sc = sb.create(); _accountMgr.buildACLSearchCriteria(sc, domainId, isRecursive, permittedAccounts, listProjectResourcesCriteria); @@ -666,6 +684,16 @@ public class RulesManagerImpl implements RulesManager, RulesService, Manager { sc.setParameters("id", id); } + if (tags != null && !tags.isEmpty()) { + int count = 0; + sc.setJoinParameters("tagSearch", "resourceType", TaggedResourceType.PortForwardingRule.toString()); + for (String key : tags.keySet()) { + sc.setJoinParameters("tagSearch", "key" + String.valueOf(count), key); + sc.setJoinParameters("tagSearch", "value" + String.valueOf(count), tags.get(key)); + count++; + } + } + if (ipId != null) { sc.setParameters("ip", ipId); } diff --git a/server/src/com/cloud/network/security/SecurityGroupManagerImpl.java b/server/src/com/cloud/network/security/SecurityGroupManagerImpl.java index e9fb111d756..a1ed6d73e42 100755 --- a/server/src/com/cloud/network/security/SecurityGroupManagerImpl.java +++ b/server/src/com/cloud/network/security/SecurityGroupManagerImpl.java @@ -77,6 +77,9 @@ import com.cloud.network.security.dao.VmRulesetLogDao; import com.cloud.projects.Project.ListProjectResourcesCriteria; import com.cloud.projects.ProjectManager; import com.cloud.server.ManagementServer; +import com.cloud.server.ResourceTag.TaggedResourceType; +import com.cloud.tags.ResourceTagVO; +import com.cloud.tags.dao.ResourceTagDao; import com.cloud.user.Account; import com.cloud.user.AccountManager; import com.cloud.user.DomainManager; @@ -93,6 +96,7 @@ import com.cloud.utils.concurrency.NamedThreadFactory; import com.cloud.utils.db.DB; import com.cloud.utils.db.Filter; import com.cloud.utils.db.GlobalLock; +import com.cloud.utils.db.JoinBuilder; import com.cloud.utils.db.SearchBuilder; import com.cloud.utils.db.SearchCriteria; import com.cloud.utils.db.Transaction; @@ -155,6 +159,8 @@ public class SecurityGroupManagerImpl implements SecurityGroupManager, SecurityG ProjectManager _projectMgr; @Inject UsageEventDao _usageEventDao; + @Inject + ResourceTagDao _resourceTagDao; ScheduledExecutorService _executorPool; ScheduledExecutorService _cleanupExecutor; @@ -1093,6 +1099,7 @@ public class SecurityGroupManagerImpl implements SecurityGroupManager, SecurityG Long id = cmd.getId(); Object keyword = cmd.getKeyword(); List permittedAccounts = new ArrayList(); + Map tags = cmd.getTags(); if (instanceId != null) { UserVmVO userVM = _userVMDao.findById(instanceId); @@ -1117,6 +1124,18 @@ public class SecurityGroupManagerImpl implements SecurityGroupManager, SecurityG sb.and("id", sb.entity().getId(), SearchCriteria.Op.EQ); sb.and("name", sb.entity().getName(), SearchCriteria.Op.EQ); + + if (tags != null && !tags.isEmpty()) { + SearchBuilder tagSearch = _resourceTagDao.createSearchBuilder(); + for (int count=0; count < tags.size(); count++) { + tagSearch.or().op("key" + String.valueOf(count), tagSearch.entity().getKey(), SearchCriteria.Op.EQ); + tagSearch.and("value" + String.valueOf(count), tagSearch.entity().getValue(), SearchCriteria.Op.EQ); + tagSearch.cp(); + } + tagSearch.and("resourceType", tagSearch.entity().getResourceType(), SearchCriteria.Op.EQ); + sb.groupBy(sb.entity().getId()); + sb.join("tagSearch", tagSearch, sb.entity().getId(), tagSearch.entity().getResourceId(), JoinBuilder.JoinType.INNER); + } SearchCriteria sc = sb.create(); _accountMgr.buildACLSearchCriteria(sc, domainId, isRecursive, permittedAccounts, listProjectResourcesCriteria); @@ -1124,6 +1143,16 @@ public class SecurityGroupManagerImpl implements SecurityGroupManager, SecurityG if (id != null) { sc.setParameters("id", id); } + + if (tags != null && !tags.isEmpty()) { + int count = 0; + sc.setJoinParameters("tagSearch", "resourceType", TaggedResourceType.SecurityGroup.toString()); + for (String key : tags.keySet()) { + sc.setJoinParameters("tagSearch", "key" + String.valueOf(count), key); + sc.setJoinParameters("tagSearch", "value" + String.valueOf(count), tags.get(key)); + count++; + } + } if (securityGroup != null) { sc.setParameters("name", securityGroup); diff --git a/server/src/com/cloud/network/security/dao/SecurityGroupDaoImpl.java b/server/src/com/cloud/network/security/dao/SecurityGroupDaoImpl.java index a962e85ddb8..0c9bdc57995 100644 --- a/server/src/com/cloud/network/security/dao/SecurityGroupDaoImpl.java +++ b/server/src/com/cloud/network/security/dao/SecurityGroupDaoImpl.java @@ -21,19 +21,26 @@ import java.util.List; import javax.ejb.Local; import com.cloud.network.security.SecurityGroupVO; +import com.cloud.server.ResourceTag.TaggedResourceType; +import com.cloud.tags.dao.ResourceTagsDaoImpl; +import com.cloud.utils.component.ComponentLocator; +import com.cloud.utils.db.DB; import com.cloud.utils.db.GenericDaoBase; import com.cloud.utils.db.SearchBuilder; import com.cloud.utils.db.SearchCriteria; - -@Local(value={SecurityGroupDao.class}) -public class SecurityGroupDaoImpl extends GenericDaoBase implements SecurityGroupDao { +import com.cloud.utils.db.Transaction; + +@Local(value={SecurityGroupDao.class}) +public class SecurityGroupDaoImpl extends GenericDaoBase implements SecurityGroupDao { private SearchBuilder AccountIdSearch; private SearchBuilder AccountIdNameSearch; private SearchBuilder AccountIdNamesSearch; - - protected SecurityGroupDaoImpl() { - AccountIdSearch = createSearchBuilder(); - AccountIdSearch.and("accountId", AccountIdSearch.entity().getAccountId(), SearchCriteria.Op.EQ); + ResourceTagsDaoImpl _tagsDao = ComponentLocator.inject(ResourceTagsDaoImpl.class); + + + protected SecurityGroupDaoImpl() { + AccountIdSearch = createSearchBuilder(); + AccountIdSearch.and("accountId", AccountIdSearch.entity().getAccountId(), SearchCriteria.Op.EQ); AccountIdSearch.done(); AccountIdNameSearch = createSearchBuilder(); @@ -88,8 +95,23 @@ public class SecurityGroupDaoImpl extends GenericDaoBase } @Override public int removeByAccountId(long accountId) { - SearchCriteria sc = AccountIdSearch.create(); + SearchCriteria sc = AccountIdSearch.create(); sc.setParameters("accountId", accountId); return expunge(sc); } -} + + + @Override + @DB + public boolean remove(Long id) { + Transaction txn = Transaction.currentTxn(); + txn.start(); + SecurityGroupVO entry = findById(id); + if (entry != null) { + _tagsDao.removeByIdAndType(id, TaggedResourceType.SecurityGroup); + } + boolean result = super.remove(id); + txn.commit(); + return result; + } +} diff --git a/server/src/com/cloud/projects/dao/ProjectDaoImpl.java b/server/src/com/cloud/projects/dao/ProjectDaoImpl.java index a7eeb267793..87c8d21e959 100644 --- a/server/src/com/cloud/projects/dao/ProjectDaoImpl.java +++ b/server/src/com/cloud/projects/dao/ProjectDaoImpl.java @@ -73,8 +73,6 @@ public class ProjectDaoImpl extends GenericDaoBase implements P if (!update(projectId, projectToRemove)) { s_logger.warn("Failed to reset name for the project id=" + projectId + " as a part of project remove"); return false; - } else { - } result = super.remove(projectId); txn.commit(); diff --git a/server/src/com/cloud/server/ManagementServerImpl.java b/server/src/com/cloud/server/ManagementServerImpl.java index d4bf7506789..5a8b43741f0 100755 --- a/server/src/com/cloud/server/ManagementServerImpl.java +++ b/server/src/com/cloud/server/ManagementServerImpl.java @@ -170,6 +170,7 @@ import com.cloud.projects.Project; import com.cloud.projects.Project.ListProjectResourcesCriteria; import com.cloud.projects.ProjectManager; import com.cloud.resource.ResourceManager; +import com.cloud.server.ResourceTag.TaggedResourceType; import com.cloud.service.ServiceOfferingVO; import com.cloud.service.dao.ServiceOfferingDao; import com.cloud.storage.DiskOfferingVO; @@ -196,6 +197,8 @@ import com.cloud.storage.secondary.SecondaryStorageVmManager; import com.cloud.storage.snapshot.SnapshotManager; import com.cloud.storage.swift.SwiftManager; import com.cloud.storage.upload.UploadMonitor; +import com.cloud.tags.ResourceTagVO; +import com.cloud.tags.dao.ResourceTagDao; import com.cloud.template.VirtualMachineTemplate.TemplateFilter; import com.cloud.user.Account; import com.cloud.user.AccountManager; @@ -304,6 +307,7 @@ public class ManagementServerImpl implements ManagementServer { private final HypervisorCapabilitiesDao _hypervisorCapabilitiesDao; private final Adapters _hostAllocators; private final ConfigurationManager _configMgr; + private final ResourceTagDao _resourceTagDao; @Inject ProjectManager _projectMgr; @@ -379,6 +383,7 @@ public class ManagementServerImpl implements ManagementServer { _ksMgr = locator.getManager(KeystoreManager.class); _resourceMgr = locator.getManager(ResourceManager.class); _configMgr = locator.getManager(ConfigurationManager.class); + _resourceTagDao = locator.getDao(ResourceTagDao.class); _hypervisorCapabilitiesDao = locator.getDao(HypervisorCapabilitiesDao.class); @@ -1253,6 +1258,7 @@ public class ManagementServerImpl implements ManagementServer { public Set> listIsos(ListIsosCmd cmd) throws IllegalArgumentException, InvalidParameterValueException { TemplateFilter isoFilter = TemplateFilter.valueOf(cmd.getIsoFilter()); Account caller = UserContext.current().getCaller(); + Map tags = cmd.getTags(); boolean listAll = (caller.getType() != Account.ACCOUNT_TYPE_NORMAL && (isoFilter != null && isoFilter == TemplateFilter.all)); List permittedAccountIds = new ArrayList(); @@ -1267,14 +1273,14 @@ public class ManagementServerImpl implements ManagementServer { HypervisorType hypervisorType = HypervisorType.getType(cmd.getHypervisor()); return listTemplates(cmd.getId(), cmd.getIsoName(), cmd.getKeyword(), isoFilter, true, cmd.isBootable(), cmd.getPageSizeVal(), cmd.getStartIndex(), cmd.getZoneId(), hypervisorType, true, - cmd.listInReadyState(), permittedAccounts, caller, listProjectResourcesCriteria); + cmd.listInReadyState(), permittedAccounts, caller, listProjectResourcesCriteria, tags); } @Override public Set> listTemplates(ListTemplatesCmd cmd) throws IllegalArgumentException, InvalidParameterValueException { TemplateFilter templateFilter = TemplateFilter.valueOf(cmd.getTemplateFilter()); Long id = cmd.getId(); - + Map tags = cmd.getTags(); Account caller = UserContext.current().getCaller(); boolean listAll = (caller.getType() != Account.ACCOUNT_TYPE_NORMAL && (templateFilter != null && templateFilter == TemplateFilter.all)); @@ -1291,11 +1297,11 @@ public class ManagementServerImpl implements ManagementServer { HypervisorType hypervisorType = HypervisorType.getType(cmd.getHypervisor()); return listTemplates(id, cmd.getTemplateName(), cmd.getKeyword(), templateFilter, false, null, cmd.getPageSizeVal(), cmd.getStartIndex(), cmd.getZoneId(), hypervisorType, showDomr, - cmd.listInReadyState(), permittedAccounts, caller, listProjectResourcesCriteria); + cmd.listInReadyState(), permittedAccounts, caller, listProjectResourcesCriteria, tags); } private Set> listTemplates(Long templateId, String name, String keyword, TemplateFilter templateFilter, boolean isIso, Boolean bootable, Long pageSize, Long startIndex, - Long zoneId, HypervisorType hyperType, boolean showDomr, boolean onlyReady, List permittedAccounts, Account caller, ListProjectResourcesCriteria listProjectResourcesCriteria) { + Long zoneId, HypervisorType hyperType, boolean showDomr, boolean onlyReady, List permittedAccounts, Account caller, ListProjectResourcesCriteria listProjectResourcesCriteria, Map tags) { VMTemplateVO template = null; if (templateId != null) { @@ -1331,10 +1337,12 @@ public class ManagementServerImpl implements ManagementServer { Set> templateZonePairSet = new HashSet>(); if (_swiftMgr.isSwiftEnabled()) { if (template == null) { - templateZonePairSet = _templateDao.searchSwiftTemplates(name, keyword, templateFilter, isIso, hypers, bootable, domain, pageSize, startIndex, zoneId, hyperType, onlyReady, showDomr, + templateZonePairSet = _templateDao.searchSwiftTemplates(name, keyword, templateFilter, isIso, + hypers, bootable, domain, pageSize, startIndex, zoneId, hyperType, onlyReady, showDomr, permittedAccounts, caller); Set> templateZonePairSet2 = new HashSet>(); - templateZonePairSet2 = _templateDao.searchTemplates(name, keyword, templateFilter, isIso, hypers, bootable, domain, pageSize, startIndex, zoneId, hyperType, onlyReady, showDomr, + templateZonePairSet2 = _templateDao.searchTemplates(name, keyword, templateFilter, isIso, hypers, + bootable, domain, pageSize, startIndex, zoneId, hyperType, onlyReady, showDomr, permittedAccounts, caller, listProjectResourcesCriteria); for (Pair tmpltPair : templateZonePairSet2) { if (!templateZonePairSet.contains(new Pair(tmpltPair.first(), -1L))) { @@ -1352,7 +1360,8 @@ public class ManagementServerImpl implements ManagementServer { } } else { if (template == null) { - templateZonePairSet = _templateDao.searchTemplates(name, keyword, templateFilter, isIso, hypers, bootable, domain, pageSize, startIndex, zoneId, hyperType, onlyReady, showDomr, + templateZonePairSet = _templateDao.searchTemplates(name, keyword, templateFilter, isIso, hypers, + bootable, domain, pageSize, startIndex, zoneId, hyperType, onlyReady, showDomr, permittedAccounts, caller, listProjectResourcesCriteria); } else { // if template is not public, perform permission check here @@ -1698,6 +1707,7 @@ public class ManagementServerImpl implements ManagementServer { Boolean sourceNat = cmd.getIsSourceNat(); Boolean staticNat = cmd.getIsStaticNat(); Long vpcId = cmd.getVpcId(); + Map tags = cmd.getTags(); Account caller = UserContext.current().getCaller(); List permittedAccounts = new ArrayList(); @@ -1737,6 +1747,19 @@ public class ManagementServerImpl implements ManagementServer { sb.and("addressLIKE", sb.entity().getAddress(), SearchCriteria.Op.LIKE); } + if (tags != null && !tags.isEmpty()) { + SearchBuilder tagSearch = _resourceTagDao.createSearchBuilder(); + for (int count=0; count < tags.size(); count++) { + tagSearch.or().op("key" + String.valueOf(count), tagSearch.entity().getKey(), SearchCriteria.Op.EQ); + tagSearch.and("value" + String.valueOf(count), tagSearch.entity().getValue(), SearchCriteria.Op.EQ); + tagSearch.cp(); + } + tagSearch.and("resourceType", tagSearch.entity().getResourceType(), SearchCriteria.Op.EQ); + sb.groupBy(sb.entity().getId()); + sb.join("tagSearch", tagSearch, sb.entity().getId(), tagSearch.entity().getResourceId(), JoinBuilder.JoinType.INNER); + } + + SearchBuilder vlanSearch = _vlanDao.createSearchBuilder(); vlanSearch.and("vlanType", vlanSearch.entity().getVlanType(), SearchCriteria.Op.EQ); sb.join("vlanSearch", vlanSearch, sb.entity().getVlanId(), vlanSearch.entity().getId(), JoinBuilder.JoinType.INNER); @@ -1764,6 +1787,16 @@ public class ManagementServerImpl implements ManagementServer { sc.setJoinParameters("vlanSearch", "vlanType", vlanType); + if (tags != null && !tags.isEmpty()) { + int count = 0; + sc.setJoinParameters("tagSearch", "resourceType", TaggedResourceType.PublicIpAddress.toString()); + for (String key : tags.keySet()) { + sc.setJoinParameters("tagSearch", "key" + String.valueOf(count), key); + sc.setJoinParameters("tagSearch", "value" + String.valueOf(count), tags.get(key)); + count++; + } + } + if (zone != null) { sc.setParameters("dataCenterId", zone); } diff --git a/server/src/com/cloud/storage/StorageManagerImpl.java b/server/src/com/cloud/storage/StorageManagerImpl.java index 3fe27aeb3f1..8f18b04de4e 100755 --- a/server/src/com/cloud/storage/StorageManagerImpl.java +++ b/server/src/com/cloud/storage/StorageManagerImpl.java @@ -132,6 +132,7 @@ import com.cloud.projects.Project.ListProjectResourcesCriteria; import com.cloud.resource.ResourceManager; import com.cloud.resource.ResourceState; import com.cloud.server.ManagementServer; +import com.cloud.server.ResourceTag.TaggedResourceType; import com.cloud.service.ServiceOfferingVO; import com.cloud.service.dao.ServiceOfferingDao; import com.cloud.storage.Storage.ImageFormat; @@ -156,6 +157,8 @@ import com.cloud.storage.listener.StoragePoolMonitor; import com.cloud.storage.secondary.SecondaryStorageVmManager; import com.cloud.storage.snapshot.SnapshotManager; import com.cloud.storage.snapshot.SnapshotScheduler; +import com.cloud.tags.ResourceTagVO; +import com.cloud.tags.dao.ResourceTagDao; import com.cloud.template.TemplateManager; import com.cloud.user.Account; import com.cloud.user.AccountManager; @@ -320,6 +323,8 @@ public class StorageManagerImpl implements StorageManager, Manager, ClusterManag protected CheckPointManager _checkPointMgr; @Inject protected DownloadMonitor _downloadMonitor; + @Inject + protected ResourceTagDao _resourceTagDao; @Inject(adapter = StoragePoolAllocator.class) protected Adapters _storagePoolAllocators; @@ -3725,6 +3730,7 @@ public class StorageManagerImpl implements StorageManager, Manager, ClusterManag String name = cmd.getVolumeName(); String keyword = cmd.getKeyword(); String type = cmd.getType(); + Map tags = cmd.getTags(); Long zoneId = cmd.getZoneId(); Long podId = null; @@ -3764,6 +3770,18 @@ public class StorageManagerImpl implements StorageManager, Manager, ClusterManag vmSearch.and("type", vmSearch.entity().getType(), SearchCriteria.Op.NIN); vmSearch.or("nulltype", vmSearch.entity().getType(), SearchCriteria.Op.NULL); sb.join("vmSearch", vmSearch, sb.entity().getInstanceId(), vmSearch.entity().getId(), JoinBuilder.JoinType.LEFTOUTER); + + if (tags != null && !tags.isEmpty()) { + SearchBuilder tagSearch = _resourceTagDao.createSearchBuilder(); + for (int count=0; count < tags.size(); count++) { + tagSearch.or().op("key" + String.valueOf(count), tagSearch.entity().getKey(), SearchCriteria.Op.EQ); + tagSearch.and("value" + String.valueOf(count), tagSearch.entity().getValue(), SearchCriteria.Op.EQ); + tagSearch.cp(); + } + tagSearch.and("resourceType", tagSearch.entity().getResourceType(), SearchCriteria.Op.EQ); + sb.groupBy(sb.entity().getId()); + sb.join("tagSearch", tagSearch, sb.entity().getId(), tagSearch.entity().getResourceId(), JoinBuilder.JoinType.INNER); + } // now set the SC criteria... SearchCriteria sc = sb.create(); @@ -3782,6 +3800,16 @@ public class StorageManagerImpl implements StorageManager, Manager, ClusterManag } sc.setJoinParameters("diskOfferingSearch", "systemUse", 1); + + if (tags != null && !tags.isEmpty()) { + int count = 0; + sc.setJoinParameters("tagSearch", "resourceType", TaggedResourceType.Volume.toString()); + for (String key : tags.keySet()) { + sc.setJoinParameters("tagSearch", "key" + String.valueOf(count), key); + sc.setJoinParameters("tagSearch", "value" + String.valueOf(count), tags.get(key)); + count++; + } + } if (id != null) { sc.setParameters("id", id); diff --git a/server/src/com/cloud/storage/dao/SnapshotDaoImpl.java b/server/src/com/cloud/storage/dao/SnapshotDaoImpl.java index c0e09bf39d3..ac4bb6fc46d 100644 --- a/server/src/com/cloud/storage/dao/SnapshotDaoImpl.java +++ b/server/src/com/cloud/storage/dao/SnapshotDaoImpl.java @@ -24,13 +24,15 @@ import javax.ejb.Local; import org.apache.log4j.Logger; +import com.cloud.server.ResourceTag.TaggedResourceType; import com.cloud.storage.Snapshot; import com.cloud.storage.Snapshot.Type; import com.cloud.storage.SnapshotVO; -import com.cloud.storage.VMTemplateStorageResourceAssoc.Status; import com.cloud.storage.Volume; import com.cloud.storage.VolumeVO; +import com.cloud.tags.dao.ResourceTagsDaoImpl; import com.cloud.utils.component.ComponentLocator; +import com.cloud.utils.db.DB; import com.cloud.utils.db.Filter; import com.cloud.utils.db.GenericDaoBase; import com.cloud.utils.db.GenericSearchBuilder; @@ -60,6 +62,7 @@ public class SnapshotDaoImpl extends GenericDaoBase implements private final SearchBuilder InstanceIdSearch; private final SearchBuilder StatusSearch; private final GenericSearchBuilder CountSnapshotsByAccount; + ResourceTagsDaoImpl _tagsDao = ComponentLocator.inject(ResourceTagsDaoImpl.class); protected final VMInstanceDaoImpl _instanceDao = ComponentLocator.inject(VMInstanceDaoImpl.class); protected final VolumeDaoImpl _volumeDao = ComponentLocator.inject(VolumeDaoImpl.class); @@ -290,4 +293,18 @@ public class SnapshotDaoImpl extends GenericDaoBase implements sc.setParameters("status", (Object[])status); return listBy(sc, null); } + + @Override + @DB + public boolean remove(Long id) { + Transaction txn = Transaction.currentTxn(); + txn.start(); + SnapshotVO entry = findById(id); + if (entry != null) { + _tagsDao.removeByIdAndType(id, TaggedResourceType.Snapshot); + } + boolean result = super.remove(id); + txn.commit(); + return result; + } } diff --git a/server/src/com/cloud/storage/dao/VMTemplateDaoImpl.java b/server/src/com/cloud/storage/dao/VMTemplateDaoImpl.java index bb5f5ed9015..6f513a34b90 100755 --- a/server/src/com/cloud/storage/dao/VMTemplateDaoImpl.java +++ b/server/src/com/cloud/storage/dao/VMTemplateDaoImpl.java @@ -33,6 +33,7 @@ import javax.naming.ConfigurationException; import org.apache.log4j.Logger; import com.cloud.api.BaseCmd; +import com.cloud.configuration.Resource; import com.cloud.configuration.dao.ConfigurationDao; import com.cloud.dc.dao.DataCenterDao; import com.cloud.domain.DomainVO; @@ -42,14 +43,18 @@ import com.cloud.host.HostVO; import com.cloud.host.dao.HostDao; import com.cloud.hypervisor.Hypervisor.HypervisorType; import com.cloud.projects.Project.ListProjectResourcesCriteria; +import com.cloud.server.ResourceTag.TaggedResourceType; import com.cloud.storage.Storage; +import com.cloud.storage.Storage.ImageFormat; import com.cloud.storage.Storage.TemplateType; import com.cloud.storage.VMTemplateStorageResourceAssoc.Status; import com.cloud.storage.VMTemplateVO; import com.cloud.storage.VMTemplateZoneVO; +import com.cloud.tags.dao.ResourceTagsDaoImpl; import com.cloud.template.VirtualMachineTemplate.TemplateFilter; import com.cloud.user.Account; import com.cloud.utils.Pair; +import com.cloud.utils.component.ComponentLocator; import com.cloud.utils.component.Inject; import com.cloud.utils.db.DB; import com.cloud.utils.db.Filter; @@ -103,12 +108,15 @@ public class VMTemplateDaoImpl extends GenericDaoBase implem private SearchBuilder PublicIsoSearch; private GenericSearchBuilder CountTemplatesByAccount; - private String routerTmpltName; - private String consoleProxyTmpltName; - - protected VMTemplateDaoImpl() { - } - + ResourceTagsDaoImpl _tagsDao = ComponentLocator.inject(ResourceTagsDaoImpl.class); + + + private String routerTmpltName; + private String consoleProxyTmpltName; + + protected VMTemplateDaoImpl() { + } + @Override public List listByPublic() { SearchCriteria sc = PublicSearch.create(); @@ -789,12 +797,25 @@ public class VMTemplateDaoImpl extends GenericDaoBase implem } @Override + @DB public boolean remove(Long id) { + Transaction txn = Transaction.currentTxn(); + txn.start(); VMTemplateVO template = createForUpdate(); template.setRemoved(new Date()); + if (template != null) { + if (template.getFormat() == ImageFormat.ISO) { + _tagsDao.removeByIdAndType(id, TaggedResourceType.ISO); + } else { + _tagsDao.removeByIdAndType(id, TaggedResourceType.Template); + } + } - return update(id, template); + boolean result = update(id, template); + txn.commit(); + return result; } + private boolean isAdmin(short accountType) { return ((accountType == Account.ACCOUNT_TYPE_ADMIN) || (accountType == Account.ACCOUNT_TYPE_RESOURCE_DOMAIN_ADMIN) || diff --git a/server/src/com/cloud/storage/dao/VolumeDaoImpl.java b/server/src/com/cloud/storage/dao/VolumeDaoImpl.java index 95fa56850de..638d209e5b1 100755 --- a/server/src/com/cloud/storage/dao/VolumeDaoImpl.java +++ b/server/src/com/cloud/storage/dao/VolumeDaoImpl.java @@ -28,13 +28,16 @@ import javax.ejb.Local; import org.apache.log4j.Logger; import com.cloud.hypervisor.Hypervisor.HypervisorType; +import com.cloud.server.ResourceTag.TaggedResourceType; import com.cloud.storage.Storage.ImageFormat; import com.cloud.storage.Volume; import com.cloud.storage.Volume.Event; import com.cloud.storage.Volume.State; import com.cloud.storage.Volume.Type; import com.cloud.storage.VolumeVO; +import com.cloud.tags.dao.ResourceTagsDaoImpl; import com.cloud.utils.Pair; +import com.cloud.utils.component.ComponentLocator; import com.cloud.utils.db.DB; import com.cloud.utils.db.GenericDaoBase; import com.cloud.utils.db.GenericSearchBuilder; @@ -56,6 +59,7 @@ public class VolumeDaoImpl extends GenericDaoBase implements Vol protected final SearchBuilder InstanceStatesSearch; protected final SearchBuilder AllFieldsSearch; protected GenericSearchBuilder CountByAccount; + ResourceTagsDaoImpl _tagsDao = ComponentLocator.inject(ResourceTagsDaoImpl.class); protected static final String SELECT_VM_SQL = "SELECT DISTINCT instance_id from volumes v where v.host_id = ? and v.mirror_state = ?"; protected static final String SELECT_HYPERTYPE_FROM_VOLUME = "SELECT c.hypervisor_type from volumes v, storage_pool s, cluster c where v.pool_id = s.id and s.cluster_id = c.id and v.id = ?"; @@ -395,4 +399,18 @@ public class VolumeDaoImpl extends GenericDaoBase implements Vol SumCount sumCount = results.get(0); return new Pair(sumCount.count, sumCount.sum); } + + @Override + @DB + public boolean remove(Long id) { + Transaction txn = Transaction.currentTxn(); + txn.start(); + VolumeVO entry = findById(id); + if (entry != null) { + _tagsDao.removeByIdAndType(id, TaggedResourceType.Volume); + } + boolean result = super.remove(id); + txn.commit(); + return result; + } } diff --git a/server/src/com/cloud/storage/secondary/SecondaryStorageManagerImpl.java b/server/src/com/cloud/storage/secondary/SecondaryStorageManagerImpl.java index 16fffbb5c77..0dd1e422f85 100755 --- a/server/src/com/cloud/storage/secondary/SecondaryStorageManagerImpl.java +++ b/server/src/com/cloud/storage/secondary/SecondaryStorageManagerImpl.java @@ -1066,7 +1066,7 @@ public class SecondaryStorageManagerImpl implements SecondaryStorageVmManager, V if (profile.getHypervisorType() == HypervisorType.Hyperv) { buf.append(" resource=com.cloud.storage.resource.CifsSecondaryStorageResource"); } else { - buf.append(" resource=com.cloud.storage.resource.PremiumSecondaryStorageResource"); + buf.append(" resource=com.cloud.storage.resource.NfsSecondaryStorageResource"); } } else { buf.append(" resource=com.cloud.storage.resource.NfsSecondaryStorageResource"); diff --git a/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java b/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java index b07f7365cb2..50dcf384205 100755 --- a/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java +++ b/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java @@ -71,6 +71,7 @@ import com.cloud.org.Grouping; import com.cloud.projects.Project.ListProjectResourcesCriteria; import com.cloud.projects.ProjectManager; import com.cloud.resource.ResourceManager; +import com.cloud.server.ResourceTag.TaggedResourceType; import com.cloud.storage.Snapshot; import com.cloud.storage.Snapshot.Status; import com.cloud.storage.Snapshot.Type; @@ -93,6 +94,8 @@ import com.cloud.storage.dao.VMTemplateDao; import com.cloud.storage.dao.VolumeDao; import com.cloud.storage.secondary.SecondaryStorageVmManager; import com.cloud.storage.swift.SwiftManager; +import com.cloud.tags.ResourceTagVO; +import com.cloud.tags.dao.ResourceTagDao; import com.cloud.user.Account; import com.cloud.user.AccountManager; import com.cloud.user.AccountVO; @@ -112,6 +115,7 @@ import com.cloud.utils.component.Inject; import com.cloud.utils.component.Manager; import com.cloud.utils.db.DB; import com.cloud.utils.db.Filter; +import com.cloud.utils.db.JoinBuilder; import com.cloud.utils.db.SearchBuilder; import com.cloud.utils.db.SearchCriteria; import com.cloud.utils.db.Transaction; @@ -183,6 +187,9 @@ public class SnapshotManagerImpl implements SnapshotManager, SnapshotService, Ma private DomainManager _domainMgr; @Inject private VolumeDao _volumeDao; + @Inject + private ResourceTagDao _resourceTagDao; + String _name; private int _totalRetries; private int _pauseInterval; @@ -898,6 +905,7 @@ public class SnapshotManagerImpl implements SnapshotManager, SnapshotService, Ma String keyword = cmd.getKeyword(); String snapshotTypeStr = cmd.getSnapshotType(); String intervalTypeStr = cmd.getIntervalType(); + Map tags = cmd.getTags(); Account caller = UserContext.current().getCaller(); List permittedAccounts = new ArrayList(); @@ -926,6 +934,18 @@ public class SnapshotManagerImpl implements SnapshotManager, SnapshotService, Ma sb.and("id", sb.entity().getId(), SearchCriteria.Op.EQ); sb.and("snapshotTypeEQ", sb.entity().getsnapshotType(), SearchCriteria.Op.IN); sb.and("snapshotTypeNEQ", sb.entity().getsnapshotType(), SearchCriteria.Op.NEQ); + + if (tags != null && !tags.isEmpty()) { + SearchBuilder tagSearch = _resourceTagDao.createSearchBuilder(); + for (int count=0; count < tags.size(); count++) { + tagSearch.or().op("key" + String.valueOf(count), tagSearch.entity().getKey(), SearchCriteria.Op.EQ); + tagSearch.and("value" + String.valueOf(count), tagSearch.entity().getValue(), SearchCriteria.Op.EQ); + tagSearch.cp(); + } + tagSearch.and("resourceType", tagSearch.entity().getResourceType(), SearchCriteria.Op.EQ); + sb.groupBy(sb.entity().getId()); + sb.join("tagSearch", tagSearch, sb.entity().getId(), tagSearch.entity().getResourceId(), JoinBuilder.JoinType.INNER); + } SearchCriteria sc = sb.create(); _accountMgr.buildACLSearchCriteria(sc, domainId, isRecursive, permittedAccounts, listProjectResourcesCriteria); @@ -933,6 +953,16 @@ public class SnapshotManagerImpl implements SnapshotManager, SnapshotService, Ma if (volumeId != null) { sc.setParameters("volumeId", volumeId); } + + if (tags != null && !tags.isEmpty()) { + int count = 0; + sc.setJoinParameters("tagSearch", "resourceType", TaggedResourceType.Snapshot.toString()); + for (String key : tags.keySet()) { + sc.setJoinParameters("tagSearch", "key" + String.valueOf(count), key); + sc.setJoinParameters("tagSearch", "value" + String.valueOf(count), tags.get(key)); + count++; + } + } if (name != null) { sc.setParameters("name", "%" + name + "%"); diff --git a/server/src/com/cloud/tags/ResourceTagVO.java b/server/src/com/cloud/tags/ResourceTagVO.java index f1750063927..d5b28eb19c9 100644 --- a/server/src/com/cloud/tags/ResourceTagVO.java +++ b/server/src/com/cloud/tags/ResourceTagVO.java @@ -61,6 +61,9 @@ public class ResourceTagVO implements Identity, ResourceTag{ @Column(name="resource_id") long resourceId; + @Column(name="resource_uuid") + private String resourceUuid; + @Column(name="resource_type") @Enumerated(value=EnumType.STRING) private TaggedResourceType resourceType; @@ -81,9 +84,10 @@ public class ResourceTagVO implements Identity, ResourceTag{ * @param resourceId * @param resourceType * @param customer TODO + * @param resourceUuid TODO */ public ResourceTagVO(String key, String value, long accountId, long domainId, long resourceId, - TaggedResourceType resourceType, String customer) { + TaggedResourceType resourceType, String customer, String resourceUuid) { super(); this.key = key; this.value = value; @@ -93,6 +97,7 @@ public class ResourceTagVO implements Identity, ResourceTag{ this.resourceType = resourceType; this.uuid = UUID.randomUUID().toString(); this.customer = customer; + this.resourceUuid = resourceUuid; } @@ -149,4 +154,9 @@ public class ResourceTagVO implements Identity, ResourceTag{ public String getCustomer() { return customer; } + + @Override + public String getResourceUuid() { + return resourceUuid; + } } diff --git a/server/src/com/cloud/tags/TaggedResourceManagerImpl.java b/server/src/com/cloud/tags/TaggedResourceManagerImpl.java index d84b6b5de61..0386425d569 100644 --- a/server/src/com/cloud/tags/TaggedResourceManagerImpl.java +++ b/server/src/com/cloud/tags/TaggedResourceManagerImpl.java @@ -236,10 +236,12 @@ public class TaggedResourceManagerImpl implements TaggedResourceService, Manager for (String tag : tags.keySet()) { for (String resourceId : resourceIds) { Long id = getResourceId(resourceId, resourceType); + String resourceUuid = getUuid(resourceId, resourceType); //check if object exists if (_daoMap.get(resourceType).findById(id) == null) { - throw new InvalidParameterValueException("Unable to find resource by id " + resourceId + " and type " + resourceType); + throw new InvalidParameterValueException("Unable to find resource by id " + resourceId + + " and type " + resourceType); } Pair accountDomainPair = getAccountDomain(id, resourceType); @@ -257,10 +259,9 @@ public class TaggedResourceManagerImpl implements TaggedResourceService, Manager ResourceTagVO resourceTag = new ResourceTagVO(tag, tags.get(tag), accountDomainPair.first(), accountDomainPair.second(), - id, resourceType, customer); + id, resourceType, customer, resourceUuid); resourceTag = _resourceTagDao.persist(resourceTag); resourceTags.add(resourceTag); - } } @@ -282,14 +283,14 @@ public class TaggedResourceManagerImpl implements TaggedResourceService, Manager if (tableName == null) { throw new InvalidParameterValueException("Unable to find resource of type " + resourceType + " in the database"); } - identiyUUId = _identityDao.getIdentityUuid(tableName, resourceId); - if (identiyUUId != null) { - break; - } + + claz = claz.getSuperclass(); + if (claz == Object.class) { + identiyUUId = _identityDao.getIdentityUuid(tableName, resourceId); + } } catch (Exception ex) { //do nothing here, it might mean uuid field is missing and we have to search further } - claz = claz.getSuperclass(); } if (identiyUUId == null) { @@ -324,7 +325,9 @@ public class TaggedResourceManagerImpl implements TaggedResourceService, Manager sb.and("key", sb.entity().getKey(), SearchCriteria.Op.EQ); sb.and("value", sb.entity().getValue(), SearchCriteria.Op.EQ); - sb.and("resourceId", sb.entity().getResourceId(), SearchCriteria.Op.EQ); + sb.and().op("resourceId", sb.entity().getResourceId(), SearchCriteria.Op.EQ); + sb.or("resourceUuid", sb.entity().getResourceUuid(), SearchCriteria.Op.EQ); + sb.cp(); sb.and("resourceType", sb.entity().getResourceType(), SearchCriteria.Op.EQ); sb.and("customer", sb.entity().getCustomer(), SearchCriteria.Op.EQ); @@ -342,6 +345,7 @@ public class TaggedResourceManagerImpl implements TaggedResourceService, Manager if (resourceId != null) { sc.setParameters("resourceId", resourceId); + sc.setParameters("resourceUuid", resourceId); } if (resourceType != null) { @@ -362,10 +366,14 @@ public class TaggedResourceManagerImpl implements TaggedResourceService, Manager Account caller = UserContext.current().getCaller(); SearchBuilder sb = _resourceTagDao.createSearchBuilder(); - sb.and("resourceId", sb.entity().getResourceId(), SearchCriteria.Op.IN); + sb.and().op("resourceId", sb.entity().getResourceId(), SearchCriteria.Op.IN); + sb.or("resourceUuid", sb.entity().getResourceUuid(), SearchCriteria.Op.IN); + sb.cp(); sb.and("resourceType", sb.entity().getResourceType(), SearchCriteria.Op.EQ); + SearchCriteria sc = sb.create(); sc.setParameters("resourceId", resourceIds.toArray()); + sc.setParameters("resourceUuid", resourceIds.toArray()); sc.setParameters("resourceType", resourceType); List resourceTags = _resourceTagDao.search(sc, null);; @@ -400,6 +408,10 @@ public class TaggedResourceManagerImpl implements TaggedResourceService, Manager } } + if (tagsToRemove.isEmpty()) { + throw new InvalidParameterValueException("Unable to find tags by parameters specified"); + } + //Remove the tags Transaction txn = Transaction.currentTxn(); txn.start(); @@ -411,4 +423,10 @@ public class TaggedResourceManagerImpl implements TaggedResourceService, Manager return true; } + + + @Override + public List listByResourceTypeAndId(TaggedResourceType type, long resourceId) { + return _resourceTagDao.listBy(resourceId, type); + } } diff --git a/server/src/com/cloud/tags/dao/ResourceTagDao.java b/server/src/com/cloud/tags/dao/ResourceTagDao.java index efe9595201e..2a5c33928c9 100644 --- a/server/src/com/cloud/tags/dao/ResourceTagDao.java +++ b/server/src/com/cloud/tags/dao/ResourceTagDao.java @@ -16,6 +16,10 @@ // under the License. package com.cloud.tags.dao; +import java.util.List; + +import com.cloud.server.ResourceTag; +import com.cloud.server.ResourceTag.TaggedResourceType; import com.cloud.tags.ResourceTagVO; import com.cloud.utils.db.GenericDao; @@ -24,4 +28,20 @@ import com.cloud.utils.db.GenericDao; */ public interface ResourceTagDao extends GenericDao{ + /** + * @param resourceId + * @param resourceType + * @return + */ + boolean removeByIdAndType(long resourceId, TaggedResourceType resourceType); + + List listBy(long resourceId, TaggedResourceType resourceType); + +// /** +// * @param resourceUuId +// * @param resourceType +// * @return +// */ +// ResourceTag findByUuid(String resourceUuId, TaggedResourceType resourceType); + } diff --git a/server/src/com/cloud/tags/dao/ResourceTagsDaoImpl.java b/server/src/com/cloud/tags/dao/ResourceTagsDaoImpl.java index 7f43a046b35..255f9409263 100644 --- a/server/src/com/cloud/tags/dao/ResourceTagsDaoImpl.java +++ b/server/src/com/cloud/tags/dao/ResourceTagsDaoImpl.java @@ -16,10 +16,17 @@ // under the License. package com.cloud.tags.dao; +import java.util.List; + import javax.ejb.Local; +import com.cloud.server.ResourceTag; +import com.cloud.server.ResourceTag.TaggedResourceType; import com.cloud.tags.ResourceTagVO; import com.cloud.utils.db.GenericDaoBase; +import com.cloud.utils.db.SearchBuilder; +import com.cloud.utils.db.SearchCriteria; +import com.cloud.utils.db.SearchCriteria.Op; /** * @author Alena Prokharchyk @@ -27,7 +34,38 @@ import com.cloud.utils.db.GenericDaoBase; @Local(value = { ResourceTagDao.class }) public class ResourceTagsDaoImpl extends GenericDaoBase implements ResourceTagDao{ + final SearchBuilder AllFieldsSearch; - protected ResourceTagsDaoImpl() { + protected ResourceTagsDaoImpl() { + AllFieldsSearch = createSearchBuilder(); + AllFieldsSearch.and("resourceId", AllFieldsSearch.entity().getResourceId(), Op.EQ); + AllFieldsSearch.and("uuid", AllFieldsSearch.entity().getResourceUuid(), Op.EQ); + AllFieldsSearch.and("resourceType", AllFieldsSearch.entity().getResourceType(), Op.EQ); + AllFieldsSearch.done(); + } + + @Override + public boolean removeByIdAndType(long resourceId, ResourceTag.TaggedResourceType resourceType) { + SearchCriteria sc = AllFieldsSearch.create(); + sc.setParameters("resourceId", resourceId); + sc.setParameters("resourceType", resourceType); + remove(sc); + return true; + } + +// @Override +// public ResourceTag findByUuid(String resourceUuId, ResourceTag.TaggedResourceType resourceType) { +// SearchCriteria sc = AllFieldsSearch.create(); +// sc.setParameters("uuid", resourceUuId); +// sc.setParameters("resourceType", resourceType); +// return findOneBy(sc); +// } + + @Override + public List listBy(long resourceId, TaggedResourceType resourceType) { + SearchCriteria sc = AllFieldsSearch.create(); + sc.setParameters("resourceId", resourceId); + sc.setParameters("resourceType", resourceType); + return listBy(sc); } } diff --git a/server/src/com/cloud/vm/UserVmManager.java b/server/src/com/cloud/vm/UserVmManager.java index e4896761c54..11d2c64016f 100755 --- a/server/src/com/cloud/vm/UserVmManager.java +++ b/server/src/com/cloud/vm/UserVmManager.java @@ -95,9 +95,10 @@ public interface UserVmManager extends VirtualMachineGuru, UserVmServi * @param permittedAccounts TODO * @param listAll TODO * @param listProjectResourcesCriteria TODO + * @param tags TODO * @return List of UserVMs. */ - List searchForUserVMs(Criteria c, Account caller, Long domainId, boolean isRecursive, List permittedAccounts, boolean listAll, ListProjectResourcesCriteria listProjectResourcesCriteria); + List searchForUserVMs(Criteria c, Account caller, Long domainId, boolean isRecursive, List permittedAccounts, boolean listAll, ListProjectResourcesCriteria listProjectResourcesCriteria, Map tags); String getChecksum(Long hostId, String templatePath); diff --git a/server/src/com/cloud/vm/UserVmManagerImpl.java b/server/src/com/cloud/vm/UserVmManagerImpl.java index f151c329ebc..806f856d38d 100755 --- a/server/src/com/cloud/vm/UserVmManagerImpl.java +++ b/server/src/com/cloud/vm/UserVmManagerImpl.java @@ -149,6 +149,7 @@ import com.cloud.projects.ProjectManager; import com.cloud.resource.ResourceManager; import com.cloud.resource.ResourceState; import com.cloud.server.Criteria; +import com.cloud.server.ResourceTag.TaggedResourceType; import com.cloud.service.ServiceOfferingVO; import com.cloud.service.dao.ServiceOfferingDao; import com.cloud.storage.DiskOfferingVO; @@ -182,6 +183,8 @@ import com.cloud.storage.dao.VMTemplateZoneDao; import com.cloud.storage.dao.VolumeDao; import com.cloud.storage.dao.VolumeHostDao; import com.cloud.storage.snapshot.SnapshotManager; +import com.cloud.tags.ResourceTagVO; +import com.cloud.tags.dao.ResourceTagDao; import com.cloud.template.VirtualMachineTemplate; import com.cloud.template.VirtualMachineTemplate.BootloaderType; import com.cloud.user.Account; @@ -342,6 +345,8 @@ public class UserVmManagerImpl implements UserVmManager, UserVmService, Manager @Inject protected ItWorkDao _workDao; VolumeHostDao _volumeHostDao; + @Inject + ResourceTagDao _resourceTagDao; protected ScheduledExecutorService _executor = null; @@ -2901,6 +2906,7 @@ public class UserVmManagerImpl implements UserVmManager, UserVmService, Manager String hypervisor = cmd.getHypervisor(); boolean listAll = cmd.listAll(); Long id = cmd.getId(); + Map tags = cmd.getTags(); Ternary domainIdRecursiveListProject = new Ternary(cmd.getDomainId(), cmd.isRecursive(), null); _accountMgr.buildACLSearchParameters(caller, id, cmd.getAccountName(), cmd.getProjectId(), permittedAccounts, domainIdRecursiveListProject, listAll, false); @@ -2940,11 +2946,12 @@ public class UserVmManagerImpl implements UserVmManager, UserVmService, Manager } c.addCriteria(Criteria.ISADMIN, _accountMgr.isAdmin(caller.getType())); - return searchForUserVMs(c, caller, domainId, isRecursive, permittedAccounts, listAll, listProjectResourcesCriteria); + return searchForUserVMs(c, caller, domainId, isRecursive, permittedAccounts, listAll, listProjectResourcesCriteria, tags); } @Override - public List searchForUserVMs(Criteria c, Account caller, Long domainId, boolean isRecursive, List permittedAccounts, boolean listAll, ListProjectResourcesCriteria listProjectResourcesCriteria) { + public List searchForUserVMs(Criteria c, Account caller, Long domainId, boolean isRecursive, + List permittedAccounts, boolean listAll, ListProjectResourcesCriteria listProjectResourcesCriteria, Map tags) { Filter searchFilter = new Filter(UserVmVO.class, c.getOrderBy(), c.getAscending(), c.getOffset(), c.getLimit()); SearchBuilder sb = _vmDao.createSearchBuilder(); @@ -2988,6 +2995,18 @@ public class UserVmManagerImpl implements UserVmManager, UserVmService, Manager sb.join("groupSearch", groupSearch, sb.entity().getId(), groupSearch.entity().getInstanceId(), JoinBuilder.JoinType.INNER); } + if (tags != null && !tags.isEmpty()) { + SearchBuilder tagSearch = _resourceTagDao.createSearchBuilder(); + for (int count=0; count < tags.size(); count++) { + tagSearch.or().op("key" + String.valueOf(count), tagSearch.entity().getKey(), SearchCriteria.Op.EQ); + tagSearch.and("value" + String.valueOf(count), tagSearch.entity().getValue(), SearchCriteria.Op.EQ); + tagSearch.cp(); + } + tagSearch.and("resourceType", tagSearch.entity().getResourceType(), SearchCriteria.Op.EQ); + sb.groupBy(sb.entity().getId()); + sb.join("tagSearch", tagSearch, sb.entity().getId(), tagSearch.entity().getResourceId(), JoinBuilder.JoinType.INNER); + } + if (networkId != null) { SearchBuilder nicSearch = _nicDao.createSearchBuilder(); nicSearch.and("networkId", nicSearch.entity().getNetworkId(), SearchCriteria.Op.EQ); @@ -3009,6 +3028,16 @@ public class UserVmManagerImpl implements UserVmManager, UserVmService, Manager SearchCriteria sc = sb.create(); _accountMgr.buildACLSearchCriteria(sc, domainId, isRecursive, permittedAccounts, listProjectResourcesCriteria); + if (tags != null && !tags.isEmpty()) { + int count = 0; + sc.setJoinParameters("tagSearch", "resourceType", TaggedResourceType.UserVm.toString()); + for (String key : tags.keySet()) { + sc.setJoinParameters("tagSearch", "key" + String.valueOf(count), key); + sc.setJoinParameters("tagSearch", "value" + String.valueOf(count), tags.get(key)); + count++; + } + } + if (groupId != null && (Long) groupId == -1) { sc.setJoinParameters("vmSearch", "instanceId", (Object) null); } else if (groupId != null) { diff --git a/server/src/com/cloud/vm/dao/UserVmDao.java b/server/src/com/cloud/vm/dao/UserVmDao.java index aa09e45ab38..9fbcde377dd 100755 --- a/server/src/com/cloud/vm/dao/UserVmDao.java +++ b/server/src/com/cloud/vm/dao/UserVmDao.java @@ -70,4 +70,5 @@ public interface UserVmDao extends GenericDao { public Long countAllocatedVMsForAccount(long accountId); Hashtable listVmDetails(Hashtable userVmData); + } diff --git a/server/src/com/cloud/vm/dao/UserVmDaoImpl.java b/server/src/com/cloud/vm/dao/UserVmDaoImpl.java index 3ef0bf6bbc7..db1d8776623 100755 --- a/server/src/com/cloud/vm/dao/UserVmDaoImpl.java +++ b/server/src/com/cloud/vm/dao/UserVmDaoImpl.java @@ -16,6 +16,7 @@ // under the License. package com.cloud.vm.dao; + import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.SQLException; @@ -29,6 +30,9 @@ import javax.ejb.Local; import org.apache.log4j.Logger; +import com.cloud.configuration.Resource; +import com.cloud.server.ResourceTag.TaggedResourceType; +import com.cloud.tags.dao.ResourceTagsDaoImpl; import com.cloud.user.Account; import com.cloud.utils.component.ComponentLocator; import com.cloud.utils.db.Attribute; @@ -47,503 +51,515 @@ import com.cloud.vm.VirtualMachine.State; import com.cloud.vm.dao.UserVmData.NicData; import com.cloud.vm.dao.UserVmData.SecurityGroupData; -@Local(value={UserVmDao.class}) -public class UserVmDaoImpl extends GenericDaoBase implements UserVmDao { - public static final Logger s_logger = Logger.getLogger(UserVmDaoImpl.class); - - protected final SearchBuilder AccountPodSearch; - protected final SearchBuilder AccountDataCenterSearch; - protected final SearchBuilder AccountSearch; - protected final SearchBuilder HostSearch; - protected final SearchBuilder LastHostSearch; - protected final SearchBuilder HostUpSearch; - protected final SearchBuilder HostRunningSearch; - protected final SearchBuilder StateChangeSearch; - protected final SearchBuilder AccountHostSearch; - - protected final SearchBuilder DestroySearch; - protected SearchBuilder AccountDataCenterVirtualSearch; - protected GenericSearchBuilder CountByAccountPod; - protected GenericSearchBuilder CountByAccount; - protected GenericSearchBuilder PodsHavingVmsForAccount; - - protected SearchBuilder UserVmSearch; + +@Local(value={UserVmDao.class}) +public class UserVmDaoImpl extends GenericDaoBase implements UserVmDao { + public static final Logger s_logger = Logger.getLogger(UserVmDaoImpl.class); + + protected final SearchBuilder AccountPodSearch; + protected final SearchBuilder AccountDataCenterSearch; + protected final SearchBuilder AccountSearch; + protected final SearchBuilder HostSearch; + protected final SearchBuilder LastHostSearch; + protected final SearchBuilder HostUpSearch; + protected final SearchBuilder HostRunningSearch; + protected final SearchBuilder StateChangeSearch; + protected final SearchBuilder AccountHostSearch; + + protected final SearchBuilder DestroySearch; + protected SearchBuilder AccountDataCenterVirtualSearch; + protected GenericSearchBuilder CountByAccountPod; + protected GenericSearchBuilder CountByAccount; + protected GenericSearchBuilder PodsHavingVmsForAccount; + + protected SearchBuilder UserVmSearch; protected final Attribute _updateTimeAttr; - - private static final String LIST_PODS_HAVING_VMS_FOR_ACCOUNT = "SELECT pod_id FROM cloud.vm_instance WHERE data_center_id = ? AND account_id = ? AND pod_id IS NOT NULL AND (state = 'Running' OR state = 'Stopped') " + - "GROUP BY pod_id HAVING count(id) > 0 ORDER BY count(id) DESC"; - - private static String VM_DETAILS = "select vm_instance.id, " + - "account.id, account.account_name, account.type, domain.name, instance_group.id, instance_group.name," + - "data_center.id, data_center.name, data_center.is_security_group_enabled, host.id, host.name, " + - "vm_template.id, vm_template.name, vm_template.display_text, iso.id, iso.name, " + - "vm_template.enable_password, service_offering.id, disk_offering.name, storage_pool.id, storage_pool.pool_type, " + - "service_offering.cpu, service_offering.speed, service_offering.ram_size, volumes.id, volumes.device_id, volumes.volume_type, security_group.id, security_group.name, " + - "security_group.description, nics.id, nics.ip4_address, nics.default_nic, nics.gateway, nics.network_id, nics.netmask, nics.mac_address, nics.broadcast_uri, nics.isolation_uri, " + - "networks.traffic_type, networks.guest_type, user_ip_address.id, user_ip_address.public_ip_address from vm_instance " + - "left join account on vm_instance.account_id=account.id " + - "left join domain on vm_instance.domain_id=domain.id " + - "left join instance_group_vm_map on vm_instance.id=instance_group_vm_map.instance_id " + - "left join instance_group on instance_group_vm_map.group_id=instance_group.id " + - "left join data_center on vm_instance.data_center_id=data_center.id " + - "left join host on vm_instance.host_id=host.id " + - "left join vm_template on vm_instance.vm_template_id=vm_template.id " + - "left join user_vm on vm_instance.id=user_vm.id " + - "left join vm_template iso on iso.id=user_vm.iso_id " + - "left join service_offering on vm_instance.service_offering_id=service_offering.id " + - "left join disk_offering on vm_instance.service_offering_id=disk_offering.id " + - "left join volumes on vm_instance.id=volumes.instance_id " + - "left join storage_pool on volumes.pool_id=storage_pool.id " + - "left join security_group_vm_map on vm_instance.id=security_group_vm_map.instance_id " + - "left join security_group on security_group_vm_map.security_group_id=security_group.id " + - "left join nics on vm_instance.id=nics.instance_id " + - "left join networks on nics.network_id=networks.id " + - "left join user_ip_address on user_ip_address.vm_id=vm_instance.id " + - "where vm_instance.id in ("; - - private static final int VM_DETAILS_BATCH_SIZE=100; - - protected final UserVmDetailsDaoImpl _detailsDao = ComponentLocator.inject(UserVmDetailsDaoImpl.class); - protected final NicDaoImpl _nicDao = ComponentLocator.inject(NicDaoImpl.class); - - protected UserVmDaoImpl() { - AccountSearch = createSearchBuilder(); - AccountSearch.and("account", AccountSearch.entity().getAccountId(), SearchCriteria.Op.EQ); - AccountSearch.done(); - - HostSearch = createSearchBuilder(); - HostSearch.and("host", HostSearch.entity().getHostId(), SearchCriteria.Op.EQ); - HostSearch.done(); - - LastHostSearch = createSearchBuilder(); - LastHostSearch.and("lastHost", LastHostSearch.entity().getLastHostId(), SearchCriteria.Op.EQ); - LastHostSearch.and("state", LastHostSearch.entity().getState(), SearchCriteria.Op.EQ); - LastHostSearch.done(); - - HostUpSearch = createSearchBuilder(); - HostUpSearch.and("host", HostUpSearch.entity().getHostId(), SearchCriteria.Op.EQ); - HostUpSearch.and("states", HostUpSearch.entity().getState(), SearchCriteria.Op.NIN); - HostUpSearch.done(); - - HostRunningSearch = createSearchBuilder(); - HostRunningSearch.and("host", HostRunningSearch.entity().getHostId(), SearchCriteria.Op.EQ); - HostRunningSearch.and("state", HostRunningSearch.entity().getState(), SearchCriteria.Op.EQ); - HostRunningSearch.done(); - - AccountPodSearch = createSearchBuilder(); - AccountPodSearch.and("account", AccountPodSearch.entity().getAccountId(), SearchCriteria.Op.EQ); - AccountPodSearch.and("pod", AccountPodSearch.entity().getPodIdToDeployIn(), SearchCriteria.Op.EQ); - AccountPodSearch.done(); - - AccountDataCenterSearch = createSearchBuilder(); - AccountDataCenterSearch.and("account", AccountDataCenterSearch.entity().getAccountId(), SearchCriteria.Op.EQ); - AccountDataCenterSearch.and("dc", AccountDataCenterSearch.entity().getDataCenterIdToDeployIn(), SearchCriteria.Op.EQ); - AccountDataCenterSearch.done(); - - StateChangeSearch = createSearchBuilder(); - StateChangeSearch.and("id", StateChangeSearch.entity().getId(), SearchCriteria.Op.EQ); - StateChangeSearch.and("states", StateChangeSearch.entity().getState(), SearchCriteria.Op.EQ); - StateChangeSearch.and("host", StateChangeSearch.entity().getHostId(), SearchCriteria.Op.EQ); - StateChangeSearch.and("update", StateChangeSearch.entity().getUpdated(), SearchCriteria.Op.EQ); - StateChangeSearch.done(); - - DestroySearch = createSearchBuilder(); - DestroySearch.and("state", DestroySearch.entity().getState(), SearchCriteria.Op.IN); - DestroySearch.and("updateTime", DestroySearch.entity().getUpdateTime(), SearchCriteria.Op.LT); - DestroySearch.done(); - - AccountHostSearch = createSearchBuilder(); - AccountHostSearch.and("accountId", AccountHostSearch.entity().getAccountId(), SearchCriteria.Op.EQ); - AccountHostSearch.and("hostId", AccountHostSearch.entity().getHostId(), SearchCriteria.Op.EQ); - AccountHostSearch.done(); - - CountByAccountPod = createSearchBuilder(Long.class); - CountByAccountPod.select(null, Func.COUNT, null); - CountByAccountPod.and("account", CountByAccountPod.entity().getAccountId(), SearchCriteria.Op.EQ); - CountByAccountPod.and("pod", CountByAccountPod.entity().getPodIdToDeployIn(), SearchCriteria.Op.EQ); - CountByAccountPod.done(); - - CountByAccount = createSearchBuilder(Long.class); - CountByAccount.select(null, Func.COUNT, null); - CountByAccount.and("account", CountByAccount.entity().getAccountId(), SearchCriteria.Op.EQ); - CountByAccount.and("type", CountByAccount.entity().getType(), SearchCriteria.Op.EQ); - CountByAccount.and("state", CountByAccount.entity().getState(), SearchCriteria.Op.NIN); - CountByAccount.done(); - - - SearchBuilder nicSearch = _nicDao.createSearchBuilder(); - nicSearch.and("networkId", nicSearch.entity().getNetworkId(), SearchCriteria.Op.EQ); - nicSearch.and("ip4Address", nicSearch.entity().getIp4Address(), SearchCriteria.Op.NNULL); - - AccountDataCenterVirtualSearch = createSearchBuilder(); - AccountDataCenterVirtualSearch.and("account", AccountDataCenterVirtualSearch.entity().getAccountId(), SearchCriteria.Op.EQ); - AccountDataCenterVirtualSearch.and("dc", AccountDataCenterVirtualSearch.entity().getDataCenterIdToDeployIn(), SearchCriteria.Op.EQ); - AccountDataCenterVirtualSearch.join("nicSearch", nicSearch, AccountDataCenterVirtualSearch.entity().getId(), nicSearch.entity().getInstanceId(), JoinBuilder.JoinType.INNER); - AccountDataCenterVirtualSearch.done(); - - - _updateTimeAttr = _allAttributes.get("updateTime"); - assert _updateTimeAttr != null : "Couldn't get this updateTime attribute"; - } + ResourceTagsDaoImpl _tagsDao = ComponentLocator.inject(ResourceTagsDaoImpl.class); + + + private static final String LIST_PODS_HAVING_VMS_FOR_ACCOUNT = "SELECT pod_id FROM cloud.vm_instance WHERE data_center_id = ? AND account_id = ? AND pod_id IS NOT NULL AND (state = 'Running' OR state = 'Stopped') " + + "GROUP BY pod_id HAVING count(id) > 0 ORDER BY count(id) DESC"; + + private static String VM_DETAILS = "select vm_instance.id, " + + "account.id, account.account_name, account.type, domain.name, instance_group.id, instance_group.name," + + "data_center.id, data_center.name, data_center.is_security_group_enabled, host.id, host.name, " + + "vm_template.id, vm_template.name, vm_template.display_text, iso.id, iso.name, " + + "vm_template.enable_password, service_offering.id, disk_offering.name, storage_pool.id, storage_pool.pool_type, " + + "service_offering.cpu, service_offering.speed, service_offering.ram_size, volumes.id, volumes.device_id, volumes.volume_type, security_group.id, security_group.name, " + + "security_group.description, nics.id, nics.ip4_address, nics.default_nic, nics.gateway, nics.network_id, nics.netmask, nics.mac_address, nics.broadcast_uri, nics.isolation_uri, " + + "networks.traffic_type, networks.guest_type, user_ip_address.id, user_ip_address.public_ip_address from vm_instance " + + "left join account on vm_instance.account_id=account.id " + + "left join domain on vm_instance.domain_id=domain.id " + + "left join instance_group_vm_map on vm_instance.id=instance_group_vm_map.instance_id " + + "left join instance_group on instance_group_vm_map.group_id=instance_group.id " + + "left join data_center on vm_instance.data_center_id=data_center.id " + + "left join host on vm_instance.host_id=host.id " + + "left join vm_template on vm_instance.vm_template_id=vm_template.id " + + "left join user_vm on vm_instance.id=user_vm.id " + + "left join vm_template iso on iso.id=user_vm.iso_id " + + "left join service_offering on vm_instance.service_offering_id=service_offering.id " + + "left join disk_offering on vm_instance.service_offering_id=disk_offering.id " + + "left join volumes on vm_instance.id=volumes.instance_id " + + "left join storage_pool on volumes.pool_id=storage_pool.id " + + "left join security_group_vm_map on vm_instance.id=security_group_vm_map.instance_id " + + "left join security_group on security_group_vm_map.security_group_id=security_group.id " + + "left join nics on vm_instance.id=nics.instance_id " + + "left join networks on nics.network_id=networks.id " + + "left join user_ip_address on user_ip_address.vm_id=vm_instance.id " + + "where vm_instance.id in ("; + + private static final int VM_DETAILS_BATCH_SIZE=100; + + protected final UserVmDetailsDaoImpl _detailsDao = ComponentLocator.inject(UserVmDetailsDaoImpl.class); + protected final NicDaoImpl _nicDao = ComponentLocator.inject(NicDaoImpl.class); + + protected UserVmDaoImpl() { + AccountSearch = createSearchBuilder(); + AccountSearch.and("account", AccountSearch.entity().getAccountId(), SearchCriteria.Op.EQ); + AccountSearch.done(); + + HostSearch = createSearchBuilder(); + HostSearch.and("host", HostSearch.entity().getHostId(), SearchCriteria.Op.EQ); + HostSearch.done(); + + LastHostSearch = createSearchBuilder(); + LastHostSearch.and("lastHost", LastHostSearch.entity().getLastHostId(), SearchCriteria.Op.EQ); + LastHostSearch.and("state", LastHostSearch.entity().getState(), SearchCriteria.Op.EQ); + LastHostSearch.done(); + + HostUpSearch = createSearchBuilder(); + HostUpSearch.and("host", HostUpSearch.entity().getHostId(), SearchCriteria.Op.EQ); + HostUpSearch.and("states", HostUpSearch.entity().getState(), SearchCriteria.Op.NIN); + HostUpSearch.done(); + + HostRunningSearch = createSearchBuilder(); + HostRunningSearch.and("host", HostRunningSearch.entity().getHostId(), SearchCriteria.Op.EQ); + HostRunningSearch.and("state", HostRunningSearch.entity().getState(), SearchCriteria.Op.EQ); + HostRunningSearch.done(); + + AccountPodSearch = createSearchBuilder(); + AccountPodSearch.and("account", AccountPodSearch.entity().getAccountId(), SearchCriteria.Op.EQ); + AccountPodSearch.and("pod", AccountPodSearch.entity().getPodIdToDeployIn(), SearchCriteria.Op.EQ); + AccountPodSearch.done(); + + AccountDataCenterSearch = createSearchBuilder(); + AccountDataCenterSearch.and("account", AccountDataCenterSearch.entity().getAccountId(), SearchCriteria.Op.EQ); + AccountDataCenterSearch.and("dc", AccountDataCenterSearch.entity().getDataCenterIdToDeployIn(), SearchCriteria.Op.EQ); + AccountDataCenterSearch.done(); + + StateChangeSearch = createSearchBuilder(); + StateChangeSearch.and("id", StateChangeSearch.entity().getId(), SearchCriteria.Op.EQ); + StateChangeSearch.and("states", StateChangeSearch.entity().getState(), SearchCriteria.Op.EQ); + StateChangeSearch.and("host", StateChangeSearch.entity().getHostId(), SearchCriteria.Op.EQ); + StateChangeSearch.and("update", StateChangeSearch.entity().getUpdated(), SearchCriteria.Op.EQ); + StateChangeSearch.done(); + + DestroySearch = createSearchBuilder(); + DestroySearch.and("state", DestroySearch.entity().getState(), SearchCriteria.Op.IN); + DestroySearch.and("updateTime", DestroySearch.entity().getUpdateTime(), SearchCriteria.Op.LT); + DestroySearch.done(); + + AccountHostSearch = createSearchBuilder(); + AccountHostSearch.and("accountId", AccountHostSearch.entity().getAccountId(), SearchCriteria.Op.EQ); + AccountHostSearch.and("hostId", AccountHostSearch.entity().getHostId(), SearchCriteria.Op.EQ); + AccountHostSearch.done(); + + CountByAccountPod = createSearchBuilder(Long.class); + CountByAccountPod.select(null, Func.COUNT, null); + CountByAccountPod.and("account", CountByAccountPod.entity().getAccountId(), SearchCriteria.Op.EQ); + CountByAccountPod.and("pod", CountByAccountPod.entity().getPodIdToDeployIn(), SearchCriteria.Op.EQ); + CountByAccountPod.done(); + + CountByAccount = createSearchBuilder(Long.class); + CountByAccount.select(null, Func.COUNT, null); + CountByAccount.and("account", CountByAccount.entity().getAccountId(), SearchCriteria.Op.EQ); + CountByAccount.and("type", CountByAccount.entity().getType(), SearchCriteria.Op.EQ); + CountByAccount.and("state", CountByAccount.entity().getState(), SearchCriteria.Op.NIN); + CountByAccount.done(); + + + SearchBuilder nicSearch = _nicDao.createSearchBuilder(); + nicSearch.and("networkId", nicSearch.entity().getNetworkId(), SearchCriteria.Op.EQ); + nicSearch.and("ip4Address", nicSearch.entity().getIp4Address(), SearchCriteria.Op.NNULL); + + AccountDataCenterVirtualSearch = createSearchBuilder(); + AccountDataCenterVirtualSearch.and("account", AccountDataCenterVirtualSearch.entity().getAccountId(), SearchCriteria.Op.EQ); + AccountDataCenterVirtualSearch.and("dc", AccountDataCenterVirtualSearch.entity().getDataCenterIdToDeployIn(), SearchCriteria.Op.EQ); + AccountDataCenterVirtualSearch.join("nicSearch", nicSearch, AccountDataCenterVirtualSearch.entity().getId(), nicSearch.entity().getInstanceId(), JoinBuilder.JoinType.INNER); + AccountDataCenterVirtualSearch.done(); + + + _updateTimeAttr = _allAttributes.get("updateTime"); + assert _updateTimeAttr != null : "Couldn't get this updateTime attribute"; + } + + @Override + public List listByAccountAndPod(long accountId, long podId) { + SearchCriteria sc = AccountPodSearch.create(); + sc.setParameters("account", accountId); + sc.setParameters("pod", podId); + + return listIncludingRemovedBy(sc); + } + + @Override + public List listByAccountAndDataCenter(long accountId, long dcId) { + SearchCriteria sc = AccountDataCenterSearch.create(); + sc.setParameters("account", accountId); + sc.setParameters("dc", dcId); + + return listIncludingRemovedBy(sc); + } + + @Override + public void updateVM(long id, String displayName, boolean enable, Long osTypeId, String userData) { + UserVmVO vo = createForUpdate(); + vo.setDisplayName(displayName); + vo.setHaEnabled(enable); + vo.setGuestOSId(osTypeId); + vo.setUserData(userData); + update(id, vo); + } + + @Override + public List findDestroyedVms(Date date) { + SearchCriteria sc = DestroySearch.create(); + sc.setParameters("state", State.Destroyed, State.Expunging, State.Error); + sc.setParameters("updateTime", date); + + return listBy(sc); + } + + @Override + public List listByAccountId(long id) { + SearchCriteria sc = AccountSearch.create(); + sc.setParameters("account", id); + return listBy(sc); + } + + @Override + public List listByHostId(Long id) { + SearchCriteria sc = HostSearch.create(); + sc.setParameters("host", id); + + return listBy(sc); + } + + @Override + public List listUpByHostId(Long hostId) { + SearchCriteria sc = HostUpSearch.create(); + sc.setParameters("host", hostId); + sc.setParameters("states", new Object[] {State.Destroyed, State.Stopped, State.Expunging}); + return listBy(sc); + } + + @Override + public List listRunningByHostId(long hostId) { + SearchCriteria sc = HostRunningSearch.create(); + sc.setParameters("host", hostId); + sc.setParameters("state", State.Running); + + return listBy(sc); + } + + @Override + public List listVirtualNetworkInstancesByAcctAndZone(long accountId, long dcId, long networkId) { + + SearchCriteria sc = AccountDataCenterVirtualSearch.create(); + sc.setParameters("account", accountId); + sc.setParameters("dc", dcId); + sc.setJoinParameters("nicSearch", "networkId", networkId); + + return listBy(sc); + } + + @Override + public List listByNetworkIdAndStates(long networkId, State... states) { + if (UserVmSearch == null) { + NicDao _nicDao = ComponentLocator.getLocator("management-server").getDao(NicDao.class); + SearchBuilder nicSearch = _nicDao.createSearchBuilder(); + nicSearch.and("networkId", nicSearch.entity().getNetworkId(), SearchCriteria.Op.EQ); + nicSearch.and("ip4Address", nicSearch.entity().getIp4Address(), SearchCriteria.Op.NNULL); + + UserVmSearch = createSearchBuilder(); + UserVmSearch.and("states", UserVmSearch.entity().getState(), SearchCriteria.Op.IN); + UserVmSearch.join("nicSearch", nicSearch, UserVmSearch.entity().getId(), nicSearch.entity().getInstanceId(), JoinBuilder.JoinType.INNER); + UserVmSearch.done(); + } + + SearchCriteria sc = UserVmSearch.create(); + if (states != null && states.length != 0) { + sc.setParameters("states", (Object[]) states); + } + sc.setJoinParameters("nicSearch", "networkId", networkId); + + return listBy(sc); + } + + @Override + public List listByLastHostId(Long hostId) { + SearchCriteria sc = LastHostSearch.create(); + sc.setParameters("lastHost", hostId); + sc.setParameters("state", State.Stopped); + return listBy(sc); + } + + @Override + public List listByAccountIdAndHostId(long accountId, long hostId) { + SearchCriteria sc = AccountHostSearch.create(); + sc.setParameters("hostId", hostId); + sc.setParameters("accountId", accountId); + return listBy(sc); + } + + @Override + public void loadDetails(UserVmVO vm) { + Map details = _detailsDao.findDetails(vm.getId()); + vm.setDetails(details); + } + + @Override + public void saveDetails(UserVmVO vm) { + Map details = vm.getDetails(); + if (details == null) { + return; + } + _detailsDao.persist(vm.getId(), details); + } + + @Override + public List listPodIdsHavingVmsforAccount(long zoneId, long accountId){ + Transaction txn = Transaction.currentTxn(); + PreparedStatement pstmt = null; + List result = new ArrayList(); + + try { + String sql = LIST_PODS_HAVING_VMS_FOR_ACCOUNT; + pstmt = txn.prepareAutoCloseStatement(sql); + pstmt.setLong(1, zoneId); + pstmt.setLong(2, accountId); + + ResultSet rs = pstmt.executeQuery(); + while (rs.next()) { + result.add(rs.getLong(1)); + } + return result; + } catch (SQLException e) { + throw new CloudRuntimeException("DB Exception on: " + LIST_PODS_HAVING_VMS_FOR_ACCOUNT, e); + } catch (Throwable e) { + throw new CloudRuntimeException("Caught: " + LIST_PODS_HAVING_VMS_FOR_ACCOUNT, e); + } + } + + @Override + public Hashtable listVmDetails(Hashtable userVmDataHash){ + Transaction txn = Transaction.currentTxn(); + PreparedStatement pstmt = null; + + try { + int curr_index=0; + + List userVmDataList = new ArrayList(userVmDataHash.values()); + + if (userVmDataList.size() > VM_DETAILS_BATCH_SIZE){ + pstmt = txn.prepareStatement(VM_DETAILS + getQueryBatchAppender(VM_DETAILS_BATCH_SIZE)); + while ( (curr_index + VM_DETAILS_BATCH_SIZE) <= userVmDataList.size()){ + // set the vars value + for (int k=1,j=curr_index;j 0){ + userVmData.setGroupId(grp_id); + userVmData.setGroup(rs.getString("instance_group.name")); + } + + //"data_center.id, data_center.name, host.id, host.name, vm_template.id, vm_template.name, vm_template.display_text, vm_template.enable_password, + userVmData.setZoneId(rs.getLong("data_center.id")); + userVmData.setZoneName(rs.getString("data_center.name")); + + userVmData.setHostId(rs.getLong("host.id")); + userVmData.setHostName(rs.getString("host.name")); + + long template_id = rs.getLong("vm_template.id"); + if (template_id > 0){ + userVmData.setTemplateId(template_id); + userVmData.setTemplateName(rs.getString("vm_template.name")); + userVmData.setTemplateDisplayText(rs.getString("vm_template.display_text")); + userVmData.setPasswordEnabled(rs.getBoolean("vm_template.enable_password")); + } + else { + userVmData.setTemplateId(-1L); + userVmData.setTemplateName("ISO Boot"); + userVmData.setTemplateDisplayText("ISO Boot"); + userVmData.setPasswordEnabled(false); + } + + long iso_id = rs.getLong("iso.id"); + if (iso_id > 0){ + userVmData.setIsoId(iso_id); + userVmData.setIsoName(rs.getString("iso.name")); + } + + + //service_offering.id, disk_offering.name, " + //"service_offering.cpu, service_offering.speed, service_offering.ram_size, + userVmData.setServiceOfferingId(rs.getLong("service_offering.id")); + userVmData.setServiceOfferingName(rs.getString("disk_offering.name")); + userVmData.setCpuNumber(rs.getInt("service_offering.cpu")); + userVmData.setCpuSpeed(rs.getInt("service_offering.speed")); + userVmData.setMemory(rs.getInt("service_offering.ram_size")); + + // volumes.device_id, volumes.volume_type, + long vol_id = rs.getLong("volumes.id"); + if (vol_id > 0){ + userVmData.setRootDeviceId(rs.getLong("volumes.device_id")); + userVmData.setRootDeviceType(rs.getString("volumes.volume_type")); + // storage pool + long pool_id = rs.getLong("storage_pool.id"); + if (pool_id > 0){ + userVmData.setRootDeviceType(rs.getString("storage_pool.pool_type")); + } + else { + userVmData.setRootDeviceType("Not created"); + } + } + userVmData.setInitialized(); + } + + + Long securityGroupId = rs.getLong("security_group.id"); + if (securityGroupId != null && securityGroupId.longValue() != 0){ + SecurityGroupData resp = userVmData.newSecurityGroupData(); + resp.setId(rs.getLong("security_group.id")); + resp.setName(rs.getString("security_group.name")); + resp.setDescription(rs.getString("security_group.description")); + resp.setObjectName("securitygroup"); + userVmData.addSecurityGroup(resp); + } + + long nic_id = rs.getLong("nics.id"); + if (nic_id > 0){ + NicData nicResponse = userVmData.newNicData(); + nicResponse.setId(nic_id); + nicResponse.setIpaddress(rs.getString("nics.ip4_address")); + nicResponse.setGateway(rs.getString("nics.gateway")); + nicResponse.setNetmask(rs.getString("nics.netmask")); + nicResponse.setNetworkid(rs.getLong("nics.network_id")); + nicResponse.setMacAddress(rs.getString("nics.mac_address")); + + int account_type = rs.getInt("account.type"); + if (account_type == Account.ACCOUNT_TYPE_ADMIN) { + nicResponse.setBroadcastUri(rs.getString("nics.broadcast_uri")); + nicResponse.setIsolationUri(rs.getString("nics.isolation_uri")); + } + + + nicResponse.setTrafficType(rs.getString("networks.traffic_type")); + nicResponse.setType(rs.getString("networks.guest_type")); + nicResponse.setIsDefault(rs.getBoolean("nics.default_nic")); + nicResponse.setObjectName("nic"); + userVmData.addNic(nicResponse); + } + + long publicIpId = rs.getLong("user_ip_address.id"); + if (publicIpId > 0){ + userVmData.setPublicIpId(publicIpId); + userVmData.setPublicIp(rs.getString("user_ip_address.public_ip_address")); + } + + return userVmData; + } + + public String getQueryBatchAppender(int count){ + StringBuilder sb = new StringBuilder(); + for (int i=0;i sc = CountByAccount.create(); + sc.setParameters("account", accountId); + sc.setParameters("type", VirtualMachine.Type.User); + sc.setParameters("state", new Object[] {State.Destroyed, State.Error, State.Expunging}); + return customSearch(sc, null).get(0); + } @Override - public List listByAccountAndPod(long accountId, long podId) { - SearchCriteria sc = AccountPodSearch.create(); - sc.setParameters("account", accountId); - sc.setParameters("pod", podId); - - return listIncludingRemovedBy(sc); - } - - @Override - public List listByAccountAndDataCenter(long accountId, long dcId) { - SearchCriteria sc = AccountDataCenterSearch.create(); - sc.setParameters("account", accountId); - sc.setParameters("dc", dcId); - - return listIncludingRemovedBy(sc); - } - - @Override - public void updateVM(long id, String displayName, boolean enable, Long osTypeId, String userData) { - UserVmVO vo = createForUpdate(); - vo.setDisplayName(displayName); - vo.setHaEnabled(enable); - vo.setGuestOSId(osTypeId); - vo.setUserData(userData); - update(id, vo); - } - - @Override - public List findDestroyedVms(Date date) { - SearchCriteria sc = DestroySearch.create(); - sc.setParameters("state", State.Destroyed, State.Expunging, State.Error); - sc.setParameters("updateTime", date); - - return listBy(sc); - } - - @Override - public List listByAccountId(long id) { - SearchCriteria sc = AccountSearch.create(); - sc.setParameters("account", id); - return listBy(sc); - } - - @Override - public List listByHostId(Long id) { - SearchCriteria sc = HostSearch.create(); - sc.setParameters("host", id); - - return listBy(sc); - } - - @Override - public List listUpByHostId(Long hostId) { - SearchCriteria sc = HostUpSearch.create(); - sc.setParameters("host", hostId); - sc.setParameters("states", new Object[] {State.Destroyed, State.Stopped, State.Expunging}); - return listBy(sc); - } - - @Override - public List listRunningByHostId(long hostId) { - SearchCriteria sc = HostRunningSearch.create(); - sc.setParameters("host", hostId); - sc.setParameters("state", State.Running); - - return listBy(sc); - } - - @Override - public List listVirtualNetworkInstancesByAcctAndZone(long accountId, long dcId, long networkId) { - - SearchCriteria sc = AccountDataCenterVirtualSearch.create(); - sc.setParameters("account", accountId); - sc.setParameters("dc", dcId); - sc.setJoinParameters("nicSearch", "networkId", networkId); - - return listBy(sc); - } - - @Override - public List listByNetworkIdAndStates(long networkId, State... states) { - if (UserVmSearch == null) { - NicDao _nicDao = ComponentLocator.getLocator("management-server").getDao(NicDao.class); - SearchBuilder nicSearch = _nicDao.createSearchBuilder(); - nicSearch.and("networkId", nicSearch.entity().getNetworkId(), SearchCriteria.Op.EQ); - nicSearch.and("ip4Address", nicSearch.entity().getIp4Address(), SearchCriteria.Op.NNULL); - - UserVmSearch = createSearchBuilder(); - UserVmSearch.and("states", UserVmSearch.entity().getState(), SearchCriteria.Op.IN); - UserVmSearch.join("nicSearch", nicSearch, UserVmSearch.entity().getId(), nicSearch.entity().getInstanceId(), JoinBuilder.JoinType.INNER); - UserVmSearch.done(); - } - - SearchCriteria sc = UserVmSearch.create(); - if (states != null && states.length != 0) { - sc.setParameters("states", (Object[]) states); - } - sc.setJoinParameters("nicSearch", "networkId", networkId); - - return listBy(sc); - } - - @Override - public List listByLastHostId(Long hostId) { - SearchCriteria sc = LastHostSearch.create(); - sc.setParameters("lastHost", hostId); - sc.setParameters("state", State.Stopped); - return listBy(sc); - } - - @Override - public List listByAccountIdAndHostId(long accountId, long hostId) { - SearchCriteria sc = AccountHostSearch.create(); - sc.setParameters("hostId", hostId); - sc.setParameters("accountId", accountId); - return listBy(sc); - } - - @Override - public void loadDetails(UserVmVO vm) { - Map details = _detailsDao.findDetails(vm.getId()); - vm.setDetails(details); - } - - @Override - public void saveDetails(UserVmVO vm) { - Map details = vm.getDetails(); - if (details == null) { - return; - } - _detailsDao.persist(vm.getId(), details); - } - - @Override - public List listPodIdsHavingVmsforAccount(long zoneId, long accountId){ - Transaction txn = Transaction.currentTxn(); - PreparedStatement pstmt = null; - List result = new ArrayList(); - - try { - String sql = LIST_PODS_HAVING_VMS_FOR_ACCOUNT; - pstmt = txn.prepareAutoCloseStatement(sql); - pstmt.setLong(1, zoneId); - pstmt.setLong(2, accountId); - - ResultSet rs = pstmt.executeQuery(); - while (rs.next()) { - result.add(rs.getLong(1)); - } - return result; - } catch (SQLException e) { - throw new CloudRuntimeException("DB Exception on: " + LIST_PODS_HAVING_VMS_FOR_ACCOUNT, e); - } catch (Throwable e) { - throw new CloudRuntimeException("Caught: " + LIST_PODS_HAVING_VMS_FOR_ACCOUNT, e); - } - } - - @Override - public Hashtable listVmDetails(Hashtable userVmDataHash){ + public boolean remove(Long id) { Transaction txn = Transaction.currentTxn(); - PreparedStatement pstmt = null; - - try { - int curr_index=0; - - List userVmDataList = new ArrayList(userVmDataHash.values()); - - if (userVmDataList.size() > VM_DETAILS_BATCH_SIZE){ - pstmt = txn.prepareStatement(VM_DETAILS + getQueryBatchAppender(VM_DETAILS_BATCH_SIZE)); - while ( (curr_index + VM_DETAILS_BATCH_SIZE) <= userVmDataList.size()){ - // set the vars value - for (int k=1,j=curr_index;j 0){ - userVmData.setGroupId(grp_id); - userVmData.setGroup(rs.getString("instance_group.name")); - } - - //"data_center.id, data_center.name, host.id, host.name, vm_template.id, vm_template.name, vm_template.display_text, vm_template.enable_password, - userVmData.setZoneId(rs.getLong("data_center.id")); - userVmData.setZoneName(rs.getString("data_center.name")); - - userVmData.setHostId(rs.getLong("host.id")); - userVmData.setHostName(rs.getString("host.name")); - - long template_id = rs.getLong("vm_template.id"); - if (template_id > 0){ - userVmData.setTemplateId(template_id); - userVmData.setTemplateName(rs.getString("vm_template.name")); - userVmData.setTemplateDisplayText(rs.getString("vm_template.display_text")); - userVmData.setPasswordEnabled(rs.getBoolean("vm_template.enable_password")); - } - else { - userVmData.setTemplateId(-1L); - userVmData.setTemplateName("ISO Boot"); - userVmData.setTemplateDisplayText("ISO Boot"); - userVmData.setPasswordEnabled(false); - } - - long iso_id = rs.getLong("iso.id"); - if (iso_id > 0){ - userVmData.setIsoId(iso_id); - userVmData.setIsoName(rs.getString("iso.name")); - } - - - //service_offering.id, disk_offering.name, " - //"service_offering.cpu, service_offering.speed, service_offering.ram_size, - userVmData.setServiceOfferingId(rs.getLong("service_offering.id")); - userVmData.setServiceOfferingName(rs.getString("disk_offering.name")); - userVmData.setCpuNumber(rs.getInt("service_offering.cpu")); - userVmData.setCpuSpeed(rs.getInt("service_offering.speed")); - userVmData.setMemory(rs.getInt("service_offering.ram_size")); - - // volumes.device_id, volumes.volume_type, - long vol_id = rs.getLong("volumes.id"); - if (vol_id > 0){ - userVmData.setRootDeviceId(rs.getLong("volumes.device_id")); - userVmData.setRootDeviceType(rs.getString("volumes.volume_type")); - // storage pool - long pool_id = rs.getLong("storage_pool.id"); - if (pool_id > 0){ - userVmData.setRootDeviceType(rs.getString("storage_pool.pool_type")); - } - else { - userVmData.setRootDeviceType("Not created"); - } - } - userVmData.setInitialized(); - } - - - Long securityGroupId = rs.getLong("security_group.id"); - if (securityGroupId != null && securityGroupId.longValue() != 0){ - SecurityGroupData resp = userVmData.newSecurityGroupData(); - resp.setId(rs.getLong("security_group.id")); - resp.setName(rs.getString("security_group.name")); - resp.setDescription(rs.getString("security_group.description")); - resp.setObjectName("securitygroup"); - userVmData.addSecurityGroup(resp); - } - - long nic_id = rs.getLong("nics.id"); - if (nic_id > 0){ - NicData nicResponse = userVmData.newNicData(); - nicResponse.setId(nic_id); - nicResponse.setIpaddress(rs.getString("nics.ip4_address")); - nicResponse.setGateway(rs.getString("nics.gateway")); - nicResponse.setNetmask(rs.getString("nics.netmask")); - nicResponse.setNetworkid(rs.getLong("nics.network_id")); - nicResponse.setMacAddress(rs.getString("nics.mac_address")); - - int account_type = rs.getInt("account.type"); - if (account_type == Account.ACCOUNT_TYPE_ADMIN) { - nicResponse.setBroadcastUri(rs.getString("nics.broadcast_uri")); - nicResponse.setIsolationUri(rs.getString("nics.isolation_uri")); - } - - - nicResponse.setTrafficType(rs.getString("networks.traffic_type")); - nicResponse.setType(rs.getString("networks.guest_type")); - nicResponse.setIsDefault(rs.getBoolean("nics.default_nic")); - nicResponse.setObjectName("nic"); - userVmData.addNic(nicResponse); - } - - long publicIpId = rs.getLong("user_ip_address.id"); - if (publicIpId > 0){ - userVmData.setPublicIpId(publicIpId); - userVmData.setPublicIp(rs.getString("user_ip_address.public_ip_address")); - } - - return userVmData; - } - - public String getQueryBatchAppender(int count){ - StringBuilder sb = new StringBuilder(); - for (int i=0;i sc = CountByAccount.create(); - sc.setParameters("account", accountId); - sc.setParameters("type", VirtualMachine.Type.User); - sc.setParameters("state", new Object[] {State.Destroyed, State.Error, State.Expunging}); - return customSearch(sc, null).get(0); - } - - -} + txn.start(); + _tagsDao.removeByIdAndType(id, TaggedResourceType.UserVm); + boolean result = super.remove(id); + txn.commit(); + return result; + } + +} diff --git a/server/src/com/cloud/vm/dao/VMInstanceDaoImpl.java b/server/src/com/cloud/vm/dao/VMInstanceDaoImpl.java index 0975f7f77a4..8de2f941f62 100644 --- a/server/src/com/cloud/vm/dao/VMInstanceDaoImpl.java +++ b/server/src/com/cloud/vm/dao/VMInstanceDaoImpl.java @@ -32,9 +32,12 @@ import org.apache.log4j.Logger; import com.cloud.host.HostVO; import com.cloud.host.dao.HostDaoImpl; +import com.cloud.server.ResourceTag.TaggedResourceType; +import com.cloud.tags.dao.ResourceTagsDaoImpl; import com.cloud.utils.Pair; import com.cloud.utils.component.ComponentLocator; import com.cloud.utils.db.Attribute; +import com.cloud.utils.db.DB; import com.cloud.utils.db.GenericDaoBase; import com.cloud.utils.db.GenericSearchBuilder; import com.cloud.utils.db.JoinBuilder; @@ -75,6 +78,7 @@ public class VMInstanceDaoImpl extends GenericDaoBase implem protected GenericSearchBuilder CountRunningByHost; protected GenericSearchBuilder CountRunningByAccount; protected SearchBuilder NetworkTypeSearch; + ResourceTagsDaoImpl _tagsDao = ComponentLocator.inject(ResourceTagsDaoImpl.class); protected final Attribute _updateTimeAttr; @@ -549,4 +553,18 @@ public class VMInstanceDaoImpl extends GenericDaoBase implem return listBy(sc); } + + @Override + @DB + public boolean remove(Long id) { + Transaction txn = Transaction.currentTxn(); + txn.start(); + VMInstanceVO vm = findById(id); + if (vm != null && vm.getType() == Type.User) { + _tagsDao.removeByIdAndType(id, TaggedResourceType.UserVm); + } + boolean result = super.remove(id); + txn.commit(); + return result; + } } diff --git a/server/test/com/cloud/vm/MockUserVmManagerImpl.java b/server/test/com/cloud/vm/MockUserVmManagerImpl.java index 54ba1f8cb4c..5241eb216a6 100644 --- a/server/test/com/cloud/vm/MockUserVmManagerImpl.java +++ b/server/test/com/cloud/vm/MockUserVmManagerImpl.java @@ -189,7 +189,7 @@ public class MockUserVmManagerImpl implements UserVmManager, UserVmService, Mana } @Override - public List searchForUserVMs(Criteria c, Account caller, Long domainId, boolean isRecursive, List permittedAccounts, boolean listAll, ListProjectResourcesCriteria listProjectResourcesCriteria) { + public List searchForUserVMs(Criteria c, Account caller, Long domainId, boolean isRecursive, List permittedAccounts, boolean listAll, ListProjectResourcesCriteria listProjectResourcesCriteria, Map tags) { // TODO Auto-generated method stub return null; } diff --git a/setup/db/create-schema.sql b/setup/db/create-schema.sql index 72e40b38e25..e36934081fd 100755 --- a/setup/db/create-schema.sql +++ b/setup/db/create-schema.sql @@ -2307,6 +2307,7 @@ CREATE TABLE `cloud`.`resource_tags` ( `key` varchar(255), `value` varchar(255), `resource_id` bigint unsigned NOT NULL, + `resource_uuid` varchar(40), `resource_type` varchar(255), `customer` varchar(255), `domain_id` bigint unsigned NOT NULL COMMENT 'foreign key to domain id', @@ -2314,7 +2315,9 @@ CREATE TABLE `cloud`.`resource_tags` ( PRIMARY KEY (`id`), CONSTRAINT `fk_tags__account_id` FOREIGN KEY(`account_id`) REFERENCES `account`(`id`), CONSTRAINT `fk_tags__domain_id` FOREIGN KEY(`domain_id`) REFERENCES `domain`(`id`), - UNIQUE `i_tags__resource_id__resource_type__key`(`resource_id`, `resource_type`, `key`) + UNIQUE `i_tags__resource_id__resource_type__key`(`resource_id`, `resource_type`, `key`), + CONSTRAINT `uc_resource_tags__uuid` UNIQUE (`uuid`), + CONSTRAINT `uc_resource_tags__resource_uuid` UNIQUE (`resource_uuid`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; diff --git a/setup/db/deploy-db-clouddev.sh b/setup/db/deploy-db-clouddev.sh index df2a38a7d40..4aa544ba81e 100644 --- a/setup/db/deploy-db-clouddev.sh +++ b/setup/db/deploy-db-clouddev.sh @@ -21,3 +21,23 @@ mysql --user=cloud --password=cloud < clouddev.sql if [ $? -ne 0 ]; then printf "failed to init cloudev db" fi +mysql --user=cloud -t cloud --password=cloud -e "insert into configuration (name, value) VALUES('consoleproxy.static.publicip', \"$1\")" +mysql --user=cloud -t cloud --password=cloud -e "insert into configuration (name, value) VALUES('consoleproxy.static.port', \"$2\")" + +vmids=`xe vm-list is-control-domain=false |grep uuid|awk '{print $5}'` +for vm in $vmids + do + echo $vm + xe vm-shutdown uuid=$vm + xe vm-destroy uuid=$vm + done + +vdis=`xe vdi-list |grep ^uuid |awk '{print $5}'` +for vdi in $vdis + do + xe vdi-destroy uuid=$vdi + if [ $? -gt 0 ];then + xe vdi-forget uuid=$vdi + fi + + done diff --git a/tools/bugs-wiki/search-bugs.py b/tools/bugs-wiki/search-bugs.py index 074401fa511..302e383c4d0 100755 --- a/tools/bugs-wiki/search-bugs.py +++ b/tools/bugs-wiki/search-bugs.py @@ -1,4 +1,20 @@ #!/usr/bin/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 imp import os diff --git a/tools/bugs-wiki/search-wiki.py b/tools/bugs-wiki/search-wiki.py index 8d7c26f3ba1..03e145973ac 100755 --- a/tools/bugs-wiki/search-wiki.py +++ b/tools/bugs-wiki/search-wiki.py @@ -1,4 +1,20 @@ #!/usr/bin/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 imp import os diff --git a/tools/devcloud/devcloudsetup.sh b/tools/devcloud/devcloudsetup.sh new file mode 100644 index 00000000000..8ae3908c8c9 --- /dev/null +++ b/tools/devcloud/devcloudsetup.sh @@ -0,0 +1,136 @@ +#!/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. + +fileSvr="http://nfs1.lab.vmops.com/templates/devcloud/" +install_xen() { + aptitude update + echo "install xen" + aptitude -y install linux-headers-3.2.0-23-generic-pae + aptitude -y install xen-hypervisor-4.1 xcp-xapi + echo "configure xen" + + sed -i -e 's/xend_start$/#xend_start/' -e 's/xend_stop$/#xend_stop/' /etc/init.d/xend + update-rc.d xendomains disable + + sed -i 's/GRUB_DEFAULT=.\+/GRUB_DEFAULT="Xen 4.1-amd64"/' /etc/default/grub + update-grub + + mkdir /usr/share/qemu + ln -s /usr/share/qemu-linaro/keymaps /usr/share/qemu/keymaps + +cat > /etc/network/interfaces << EOF +# The loopback network interface +auto lo +iface lo inet loopback + +# The primary network interface +auto xenbr0 +iface xenbr0 inet dhcp + gateway 10.0.2.2 + bridge_ports eth0 + + +auto eth0 +iface eth0 inet dhcp +EOF + + echo TOOLSTACK=xapi > /etc/default/xen + echo bridge > /etc/xcp/network.conf + + echo "reboot" + reboot +} + +postsetup() { + #check xen dom0 is working + xe host-list > /dev/null + if [ $? -gt 0 ]; then + print "xen dom0 is not running, make sure dom0 is installed" + exit 1 + fi + + echo "configure NFS server" + aptitude -y install nfs-server + if [ ! -d /opt/storage/secondary ];then + mkdir -p /opt/storage/secondary + mkdir -p /opt/storage/secondary/template/tmpl/1/1 + mkdir -p /opt/storage/secondary/template/tmpl/1/5 + + echo "/opt/storage/secondary *(rw,no_subtree_check,no_root_squash,fsid=0)" > /etc/exports + wget $fileSvr/vmtemplates/1/dc68eb4c-228c-4a78-84fa-b80ae178fbfd.vhd -P /opt/storage/secondary/template/tmpl/1/1/ + wget $fileSvr/vmtemplates/1/template.properties -P /opt/storage/secondary/template/tmpl/1/1/ + wget $fileSvr/vmtemplates/5/ce5b212e-215a-3461-94fb-814a635b2215.vhd -P /opt/storage/secondary/template/tmpl/1/5/ + wget $fileSvr/vmtemplates/5/template.properties -P /opt/storage/secondary/template/tmpl/1/5/ + /etc/init.d/nfs-kernel-server restart + fi + + echo "configure local storage" + if [ ! -d /opt/storage/primary ]; then + mkdir -p /opt/storage/primary + hostuuid=`xe host-list |grep uuid|awk '{print $5}'` + xe sr-create host-uuid=$hostuuid name-label=local-storage shared=false type=file device-config:location=/opt/storage/primary + fi + + echo "generate ssh key" + ssh-keygen -A -q + + echo "configure xcp" + wget $fileSvr/echo -P /usr/lib/xcp/plugins/ + chmod -R 777 /usr/lib/xcp + + sed -i 's/VNCTERM_LISTEN=.\+/VNCTERM_LISTEN="-v 0.0.0.0:1"/' /usr/lib/xcp/lib/vncterm-wrapper + + echo "install cloudstack " + + if [ ! -d /opt/cloudstack ];then + aptitude -y install git unzip openjdk-6-jdk mysql-server ant + mkdir /opt/cloudstack + cd /opt/cloudstack + git clone https://git-wip-us.apache.org/repos/asf/incubator-cloudstack.git + mkdir incubator-cloudstack/target + mkdir incubator-cloudstack/dist + wget http://archive.apache.org/dist/tomcat/tomcat-6/v6.0.32/bin/apache-tomcat-6.0.32.zip -P /opt/cloudstack/ + unzip apache-tomcat-6.0.32.zip + echo "exportCATALINA_HOME=/opt/cloudstack/apache-tomcat-6.0.32" >> /root/.bashrc + cd ~ + fi + + echo "devCloud is ready to use" +} +usage() { + print "$0 -p: presetup enviroment, e.g. install xen, configure xcp etc" + print "$0 -P: postsetup, install cloudstack, prepare template etc" +} + +while getopts "pP" OPTION +do + case $OPTION in + p) + install_xen + exit 0 + ;; + P) + postsetup + exit 0 + ;; + ?) + usage + exit + ;; + esac +done diff --git a/tools/marvin/LICENSE.txt b/tools/marvin/LICENSE.txt index fa64b4a85d0..00ae6c00d2e 100644 --- a/tools/marvin/LICENSE.txt +++ b/tools/marvin/LICENSE.txt @@ -1,9 +1,17 @@ -Copyright 2012 Citrix Systems, Inc. Licensed under the Apache License, Version -2.0 (the "License"); you may not use this file except in compliance with the -License. Citrix Systems, Inc. reserves all rights not expressly granted by 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. +# 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. + diff --git a/tools/marvin/marvin/NoseTestExecuteEngine.py b/tools/marvin/marvin/NoseTestExecuteEngine.py index 8ad34bb91ae..ca1afb4f528 100644 --- a/tools/marvin/marvin/NoseTestExecuteEngine.py +++ b/tools/marvin/marvin/NoseTestExecuteEngine.py @@ -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. + from functools import partial import unittest import nose diff --git a/tools/marvin/marvin/TestCaseExecuteEngine.py b/tools/marvin/marvin/TestCaseExecuteEngine.py index 67ed14a6aab..79089ab41d7 100644 --- a/tools/marvin/marvin/TestCaseExecuteEngine.py +++ b/tools/marvin/marvin/TestCaseExecuteEngine.py @@ -1,15 +1,19 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 unittest import xmlrunner @@ -87,4 +91,4 @@ class TestCaseExecuteEngine(object): if self.format == "text": unittest.TextTestRunner(stream=self.testResultLogFile, verbosity=2).run(self.suite) elif self.format == "xml": - xmlrunner.XMLTestRunner(output=self.testResultLogFile, verbose=True).run(self.suite) \ No newline at end of file + xmlrunner.XMLTestRunner(output=self.testResultLogFile, verbose=True).run(self.suite) diff --git a/tools/marvin/marvin/asyncJobMgr.py b/tools/marvin/marvin/asyncJobMgr.py index 0b4499bb645..935bebe4d7a 100644 --- a/tools/marvin/marvin/asyncJobMgr.py +++ b/tools/marvin/marvin/asyncJobMgr.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 threading import cloudstackException import time diff --git a/tools/marvin/marvin/cloudstackConnection.py b/tools/marvin/marvin/cloudstackConnection.py index b72e54c3c10..37919c082fe 100644 --- a/tools/marvin/marvin/cloudstackConnection.py +++ b/tools/marvin/marvin/cloudstackConnection.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 urllib2 import urllib import base64 diff --git a/tools/marvin/marvin/cloudstackException.py b/tools/marvin/marvin/cloudstackException.py index c8640975481..17a06cc9d99 100644 --- a/tools/marvin/marvin/cloudstackException.py +++ b/tools/marvin/marvin/cloudstackException.py @@ -1,15 +1,19 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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. class cloudstackAPIException(Exception): def __init__(self, cmd = "", result = ""): @@ -33,4 +37,4 @@ class internalError(Exception): def __init__(self, msg=''): self.errorMsg = msg def __str__(self): - return self.errorMsg \ No newline at end of file + return self.errorMsg diff --git a/tools/marvin/marvin/cloudstackTestCase.py b/tools/marvin/marvin/cloudstackTestCase.py index e4ff2d19339..a85eef7e1dd 100644 --- a/tools/marvin/marvin/cloudstackTestCase.py +++ b/tools/marvin/marvin/cloudstackTestCase.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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. + from cloudstackAPI import * import unittest import cloudstackTestClient diff --git a/tools/marvin/marvin/cloudstackTestClient.py b/tools/marvin/marvin/cloudstackTestClient.py index a67f2347aa3..2bf14a00386 100644 --- a/tools/marvin/marvin/cloudstackTestClient.py +++ b/tools/marvin/marvin/cloudstackTestClient.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 cloudstackConnection import asyncJobMgr import dbConnection @@ -150,4 +155,4 @@ class cloudstackTestClient(object): def submitJobs(self, jobs, nums_threads=10, interval=1): if self.asyncJobMgr is None: self.asyncJobMgr = asyncJobMgr.asyncJobMgr(self.apiClient, self.dbConnection) - self.asyncJobMgr.submitJobs(jobs, nums_threads, interval) \ No newline at end of file + self.asyncJobMgr.submitJobs(jobs, nums_threads, interval) diff --git a/tools/marvin/marvin/codegenerator.py b/tools/marvin/marvin/codegenerator.py index c7190577096..370fa9ed67b 100644 --- a/tools/marvin/marvin/codegenerator.py +++ b/tools/marvin/marvin/codegenerator.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 xml.dom.minidom from optparse import OptionParser import os diff --git a/tools/marvin/marvin/configGenerator.py b/tools/marvin/marvin/configGenerator.py index 60526a89f8a..ad323ca5ecf 100644 --- a/tools/marvin/marvin/configGenerator.py +++ b/tools/marvin/marvin/configGenerator.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 json import os from optparse import OptionParser diff --git a/tools/marvin/marvin/dbConnection.py b/tools/marvin/marvin/dbConnection.py index afe5be58695..1992f801428 100644 --- a/tools/marvin/marvin/dbConnection.py +++ b/tools/marvin/marvin/dbConnection.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 pymysql import cloudstackException import sys diff --git a/tools/marvin/marvin/deployAndRun.py b/tools/marvin/marvin/deployAndRun.py index e7d9e6120b2..80d74e4b63e 100644 --- a/tools/marvin/marvin/deployAndRun.py +++ b/tools/marvin/marvin/deployAndRun.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 deployDataCenter import TestCaseExecuteEngine import NoseTestExecuteEngine diff --git a/tools/marvin/marvin/deployDataCenter.py b/tools/marvin/marvin/deployDataCenter.py index d4838072432..91045cd741f 100644 --- a/tools/marvin/marvin/deployDataCenter.py +++ b/tools/marvin/marvin/deployDataCenter.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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. + """Deploy datacenters according to a json configuration file""" import configGenerator import cloudstackException diff --git a/tools/marvin/marvin/jsonHelper.py b/tools/marvin/marvin/jsonHelper.py index aa817b7883b..b2e7d2ff7dc 100644 --- a/tools/marvin/marvin/jsonHelper.py +++ b/tools/marvin/marvin/jsonHelper.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 cloudstackException import json import inspect diff --git a/tools/marvin/marvin/remoteSSHClient.py b/tools/marvin/marvin/remoteSSHClient.py index 4063b33fc72..60df2a744d7 100644 --- a/tools/marvin/marvin/remoteSSHClient.py +++ b/tools/marvin/marvin/remoteSSHClient.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 paramiko import time import cloudstackException @@ -66,4 +71,4 @@ class remoteSSHClient(object): if __name__ == "__main__": ssh = remoteSSHClient("192.168.137.2", 22, "root", "password") print ssh.execute("ls -l") - print ssh.execute("rm x") \ No newline at end of file + print ssh.execute("rm x") diff --git a/tools/marvin/marvin/sandbox/demo/live/testSshDeployVM.py b/tools/marvin/marvin/sandbox/demo/live/testSshDeployVM.py index 63728eff1d3..5438e40d6c8 100644 --- a/tools/marvin/marvin/sandbox/demo/live/testSshDeployVM.py +++ b/tools/marvin/marvin/sandbox/demo/live/testSshDeployVM.py @@ -1,16 +1,20 @@ #!/usr/bin/env python -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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. diff --git a/tools/marvin/marvin/sandbox/demo/simulator/simulator_setup.py b/tools/marvin/marvin/sandbox/demo/simulator/simulator_setup.py index ee800761df9..0b9c01da9f4 100644 --- a/tools/marvin/marvin/sandbox/demo/simulator/simulator_setup.py +++ b/tools/marvin/marvin/sandbox/demo/simulator/simulator_setup.py @@ -1,4 +1,21 @@ #!/usr/bin/env 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. + from ConfigParser import SafeConfigParser from optparse import OptionParser diff --git a/tools/marvin/marvin/sandbox/demo/simulator/testcase/libs/base.py b/tools/marvin/marvin/sandbox/demo/simulator/testcase/libs/base.py index e2fd5d74c81..0b5da5c162f 100644 --- a/tools/marvin/marvin/sandbox/demo/simulator/testcase/libs/base.py +++ b/tools/marvin/marvin/sandbox/demo/simulator/testcase/libs/base.py @@ -1,7 +1,20 @@ # -*- encoding: utf-8 -*- -# -# Copyright (c) 2012 Citrix. All rights reserved. -# +# 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. """ Base class for all Cloudstack resources -Virtual machine, Volume, Snapshot etc diff --git a/tools/marvin/marvin/sandbox/demo/simulator/testcase/libs/common.py b/tools/marvin/marvin/sandbox/demo/simulator/testcase/libs/common.py index 5b2b096743e..fc184016d43 100644 --- a/tools/marvin/marvin/sandbox/demo/simulator/testcase/libs/common.py +++ b/tools/marvin/marvin/sandbox/demo/simulator/testcase/libs/common.py @@ -1,7 +1,20 @@ # -*- encoding: utf-8 -*- -# -# Copyright (c) 2012 Citrix. All rights reserved. -# +# 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. """Common functions """ @@ -444,4 +457,4 @@ def list_resource_limits(apiclient, **kwargs): cmd = listResourceLimits.listResourceLimitsCmd() [setattr(cmd, k, v) for k, v in kwargs.items()] - return(apiclient.listResourceLimits(cmd)) \ No newline at end of file + return(apiclient.listResourceLimits(cmd)) diff --git a/tools/marvin/marvin/sandbox/demo/simulator/testcase/libs/utils.py b/tools/marvin/marvin/sandbox/demo/simulator/testcase/libs/utils.py index 69d524deea0..8abed18b99d 100644 --- a/tools/marvin/marvin/sandbox/demo/simulator/testcase/libs/utils.py +++ b/tools/marvin/marvin/sandbox/demo/simulator/testcase/libs/utils.py @@ -1,7 +1,20 @@ # -*- encoding: utf-8 -*- -# -# Copyright (c) 2012 Citrix. All rights reserved. -# +# 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. """Utilities functions """ diff --git a/tools/marvin/marvin/sandbox/demo/simulator/testcase/test_vm_life_cycle.py b/tools/marvin/marvin/sandbox/demo/simulator/testcase/test_vm_life_cycle.py index 176f4ae870f..9bc7e149f97 100644 --- a/tools/marvin/marvin/sandbox/demo/simulator/testcase/test_vm_life_cycle.py +++ b/tools/marvin/marvin/sandbox/demo/simulator/testcase/test_vm_life_cycle.py @@ -1,16 +1,21 @@ # -*- encoding: utf-8 -*- -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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. + """ BVT tests for Virtual Machine Life Cycle """ #Import Local Modules diff --git a/tools/marvin/setup.py b/tools/marvin/setup.py index af40771d6a4..b2d6a40cd4b 100644 --- a/tools/marvin/setup.py +++ b/tools/marvin/setup.py @@ -1,7 +1,20 @@ #!/usr/bin/env python -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. +# 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. from distutils.core import setup from sys import version diff --git a/tools/test/apisession.py b/tools/test/apisession.py index 85414f80334..bdeae53a501 100644 --- a/tools/test/apisession.py +++ b/tools/test/apisession.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 cookielib import hashlib import json diff --git a/tools/test/cloudkit.py b/tools/test/cloudkit.py index 41a7273c3b9..02dd68c1da9 100644 --- a/tools/test/cloudkit.py +++ b/tools/test/cloudkit.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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. + from apisession import ApiSession from physicalresource import ZoneCreator from globalconfig import GlobalConfig diff --git a/tools/test/db.py b/tools/test/db.py index 57e6cd1185f..2a3d3cfad26 100644 --- a/tools/test/db.py +++ b/tools/test/db.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 MySQLdb class Database: diff --git a/tools/test/globalconfig.py b/tools/test/globalconfig.py index c431e1c4876..7a5d0fd6dfa 100644 --- a/tools/test/globalconfig.py +++ b/tools/test/globalconfig.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 json import os import random diff --git a/tools/test/physicalresource.py b/tools/test/physicalresource.py index 64a2834f0ea..57767f69d85 100644 --- a/tools/test/physicalresource.py +++ b/tools/test/physicalresource.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 json import os import random diff --git a/tools/test/vm.py b/tools/test/vm.py index a419a4d8243..434e1967fd6 100644 --- a/tools/test/vm.py +++ b/tools/test/vm.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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 json import os import random diff --git a/tools/test/vmcreate.py b/tools/test/vmcreate.py index c3b0a7814e2..f220581271d 100644 --- a/tools/test/vmcreate.py +++ b/tools/test/vmcreate.py @@ -1,15 +1,20 @@ -# Copyright 2012 Citrix Systems, Inc. Licensed under the -# Apache License, Version 2.0 (the "License"); you may not use this -# file except in compliance with the License. Citrix Systems, Inc. -# reserves all rights not expressly granted by 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. +# 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 # -# Automatically generated by addcopyright.py at 04/03/2012 +# 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. + from apisession import ApiSession from vm import VMCreator diff --git a/utils/src/com/cloud/utils/ssh/SshHelper.java b/utils/src/com/cloud/utils/ssh/SshHelper.java index f29b368cbe5..dca7acb0ab9 100755 --- a/utils/src/com/cloud/utils/ssh/SshHelper.java +++ b/utils/src/com/cloud/utils/ssh/SshHelper.java @@ -1,15 +1,20 @@ -// Copyright 2012 Citrix Systems, Inc. Licensed under the -// Apache License, Version 2.0 (the "License"); you may not use this -// file except in compliance with the License. Citrix Systems, Inc. -// reserves all rights not expressly granted by 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. -// -// Automatically generated by addcopyright.py at 04/03/2012 +// 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. +// package com.cloud.utils.ssh; import java.io.File;