core: Disable unit test

- Disabled DocsServlet unit test as they are giving trouble during
jenkins job.

Change-Id: Iab18612d463cc5fe1270aca6a81bad60e6fa8595
Signed-off-by: Alexander Wels <awels@redhat.com>
Modify error to info report after fencing and fixing print

Change-Id: I9411c286b20f6e0627d5699ca8ea294e443cf6ae
Signed-off-by: Yaniv Bronhaim <ybronhei@redhat.com>
cleanup: desktops are always supported in search

The distinction of servers-only has been removed a while back.
only calls to search with 'false' for desktops are actually in the unitests.

Change-Id: Ib5f89927643a71025302a897c175257018fda000
Signed-off-by: Itamar Heim <iheim@redhat.com>
webadmin: Auto update quota by template

In the VM popup - when a template is selected, update the quota to the
quota of the selected template.

Change-Id: Ia1d70b895738218e551128c73415a1cbd33e8915
Bug-Url: https://bugzilla.redhat.com/924928
Signed-off-by: Ofri Masad <omasad@redhat.com>
core: Removed AddVmFromSnapshot.canLockSnapshot()

Removed the method and inlined the check together with the other
snapshot validations.

Change-Id: Ic0baad35bfaf24ae534676a24a6abc63d7853c23
Signed-off-by: Vered Volansky <vvolansk@redhat.com>
root: use %{x} notation instead of ${x} in web.xml

rhel jboss, at least 7.1.3-4, perform unconditional properties ${x}
substitutions in web.xml, while fedora jboss at least 7.1.1-9.3, does
not.

a solution for rhel jboss is to use $${x}, while this solution is not
working for fedora jboss.

to allow common processing and future migration to other application
server the notation was changed to %{x}.

Related-Change-Id: I94f845d36bb075c238e50606187bc22316713cdd
Change-Id: I115118e6f46ac74bc882949e101bbe3d04e29684
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
core: Fix build break

Fixed the build break introduced by
4d77dd453e011796542cc64c2c391171631b2e7e

Change-Id: Ic90b9f909c47301a3dea464e8a46cb887ad8c114
Signed-off-by: Allon Mureinik <amureini@redhat.com>
packaging: nothing was left in conf to ovirt-engine

move last file to backend.

Change-Id: I5813d6846ff8e16d32c805a6ca35546449a42830
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
findbugs: equals between different types

Change-Id: I125e5df8def7a223f9469decc7aa43dab61f4a47
Signed-off-by: Shahar Havivi <shavivi@redhat.com>
packaging: modify enigne.conf.d setup files prefix

previously we used '50-' prefix, however there is no reason for setup
default to be loaded so late in change, so now it was modified to
'10-' prefix.

clean all configuration files when engine-clean is executed to avoid
leftovers.

Change-Id: I173faede1f39b87a14ede05c04e0ab4da7e8e5d3
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
pki: fix engine-upgrade config creation

Change-Id: I9af1bbb2be895f4d77d9a060454b72109bb5a382
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
core: fix disk image json serialization/deserialization

Change-Id: Id40ef08ea341e6abf2bd5e6e815bb79814141c20
Signed-off-by: Liron Aravot <laravot@redhat.com>
core: remove vm - remove VM during execute

When removing vm the operation is done as synchronized operation, task
is created for each disk and then the vm is removed from db.
In order to deal with engine crash, in the end method a roll forward is
performed in case that the vm still exists (the vm is being deleted and
it's disks are being marked as illegal).
This logic is unneeded and can cause to a bug, in case of deleted vm and
imported vm with the same id, this can cause that the imported vm would
be
deleted from the db as the deletion tasks would end - therefore this
logic is being removed.

this patch contains the following changes:
1. the first step is to remove the vm, lock all the disks - in case of
failure they will be in ILLEGAL status.
2. added a boolean member indicating whether RemoveImage should lock the
image.
3. RemoveAllVmImages shouldn't fail in case of failure to create a task
for deletion, the engine should continue and try to delete the other
images- this change also prevents a storage leak in removing vm and
templates from export domains.
4. RemoveAllVmImages returns a list of disks it failed to remove,
instead of querying the db again.

Change-Id: I7a3e497e52471f7255e6c17b59a2e3bf362b8783
Signed-off-by: Liron Aravot <laravot@redhat.com>
Signed-off-by: Allon Mureinik <amureini@redhat.com>
packaging: engine-service: protect configuration files

we need to protect configuration files as database password resides
within.

for some reason jboss changes the permissions of configuration file and
deployment to 0777, enforcing umask of 0027 perform some remedy at the
price of having logs not world readable as well, so it is not a
solution.

luckily, jboss does not modify the directory in which configuration file
resides, so we split the configuration directory to own directory and
set proper permissions.

Change-Id: Ie76e5ffcdccd8c3a0bedbb9ce9bd56e146eeccd9
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
packaging: Updated DB validation flow.

This patch is an addition to http://gerrit.ovirt.org/#/c/14389.

It updates the parameters handling in encodingvalidator
utility. Also, it updates calling the validation utilities
with an admin user (postgres) instead of engine.

Change-Id: I34c87815bd667d80f3691ae4a2533523bfa89f29
Bug-Url: https://bugzilla.redhat.com/920565
Signed-off-by: Alex Lourie <alourie@redhat.com>