Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

Commit

Permalink
Merge remote-tracking branch 'origin/master' into mazz/wip
Browse files Browse the repository at this point in the history
Conflicts:
	pom.xml
  • Loading branch information
jmazzitelli committed May 27, 2015
2 parents 632125d + 346e1b6 commit e98706b
Show file tree
Hide file tree
Showing 41 changed files with 1,927 additions and 999 deletions.
7 changes: 4 additions & 3 deletions README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ Sub-projects are currently:
* https://github.com/hawkular/hawkular-metrics[Hawkular-metrics]: metric storage and retrieval engine
* https://github.com/hawkular/hawkular-bus[Hawkular-bus]: asynchronous bus to connect the various parts
* https://github.com/hawkular/hawkular-alerts[Hawkular-alerts]: alerting on events.
* Hawkular UI
** https://github.com/hawkular/hawkular-ui-components[Hawkular-ui-components]: ui components such as https://github.com/hawtio/hawtio/blob/master/docs/Overview2dotX.md[Hawt.io 2] plugins and Angular directives that make up the _Hawkular Console_
* Hawkular UI Console (a https://github.com/hawtio[hawt.io 2 plugin])
** https://github.com/hawkular/hawkular-ui-services[Hawkular-ui-services]: common services and ngResource wrappers for Hawkular REST Apis.
** https://github.com/hawkular/hawkular-charts[Hawkular-charts]: Charts and other Angular visualization components used to graphically render data in _Hawkular._
* https://github.com/hawkular/hawkular-build-tools[Hawkular build tools]: Helpers and definitions to build Hawkular
Expand Down Expand Up @@ -39,7 +38,9 @@ Once those steps are achieved, .zip and .tgz archives will be available in `dist

TIP: If you build with `mvn install -Pdev` an uncompressed directory will be created in `dist/target`.
A default user will be created, the username is `jdoe` and the password is `password`. This can be convenient
when you are working on the project as you won't have to unzip/untar and register a new user.
when you are working on the project as you won't have to unzip/untar and register a new user. The uncompressed directory
can be found in 'dist/target/hawkular-1.0.0-SNAPSHOT/wildfly-8.2.0.Final/' and run with 'bin/standalone.sh' as normally
starting a WildFly server.

Please have a look at the
http://www.hawkular.org/docs/dev/development.html[developer documentation] for more information
Expand Down
6 changes: 6 additions & 0 deletions dist/assembly.xml
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,12 @@
<filtered>true</filtered>
<destName>hawkular-realm.json</destName>
</file>
<file>
<source>src/main/resources/configuration/hawkular-realm-for-dev.json</source>
<outputDirectory>${wildfly.dist.zip.root.dir}/standalone/configuration/</outputDirectory>
<filtered>true</filtered>
<destName>hawkular-realm-for-dev.json</destName>
</file>
</files>

</assembly>
Expand Down
2 changes: 1 addition & 1 deletion dist/docker/README.adoc
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
== Build the Kettle Docker image
Make sure you are in hawkular/kettle directory
Make sure you are in hawkular/dist directory
[source,shell]
----
mvn package docker:build
Expand Down
7 changes: 5 additions & 2 deletions dist/src/main/resources/wildfly/patches/standalone.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,9 @@
<!-- add system properties -->
<xsl:template name="system-properties">
<system-properties>
<property name="hawkular-metrics.backend" value="embedded_cass" />
<xsl:text disable-output-escaping="yes">
&lt;property name="hawkular-metrics.backend" value="${hawkular-metrics.backend:embedded_cass}" /&gt;
</xsl:text>
</system-properties>
</xsl:template>

Expand Down Expand Up @@ -735,7 +737,8 @@
<web-context>auth</web-context>
</auth-server>
<realm name="hawkular">
<auth-server-url>http://localhost:8080/auth</auth-server-url>
<auth-server-url>/auth</auth-server-url>
<auth-server-url-for-backend-requests>http://localhost:8080/auth</auth-server-url-for-backend-requests>
<ssl-required>none</ssl-required>
</realm>
<secure-deployment name="hawkular-accounts.war">
Expand Down
105 changes: 100 additions & 5 deletions modules/end-to-end-test/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,15 @@
limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.hawkular</groupId>
<artifactId>hawkular</artifactId>
<version>1.0.0-SNAPSHOT</version>
<relativePath>../../pom.xml</relativePath>
</parent>

<artifactId>hawkular-end-to-end-tests</artifactId>
Expand All @@ -36,11 +36,14 @@
<dependency>
<groupId>org.hawkular.inventory</groupId>
<artifactId>inventory-api</artifactId>
<scope>test</scope>
</dependency>


<dependency>
<groupId>org.rhq.metrics</groupId>
<artifactId>rhq-metrics-api</artifactId>
<groupId>org.jboss.resteasy</groupId>
<artifactId>resteasy-client</artifactId>
<scope>test</scope>
</dependency>

<dependency>
Expand All @@ -58,9 +61,101 @@
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>

</dependencies>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<!-- because integration tests are run by maven-failsafe-plugin -->
<skip>true</skip>
</configuration>
</plugin>
</plugins>
</build>

<profiles>
<profile>
<id>itest</id>
<properties>
<hawkular.host>localhost</hawkular.host>
<hawkular.port>8080</hawkular.port>
<hawkular.path>/hawkular</hawkular.path>
<hawkular.base-uri>http://${hawkular.host}:${hawkular.port}${hawkular.path}</hawkular.base-uri>
<hawkular.management.port>9999</hawkular.management.port>
</properties>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<configuration>
<includes>
<include>**/*ITest*</include>
</includes>
<systemPropertyVariables>
<hawkular.host>${hawkular.host}</hawkular.host>
<hawkular.port>${hawkular.port}</hawkular.port>
<hawkular.base-uri>${hawkular.base-uri}</hawkular.base-uri>
</systemPropertyVariables>
</configuration>
<executions>
<execution>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- prepared for HAWKULAR-257 Run end to end tests by Travis
<plugin>
<groupId>org.wildfly.plugins</groupId>
<artifactId>wildfly-maven-plugin</artifactId>
<configuration>
<groupId>org.hawkular</groupId>
<artifactId>hawkular-dist</artifactId>
<version>${project.version}</version>
<skip>${skipTests}</skip>
<startupTimeout>240</startupTimeout>
</configuration>
<executions>
<execution>
<id>start-wildfly</id>
<phase>pre-integration-test</phase>
<configuration>
<javaOpts>
<javaOpt>-server</javaOpt>
<javaOpt>-Xms64m</javaOpt>
<javaOpt>-Xmx512m</javaOpt>
<javaOpt>-XX:MaxPermSize=256m</javaOpt>
<javaOpt>-Djava.net.preferIPv4Stack=true</javaOpt>
<javaOpt>-Djboss.modules.system.pkgs=org.jboss.byteman </javaOpt>
<javaOpt>-Djava.awt.headless=true </javaOpt>
<javaOpt>-Dkeycloak.import=/home/ppalaga/scratch/hawkular-master/wildFly/standalone/configuration/hawkular-realm.json</javaOpt>
</javaOpts>
</configuration>
<goals>
<goal>start</goal>
</goals>
</execution>
<execution>
<id>stop-wildfly</id>
<phase>post-integration-test</phase>
<goals>
<goal>shutdown</goal>
</goals>
</execution>
</executions>
</plugin> -->
</plugins>
</build>
</profile>
</profiles>

</project>
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,31 @@ package org.hawkular.integration.test

import groovyx.net.http.ContentType
import groovyx.net.http.RESTClient

import org.junit.BeforeClass

class AbstractTestBase {

static baseURI = System.getProperty('hawkular.base-uri') ?: '127.0.0.1:8080/hawkular/'
static testUser = 'jdoe'
static testPasword = 'password'
static baseURI = 'http://localhost:8080'
//static baseURI = System.getProperty('hawkular.base-uri') ?: 'http://localhost:8080/hawkular'
static RESTClient client

@BeforeClass
static void initClient() {
client = new RESTClient("http://$baseURI", ContentType.JSON)
client = new RESTClient(baseURI, ContentType.JSON)

/* http://en.wikipedia.org/wiki/Basic_access_authentication#Client_side :
* The Authorization header is constructed as follows:
* * Username and password are combined into a string "username:password"
* * The resulting string is then encoded using the RFC2045-MIME variant of Base64,
* except not limited to 76 char/line[9]
* * The authorization method and a space i.e. "Basic " is then put before the encoded string.
*/
String encodedCredentials = Base64.getMimeEncoder().encodeToString("$testUser:$testPasword".getBytes("utf-8"))
client.defaultRequestHeaders.Authorization = "Basic "+ encodedCredentials

}

}

This file was deleted.

0 comments on commit e98706b

Please sign in to comment.