@RequiresSession
  public StackEntity findById(long stackId) {
    return entityManagerProvider.get().find(StackEntity.class, stackId);
  }
Gets a stack with the specified ID.

@param stackId
         the ID of the stack to retrieve.
@return the stack or {@code null} if none exists.
ambari-server/src/main/java/org/apache/ambari/server/orm/dao/StackDAO.java