stack_advisor.py 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. #!/usr/bin/env ambari-python-wrap
  2. """
  3. Licensed to the Apache Software Foundation (ASF) under one
  4. or more contributor license agreements. See the NOTICE file
  5. distributed with this work for additional information
  6. regarding copyright ownership. The ASF licenses this file
  7. to you under the Apache License, Version 2.0 (the
  8. "License"); you may not use this file except in compliance
  9. with the License. You may obtain a copy of the License at
  10. http://www.apache.org/licenses/LICENSE-2.0
  11. Unless required by applicable law or agreed to in writing, software
  12. distributed under the License is distributed on an "AS IS" BASIS,
  13. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  14. See the License for the specific language governing permissions and
  15. limitations under the License.
  16. """
  17. class StackAdvisor(object):
  18. def recommendComponentLayout(self, services, hosts):
  19. """Returns Services object with hostnames array populated for components"""
  20. pass
  21. def validateComponentLayout(self, services, hosts):
  22. """Returns array of Validation objects about issues with hostnames components assigned to"""
  23. pass
  24. def recommendConfigurations(self, services, hosts):
  25. """Returns Services object with configurations object populated"""
  26. pass
  27. def validateConfigurations(self, services, hosts):
  28. """Returns array of Validation objects about issues with configuration values provided in services"""
  29. pass