Added quick test class and log conf
This commit is contained in:
parent
53b46a72a1
commit
352c4ae2b9
|
@ -0,0 +1,19 @@
|
||||||
|
package org.gcube.event.publisher;
|
||||||
|
|
||||||
|
import java.net.MalformedURLException;
|
||||||
|
import java.net.URL;
|
||||||
|
|
||||||
|
public class HTTPEventSenderTest {
|
||||||
|
|
||||||
|
public HTTPEventSenderTest() {
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void main(String[] args) throws MalformedURLException {
|
||||||
|
// HTTPEventSender sender = new HTTPEventSender(null, "lr62_portal", "28726d01-9f24-4ef4-a057-3d208d96aaa0",
|
||||||
|
// new URL("https://nubis2.int.d4science.net/auth/realms/d4science/protocol/openid-connect/token"));
|
||||||
|
new Thread(new HTTPEventSender(null, null, null, null).new HTTPost(new URL("https://nubis1.int.d4science.net/api/workflow/startup"),
|
||||||
|
"{\"sender\":\"gcube\",\"name\":\"startup\",\"ids\":\"20154\",\"type\":\"portal\",\"uuid\":\"474be056-365f-4b2c-9519-b9614299b09a\",\"timestamp\":\"2020-06-25T13:08:10.673Z\"}"))
|
||||||
|
.start();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,27 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8" ?>
|
||||||
|
<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
|
||||||
|
<log4j:configuration
|
||||||
|
xmlns="http://jakarta.apache.org/log4j/"
|
||||||
|
xmlns:log4j="http://jakarta.apache.org/log4j/">
|
||||||
|
|
||||||
|
<appender name="console"
|
||||||
|
class="org.apache.log4j.ConsoleAppender">
|
||||||
|
<layout class="org.apache.log4j.PatternLayout">
|
||||||
|
<param name="ConversionPattern"
|
||||||
|
value="%d{yyyy-MM-dd HH:mm:ss} %-5p %c{1}:%L - %m%n" />
|
||||||
|
</layout>
|
||||||
|
</appender>
|
||||||
|
<logger name="org.gcube" additivity="false">
|
||||||
|
<level value="TRACE" />
|
||||||
|
<appender-ref ref="console" />
|
||||||
|
</logger>
|
||||||
|
<logger name="org.jboss" additivity="false">
|
||||||
|
<level value="INFO" />
|
||||||
|
<appender-ref ref="console" />
|
||||||
|
</logger>
|
||||||
|
<root>
|
||||||
|
<level value="TRACE" />
|
||||||
|
<appender-ref ref="console" />
|
||||||
|
</root>
|
||||||
|
|
||||||
|
</log4j:configuration>
|
Loading…
Reference in New Issue