1. 18 Sep, 2013 1 commit
  2. 17 Sep, 2013 3 commits
    • Kostas Papadimitriou's avatar
      helpdesk: Exclude nics of deleted vms · 2e66630b
      Kostas Papadimitriou authored
      when helpdesk users search using ip address
      2e66630b
    • Christos Stavrakakis's avatar
      cyclades: Mock vm removal if creation fails · a2daae31
      Christos Stavrakakis authored
      In case creating a VM fails before the OP_INSTANCE_CREATE job is
      enqueued in Ganeti, the VM and its NICs must be deleted, and the
      resources must be released from Quotaholder, which is exactly what is
      done when a VM is deleted from Ganeti. Instead of duplicating the code,
      this commit uses the same function that is used by snf-dispatcher, by
      mocking an successfully OP_INSTANCE_REMOVE.
      a2daae31
    • Christos Stavrakakis's avatar
      cyclades: Fix bug during server creation · baae8e7f
      Christos Stavrakakis authored
      Commit #32a0b85, modified server creation, by refetching the object from
      DB after issuing commission to quotaholder. However, the new object is
      not having the 'config_url' attributed, which is added to the vm object
      by the 'vmapi'. This commit, fixes this by moving the signal dispatching
      code after refetching the vm. Also, this commit makes more clear the
      exception handling code, when the creation job can not be enqueued to
      Ganeti.
      baae8e7f
  3. 16 Sep, 2013 2 commits
  4. 13 Sep, 2013 1 commit
  5. 12 Sep, 2013 3 commits
    • Giorgos Korfiatis's avatar
      cyclades: Do not save stale objects after a commit · 9b94fc30
      Giorgos Korfiatis authored
      Call to issue_and_accept_commission saves the resource object (eg a vm)
      and commits the transaction. This has the side-effect that the resource
      object becomes stale: its lock is released and another thread may acquire
      it and update the db record. It is thus not safe to further update and then
      save the stale object, since this would override others' changes. Instead,
      lock and fetch the object again, where needed.
      9b94fc30
    • Giorgos Korfiatis's avatar
      cyclades: Do not release resources if already deleted · 8101def7
      Giorgos Korfiatis authored
      Ensure that a commission to release vm resources is issued only once.
      If a vm is marked `deleted', then resources must have already been
      released.
      8101def7
    • Giorgos Korfiatis's avatar
      common: Strip trailing slash from endpoints · 31d98e59
      Giorgos Korfiatis authored
      Remove trailing slash from the endpoints' publicURL field in service
      definitions. These values end up in the response of POST /tokens, and,
      according to the keystone API, should not end in slash. A trailing slash
      breaks some clients, which do no proper checking before appending a
      suffix.
      
      Note that these URLs are not meant to act as a base path in the strict
      semantics of http://tools.ietf.org/html/rfc3986#section-5.2.3 . Suffixes
      should be merged into by a simple append (modulo catering for the joining
      slash).
      
      URLs are still configured as groups per prefix ending in a slash, eg:
      '^account/' and '^ui/'. Permanent redirects are added for all non-API
      endpoints (ui, helpdesk, admin, etc), so that `BASE_PATH/path' leads to
      `BASE_PATH/path/'.
      31d98e59
  6. 11 Sep, 2013 1 commit
  7. 06 Sep, 2013 1 commit
    • Christos Stavrakakis's avatar
      cyclades: Fix bug in snf-dispatcher logic · a399119b
      Christos Stavrakakis authored
      This commit reverts commits #07602322 and #30514662 which introduced a
      bug in dispatcher's logic. These commit fixed the issue that, in a case
      the Cyclades DB is unsynced with Ganeti, a resource that does not exist
      in the Ganeti backend, it  will not be deleted from DB in case the
      remove job fails.
      
      This commits fixes this issue, by quering Ganeti each time a failed
      OP_INSTANCE_REMOVE or OP_NETWORK_REMOVE is processed.
      a399119b
  8. 30 Aug, 2013 1 commit
  9. 19 Jul, 2013 1 commit
  10. 12 Jul, 2013 1 commit
    • Kostas Papadimitriou's avatar
      cyclades ui: Prefer os meta to identify connection user · faa25f0f
      Kostas Papadimitriou authored
      How vm connection user gets resolved:
      
      - Use the last user in `users` vm metadata if exists
      - Use the last user in `users` vm image metadata if exists
      - Use root if vm's image osfamily metadata is Linux
      - Use Administrator if vm's image osfamily metadata is windows
      faa25f0f
  11. 11 Jul, 2013 2 commits
  12. 08 Jul, 2013 2 commits
  13. 04 Jul, 2013 1 commit
  14. 03 Jul, 2013 2 commits
  15. 02 Jul, 2013 1 commit
    • Christos Stavrakakis's avatar
      cyclades: Wrap diagnostic creation in transaction · 6f159c83
      Christos Stavrakakis authored
      Fix bug in snf-dispatcher causing wrong updates of VMs from ganeti.
      Creation if instance diagnostics must run inside a transaction, because
      otherwise, the lock of the vm (select_for_update) is released too early.
      Specifally, 'if_update_required' takes a lock on the VM and checks if
      the timestamp of the message is newer than the one in the VM. If
      diagnostic creation ('create_instance_diagnostic' function) does not run
      inside a transaction, the lock is released when the diagnostic row is
      inserted in the DB. However, after storing the diagnostic, the VM is
      saved in order to update the 'updated' timestamp (otherwise,
      MODIFIED_SINCE does not work correctly). In the meantime, another
      message may update the VM, and this update will be lost. This commit
      wrap 'create_instance_diagnostic' inside transaction to fix this issue.
      6f159c83
  16. 28 Jun, 2013 2 commits
  17. 25 Jun, 2013 2 commits
  18. 21 Jun, 2013 1 commit
    • Christos Stavrakakis's avatar
      cyclades: Fix bug in allocating archipelago VMs · 81df9113
      Christos Stavrakakis authored
      This commit fixes a bug that caused backend allocator to send
      archipelago VMs backends to backends not in ARCHIPELAGO_BACKENDS
      setting. The flavor disk template is parsed before the backend
      allocation, so the disk_template at this point is ext and not ext_vlmc,
      as it was expected.
      81df9113
  19. 19 Jun, 2013 4 commits
  20. 18 Jun, 2013 2 commits
  21. 17 Jun, 2013 6 commits