[1144459] [eap6] Warnings in agent.log - Required property 'manage' and 'delete-durable-queue' have a null value
An issue in the plugin descriptor resulted in an ill-defined configuration
definition for the 'Role' "list of maps".  Fixing the descriptor should
resolve the issue when resource config is rediscovered for an existing
resource.  New resources should be fine from the start.

Also, fix an issue in the config editor when rendering a lot of property
fields. Something that showed up after the all of the properties started
showing up.

The lesson here? Listen to your log file warnings :)
[BZ 1136998] Fix the logic in the upgrade delegate.

It now better distinguishes between configuration values coming from a
previous upgrade report in the chain versus the values coming from
the existing resource.

Being aware of the distinction is needed for a correct decision on what
value should the "supportsPatching" attribute set to.
[BZ 1114199] Make sure data expiration is consistent for late data

Raw data has a retention of 7 days. Previously if we inserted late data that
was a day old, you might expect that it would expire in 6 days; however, the
data actually expire in 7 days. This is because the TTL and column timestamp
cannot be bind variables in Cassandra 1.2.x prepared statements. This commit
fixes the problem so that the one day old data will expire in 6 days. This
is accomplished without sacrificing the use of preared statements.

A cache of prepared statements is now used. Theere is one statement for each
of the past 7 days including today. For data that is 2 days old, we will insert
using a prepared statement that has a column timestamp of today minus 2 days,
and the data will expire in 5 days.

An EJB timer tasks runs every day at 12:00 AM to remove the oldest statements
from the caches and add a new statement for tomorrow. We store an extra
prepared statement for tomorrow to deal with scenarios where data is stored
right at midnight.
[BZ 1114199] do not update insert statement caches more than once in a day
Bug 1038317 - Use of remote client API results in error/warning messages regarding indirectly referenced JPA annotations not being resolvable

Added Hibernate Core (for CascadeType enum) and Hibernate JPA Annotations to the CLI distribution

Tested with the wiki remote API example https://docs.jboss.org/author/display/RHQ/Java+Client+Sample+Class
(Only 1 warning remains at compilation, because the sample class uses a deprecated method from the Remote API)
[BZ 1069547] Fix AS7 plugin itests.

The itests run with EAP 6.1.1 that does not support patching so I
added an exception to the rule of non-null metrics in the itest.
Merge pull request #129 from tsegismont/bug/1038317

Bug 1038317 - Use of remote client API results in error/warning messages...
[1144998] List of errors and warnings in server.log after upgrade to 3.3.0.ER03
Add EAP-level log filters for messages we can't avoid and don't want to see.
Revert "[BZ 1114199] do not update insert statement caches more than once in a day"

This reverts commit 47d9a23404e4b57b971546052f231ec188694225.
Revert "[BZ 1114199] Make sure data expiration is consistent for late data"

This reverts commit ba64f2134a51b7e0cbd445032da95d7381b590ce.
[BZ 1075575] Update C* dependency to a JBoss specific version that has the OpenJDK warning removed.
[BZ 1114199] fix handling of late data

My previous commits that involved setting the column timestamp on inserts had
to be reverted. When aggregating late data, it is possible to end up with a
clock tie (See https://wiki.apache.org/cassandra/FAQ#clocktie for details). In
those situations the columns might not get overwritten.

The key thing is to ensure that we do not try to recompute aggregate metrics
when some or all of the source data has already expired, leading to new,
incorrect data. I have put changes in place that should prevent this from
happening.

This commit also includes a change to IndexIterator. It will now continue
loading pages if there is a read timeout. Previously, the exception would go
uncaught causing data aggregation to abort early.
Bug 1074633 - RFE: Manage storage node snapshots

Fix NPE that occured in
org.rhq.enterprise.server.discovery.DiscoveryBossBeanTest.testAutoImportStorageNode
Bug 1125423 - Fuse Fabric Groups Plugin cannot be enabled

Generally when there is an attempt to enable server plugins we now first
check it's configuration by looking for required properties (in ConfigDef)
and making sure there's valid value in configuration. If something is
missing, it means plugin is not configured and cannot be enabled.
ServerPluginManagerBean thows this using
PluginConfigurationRequiredException that is then presented to user.
Bug 1077744 - statement timeout during drift purge job

Changed the query WHERE clause: don't use NOT IN because NOT IN(NULL) will always return false.
See http://stackoverflow.com/questions/17150208/sql-query-with-not-in-returning-no-rows

In other words, if any row in RHQ_DRIFT as a NULL value in OLD_DRIFT_FILE or NEW_DRIFT_FILE columns, we'll never purge anything.

Besides, the NOT EXISTS variant has a better execution plan.

Use PurgeTemplate to delete rows in batches and select the keys of the rows to delete without locking the drift files table.

Also, some code cleanup.
[BZ 1083894] - Storage node's cluster status "NORMAL" written in RED cannot be changed - Adding a way to our UI to explicitly reset error message and last failed operation on the rhq_storage_node table.
[BZ 1070277] - (JON3-39) JON should (be able to) block login to a user without roles - adding it to the db-upgrade.xml also using lower case in sysconfig-data.xml
Bug 1144489 - [BRMS 6] The original product type discovered for this server
was EAP, but the server is now reporting its product type is [BRMS]

Adding BRMS into set of known AS7 based products
Bug 1146611 - Cannot discover EAP6.0.1: supportsMatching method fails with IllegalArgumentException

EAP 6.1.0 version.txt file content is: "JBoss Enterprise Application Platform - Version 6.0.1 GA"
As a consequence, the version detected will be "6.0.1 GA" (notice the space instead of a dot)

Give such version strings a chance to make a valid OSGiVersion instance (avoid IllegalArgumentException)

If the version is still not matching the expected pattern, then supportsPatching default to false

Also:
* some perf improvements:
** use already compiled PATTERN instead of recompiling on each call of String#split or String.replaceAll
** use some OSGiVersion constants to avoid parsing over and over again
* some code cleanup (no longer use deprecated methods, remove unused param in private method, unchecked warning)
Revert "Bug 1146611 - Cannot discover EAP6.0.1: supportsMatching method fails with IllegalArgumentException"

This reverts commit b95683ae6366745f53923c8d8d4c2d88cf21e17c.

Master broken...