events = query.getResultList();
+ em.close();
+
+ for (LogEvent event : events) {
+ LogItem item = new LogItem();
+ item.setPath(event.getPath());
+ item.setDate(event.getDate());
+ item.setDescription(event.getDescription());
+ item.setType(LogEnum.valueOf(event.getLogType()));
+ item.setSession(session);
+ logItems.add(item);
+ }
+
+ return logItems;
+ }
+}
diff --git a/ace-am/src/main/java/edu/umiacs/ace/monitor/reporting/ManageReporterServlet.java b/ace-am/src/main/java/edu/umiacs/ace/monitor/reporting/ManageReporterServlet.java
new file mode 100644
index 0000000000000000000000000000000000000000..0797b79685ad1ff620c8fec4ce1810da196d7649
--- /dev/null
+++ b/ace-am/src/main/java/edu/umiacs/ace/monitor/reporting/ManageReporterServlet.java
@@ -0,0 +1,114 @@
+package edu.umiacs.ace.monitor.reporting;
+
+import edu.umiacs.ace.monitor.core.Collection;
+import edu.umiacs.ace.util.EntityManagerServlet;
+import edu.umiacs.util.Strings;
+import org.apache.log4j.Logger;
+
+import javax.persistence.EntityManager;
+import javax.persistence.EntityTransaction;
+import javax.persistence.TypedQuery;
+import javax.servlet.RequestDispatcher;
+import javax.servlet.ServletException;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import java.io.IOException;
+import java.util.List;
+import java.util.Map;
+import java.util.stream.Collectors;
+
+/**
+ * Servlet to manage Reporters attached to a collection
+ *
+ * Used for adding and remove plugins I guess
+ *
+ * Created by shake on 6/17/16.
+ */
+public class ManageReporterServlet extends EntityManagerServlet {
+
+ private static final Logger LOG = Logger.getLogger(ManageReporterServlet.class);
+
+ private static final String PARAM_CLASS = "class"; // class name of our plugin
+ private static final String PARAM_REMOVE = "remove"; // long internal id of relation
+
+
+ @Override
+ protected void processRequest(HttpServletRequest request, HttpServletResponse response, EntityManager em) throws ServletException, IOException {
+ Collection coll = getCollection(request, em);
+ String namedClass = request.getParameter(PARAM_CLASS);
+ String remove = request.getParameter(PARAM_REMOVE);
+
+ RequestDispatcher dispatcher;
+ if (coll == null) {
+ LOG.trace("No collection to process for managing reporter plugins");
+ dispatcher = request.getRequestDispatcher("Status");
+ } else {
+ // Begin our transaction
+ dispatcher = request.getRequestDispatcher("ManageCollection?collectionid=" + coll.getId());
+ EntityTransaction transaction = em.getTransaction();
+ transaction.begin();
+
+ if (!Strings.isEmpty(remove)) { // request to remove a plugin
+ remove(coll, remove, em);
+ } else if (!Strings.isEmpty(namedClass)) { // request to add a plugin
+ save(coll, namedClass, request, em);
+ } else { // GET on /ManageReporter
+ dispatcher = request.getRequestDispatcher("configure_reporting.jsp?collectionid=" + coll.getId());
+ // Don't really like this.. but... it will do for now I suppose
+ List reporters = ReporterContextListener.reporters.stream()
+ .filter(r -> !coll.getReportPlugins().contains(
+ // create a report plugin to check against
+ new ReportPlugin()
+ .setNamedClass(r.getName())
+ .setParent(coll)))
+ .collect(Collectors.toList());
+ request.setAttribute("reporters", reporters);
+ }
+
+ transaction.commit();
+ }
+
+ dispatcher.forward(request, response);
+ }
+
+ private void remove(Collection coll, String remove, EntityManager em) {
+ Map settings = coll.getSettings();
+ List plugins = coll.getReportPlugins();
+
+ TypedQuery query = em.createNamedQuery("ReportPlugin.selectByCollectionAndName", ReportPlugin.class);
+ query.setParameter("coll", coll);
+ query.setParameter("named", remove);
+
+ // Find our plugin and remove it
+ ReportPlugin plugin = query.getSingleResult();
+ em.remove(plugin);
+
+ // Remove the plugin settings from the collection
+ ReporterContextListener.Plugin rcl = ReporterContextListener.map.get(remove);
+ rcl.getSettings().forEach(settings::remove);
+ plugins.remove(plugin);
+ em.merge(coll);
+ }
+
+ private void save(Collection coll, String namedClass, HttpServletRequest request, EntityManager em) {
+ Map settings = coll.getSettings();
+ List plugins = coll.getReportPlugins();
+
+ ReportPlugin savedPlugin = new ReportPlugin();
+ savedPlugin.setNamedClass(namedClass);
+ savedPlugin.setParent(coll);
+ plugins.add(savedPlugin);
+ // Create an instance of our class
+ ReporterContextListener.Plugin plugin = ReporterContextListener.map.get(namedClass);
+ for (String param : plugin.getSettings()) {
+ String pluginSetting = request.getParameter(param);
+ LOG.trace("Adding " + param + " with val " + pluginSetting);
+ settings.put(param, pluginSetting);
+ }
+
+ em.persist(savedPlugin);
+ em.merge(coll);
+ }
+
+
+}
diff --git a/ace-am/src/main/java/edu/umiacs/ace/monitor/reporting/ReportPlugin.java b/ace-am/src/main/java/edu/umiacs/ace/monitor/reporting/ReportPlugin.java
new file mode 100644
index 0000000000000000000000000000000000000000..97ab2ed4f0ca41eef22b6557e67c95a4b27e4876
--- /dev/null
+++ b/ace-am/src/main/java/edu/umiacs/ace/monitor/reporting/ReportPlugin.java
@@ -0,0 +1,83 @@
+package edu.umiacs.ace.monitor.reporting;
+
+import edu.umiacs.ace.monitor.core.Collection;
+
+import javax.persistence.Column;
+import javax.persistence.Entity;
+import javax.persistence.GeneratedValue;
+import javax.persistence.GenerationType;
+import javax.persistence.Id;
+import javax.persistence.ManyToOne;
+import javax.persistence.NamedQueries;
+import javax.persistence.NamedQuery;
+import javax.persistence.Table;
+import java.io.Serializable;
+
+/**
+ *
+ * Created by shake on 6/20/16.
+ */
+@Entity
+@Table(name = "report_plugin")
+@NamedQueries({
+ @NamedQuery(name = "ReportPlugin.deleteByCollection", query =
+ "DELETE FROM ReportPlugin WHERE parent = :coll"),
+ @NamedQuery(name = "ReportPlugin.selectByCollectionAndName", query =
+ "SELECT p FROM ReportPlugin p WHERE p.parent = :coll AND p.namedClass = :named")
+})
+public class ReportPlugin implements Serializable {
+
+ @Id
+ @GeneratedValue(strategy = GenerationType.IDENTITY)
+ private Long id;
+
+ @ManyToOne
+ private Collection parent;
+ private String namedClass;
+
+ public Long getId() {
+ return id;
+ }
+
+ public ReportPlugin setId(Long id) {
+ this.id = id;
+ return this;
+ }
+
+ public Collection getParent() {
+ return parent;
+ }
+
+ public ReportPlugin setParent(Collection parent) {
+ this.parent = parent;
+ return this;
+ }
+
+ public String getNamedClass() {
+ return namedClass;
+ }
+
+ public ReportPlugin setNamedClass(String namedClass) {
+ this.namedClass = namedClass;
+ return this;
+ }
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) return true;
+ if (o == null || getClass() != o.getClass()) return false;
+
+ ReportPlugin that = (ReportPlugin) o;
+
+ if (!parent.equals(that.parent)) return false;
+ return namedClass.equals(that.namedClass);
+
+ }
+
+ @Override
+ public int hashCode() {
+ int result = parent.hashCode();
+ result = 31 * result + namedClass.hashCode();
+ return result;
+ }
+}
diff --git a/ace-am/src/main/java/edu/umiacs/ace/monitor/reporting/ReporterContextListener.java b/ace-am/src/main/java/edu/umiacs/ace/monitor/reporting/ReporterContextListener.java
new file mode 100644
index 0000000000000000000000000000000000000000..fac5b69ea2c446d179711068a3e20df91e254574
--- /dev/null
+++ b/ace-am/src/main/java/edu/umiacs/ace/monitor/reporting/ReporterContextListener.java
@@ -0,0 +1,86 @@
+package edu.umiacs.ace.monitor.reporting;
+
+import com.google.common.collect.ImmutableMap;
+import edu.umiacs.ace.am.Reporter;
+import io.github.lukehutch.fastclasspathscanner.FastClasspathScanner;
+import org.apache.log4j.Logger;
+
+import javax.servlet.ServletContextEvent;
+import javax.servlet.ServletContextListener;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+/**
+ *
+ * Created by shake on 6/16/16.
+ */
+public class ReporterContextListener implements ServletContextListener {
+ private static final Logger log = Logger.getLogger(ReporterContextListener.class);
+
+ public static Map map;
+ static List reporters;
+ private static final String PAGE_REPORTERS = "reporters";
+
+ @Override
+ public void contextInitialized(ServletContextEvent servletContextEvent) {
+ reporters = new ArrayList<>();
+ Map tempMap = new HashMap<>();
+
+ new FastClasspathScanner()
+ .matchClassesImplementing(Reporter.class, c -> {
+ Plugin plugin = new Plugin(c);
+ tempMap.put(c.getSimpleName(), plugin);
+ reporters.add(plugin);
+ })
+ .scan();
+
+ log.info("Found " + reporters.size() + " reporting classes: " + reporters.toString());
+
+ map = ImmutableMap.copyOf(tempMap);
+ }
+
+ @Override
+ public void contextDestroyed(ServletContextEvent servletContextEvent) {
+ reporters.clear();
+ }
+
+ public static class Plugin {
+ private Class extends Reporter> clazz;
+
+ Plugin(Class extends Reporter> clazz) {
+ this.clazz = clazz;
+ }
+
+ public Class extends Reporter> heldClass() {
+ return clazz;
+ }
+
+ public String getLongName() {
+ return this.clazz.getName();
+ }
+
+ public String getName() {
+ return clazz.getSimpleName();
+ }
+
+ public List getSettings() {
+ log.trace("Retrieving settings for " + getName());
+ List settings = new ArrayList<>();
+
+ try {
+ // log.trace("clazz classloader: " + clazz.getClassLoader());
+ // log.trace("Reporter classloader: " + Reporter.class.getClassLoader());
+ Reporter reporter = Reporter.class.cast(clazz.newInstance());
+ settings = reporter.settings();
+ log.trace("Found " + settings.size() + " settings");
+ } catch (InstantiationException | IllegalAccessException e) {
+ log.error("could not instantiate class " + clazz, e);
+ }
+
+ return settings;
+ }
+ }
+
+}
diff --git a/ace-am/src/main/java/edu/umiacs/ace/monitor/reporting/SMTPReporter.java b/ace-am/src/main/java/edu/umiacs/ace/monitor/reporting/SMTPReporter.java
new file mode 100644
index 0000000000000000000000000000000000000000..204f869a8cb8e18f0137bf461b8c83ce00638422
--- /dev/null
+++ b/ace-am/src/main/java/edu/umiacs/ace/monitor/reporting/SMTPReporter.java
@@ -0,0 +1,162 @@
+package edu.umiacs.ace.monitor.reporting;
+
+import com.google.common.collect.ImmutableList;
+import edu.umiacs.ace.am.LogEnum;
+import edu.umiacs.ace.am.LogItem;
+import edu.umiacs.ace.am.Report;
+import edu.umiacs.ace.am.Reporter;
+import org.apache.log4j.Logger;
+
+import javax.mail.Message;
+import javax.mail.MessagingException;
+import javax.mail.Session;
+import javax.mail.Transport;
+import javax.mail.internet.InternetAddress;
+import javax.mail.internet.MimeMessage;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Properties;
+
+/**
+ * Class which makes smtp class after an audit has finished
+ *
+ * Created by shake on 6/13/16.
+ */
+public class SMTPReporter implements Reporter {
+
+ private static final Logger LOG = Logger.getLogger(SMTPReporter.class);
+
+ private final String RECIPIENTS_KEY = "smtp.recipients";
+
+ private String recipients;
+ private Map> grouped = new HashMap<>();
+
+ @Override
+ public void init(Map settings) {
+ recipients = settings.get(RECIPIENTS_KEY);
+ }
+
+ @Override
+ public List settings() {
+ return ImmutableList.of(RECIPIENTS_KEY);
+ }
+
+ @Override
+ public void report(Report report) {
+ groupLogEntries(report);
+ String body = createBody(report);
+ try {
+ send(body);
+ } catch (MessagingException e) {
+ LOG.error("Unable to send report", e);
+ }
+ }
+
+ private void groupLogEntries(Report report) {
+ for (LogItem logItem : report.getInfo().getLogEntries()) {
+ LogEnum type = logItem.getType();
+ List items = grouped.get(type);
+ if (items == null) {
+ items = new ArrayList<>();
+ }
+
+ items.add(logItem);
+ grouped.put(type, items);
+ }
+ }
+
+ private void send(String body) throws MessagingException {
+ //Set the host smtp address
+ Properties props = new Properties();
+ props.put("mail.smtp.host", "127.0.0.1");
+
+ // create some properties and get the default Session
+ Session session = Session.getDefaultInstance(props, null);
+ session.setDebug(false);
+
+ // create a message
+ Message msg = new MimeMessage(session);
+
+ // set the from and to address
+ InternetAddress addressFrom = new InternetAddress("ace-report@umiacs.umd.edu");
+ msg.setFrom(addressFrom);
+
+ String[] to = (recipients == null ? null : recipients.split("\\s*,\\s*"));
+ if (to == null) {
+ throw new RuntimeException("No email recipients to send to");
+ }
+
+ InternetAddress[] addressTo = new InternetAddress[to.length];
+ for (int i = 0; i < to.length; i++) {
+ addressTo[i] = new InternetAddress(to[i]);
+ }
+ addressTo[0] = new InternetAddress(recipients);
+ msg.setRecipients(Message.RecipientType.TO, addressTo);
+
+ // Setting the Subject and Content Type
+ msg.setSubject("Ace Report: Test Reporter");
+ msg.setContent(body, "text/plain");
+ Transport.send(msg);
+ // LOG.trace("Successfully mailed report to: " + Strings.join(',', mailList));
+ }
+
+ private String createBody(Report report) {
+ StringBuilder sb = new StringBuilder();
+
+ sb.append("Report Name: \t");
+ sb.append(report.getSession());
+ sb.append("\r\n");
+
+ sb.append("Collection: \t");
+ sb.append(report.getCollection().getName());
+ sb.append("\r\n");
+
+ sb.append("Generated on: \t");
+ sb.append(report.getGenerated());
+ sb.append("\r\n");
+
+ sb.append("Start Date: \t");
+ sb.append(report.getStart());
+ sb.append("\r\n");
+
+ sb.append("End Date: \t");
+ sb.append(report.getEnd());
+ sb.append("\r\n");
+
+ sb.append("\r\n----------------------\r\nCollection summary\r\n\r\n");
+ sb.append("Collection state: \t").append(report.getCollection().getState()).append("\r\n");
+ sb.append("Errors: \t").append(report.getInfo().getErrors().size()).append("\r\n");
+
+ sb.append("\r\n----------------------\r\nTotal Log Entries\r\n\r\n");
+ for (Map.Entry> entry : grouped.entrySet()) {
+ sb.append(entry.getKey().getShortName())
+ .append(": \t")
+ .append(entry.getValue().size())
+ .append("\r\n");
+ }
+
+
+ /*
+ for ( ReportItem ri : summaryItems ) {
+ if ( !ri.isLogType() ) {
+ sb.append(ri.getAttribute());
+ sb.append(": \t");
+ sb.append(ri.getValue());
+ sb.append("\r\n");
+ }
+ }
+ sb.append("\r\n----------------------\r\nTotal Log Entries\r\n\r\n");
+ for ( ReportItem ri : summaryItems ) {
+ if ( ri.isLogType() ) {
+ sb.append(ri.getAttribute());
+ sb.append(": \t");
+ sb.append(ri.getValue());
+ sb.append("\r\n");
+ }
+ }
+ */
+ return sb.toString();
+ }
+}
diff --git a/ace-am/src/main/java/edu/umiacs/ace/remote/JsonGateway.java b/ace-am/src/main/java/edu/umiacs/ace/remote/JsonGateway.java
index 4a3b2224f3659e3744b5794e8b93cf3a6aa97c2e..d69e5047458b51721ec9ea28a8eef8a2ae737211 100644
--- a/ace-am/src/main/java/edu/umiacs/ace/remote/JsonGateway.java
+++ b/ace-am/src/main/java/edu/umiacs/ace/remote/JsonGateway.java
@@ -264,12 +264,12 @@ public class JsonGateway {
private long statusUpdate = 0;
private SummaryBean summary = null;
private long summaryUpdate = 0;
- private Map reportMap = new HashMap();
- private Map reportMapUpdate = new HashMap();
- private Map itemMap = new HashMap();
- private Map itemMapUpdate = new HashMap();
- private Map itemRootMap = new HashMap();
- private Map itemRootMapUpdate = new HashMap();
+ private Map reportMap = new HashMap<>();
+ private Map reportMapUpdate = new HashMap<>();
+ private Map itemMap = new HashMap<>();
+ private Map itemMapUpdate = new HashMap<>();
+ private Map itemRootMap = new HashMap<>();
+ private Map itemRootMapUpdate = new HashMap<>();
}
private T readJSONValue( URL u, String auth, Class clazz ) throws IOException {
diff --git a/ace-am/src/main/java/edu/umiacs/ace/rest/CollectionManagement.java b/ace-am/src/main/java/edu/umiacs/ace/rest/CollectionManagement.java
index 6547bd87922e9458e90d2e1f5f6330029418a33b..fe801bed2c8eeea79bfde0680640f1f90dbbda75 100644
--- a/ace-am/src/main/java/edu/umiacs/ace/rest/CollectionManagement.java
+++ b/ace-am/src/main/java/edu/umiacs/ace/rest/CollectionManagement.java
@@ -11,6 +11,8 @@ import edu.umiacs.ace.monitor.access.CollectionCountContext;
import edu.umiacs.ace.monitor.audit.AuditThreadFactory;
import edu.umiacs.ace.monitor.core.Collection;
import edu.umiacs.ace.monitor.core.MonitoredItem;
+import edu.umiacs.ace.monitor.reporting.ReportPlugin;
+import edu.umiacs.ace.rest.model.RPluginRequest;
import edu.umiacs.ace.util.PersistUtil;
import org.apache.log4j.Logger;
import org.codehaus.jettison.json.JSONException;
@@ -36,6 +38,8 @@ import java.util.List;
/**
* REST Service for adding and viewing collections
*
+ * TODO: We should do /{id}/verb instead of {/verb/{id}}
+ *
* @author shake
*/
@Path("collection")
@@ -68,11 +72,45 @@ public class CollectionManagement {
return false;
}
+ @POST
+ @Consumes(MediaType.APPLICATION_JSON)
+ @Path("plugin/{id}")
+ public Response configurePlugin(@PathParam("id") long id, RPluginRequest request) {
+ EntityManager em = PersistUtil.getEntityManager();
+ Collection c = em.find(Collection.class, id);
+
+ if (c == null || !RPluginRequest.isValid(request)) {
+ return Response.status(400).build();
+ }
+
+ ReportPlugin plugin = new ReportPlugin()
+ .setNamedClass(request.getNamedClass())
+ .setParent(c);
+
+ if (c.getReportPlugins().contains(plugin)) {
+ return Response.status(400).build();
+ }
+
+ c.getReportPlugins().add(plugin);
+ // TODO: Ensure settings is at least an empty map
+ c.getSettings().putAll(request.getSettings());
+
+ EntityTransaction transaction = em.getTransaction();
+ transaction.begin();
+ em.persist(plugin);
+ em.merge(c);
+ transaction.commit();
+ em.close();
+
+ return Response.ok().build();
+ }
+
@POST
@Path("audit/{id}")
- public Response startAudit(@PathParam("id")long id) {
+ public Response startAudit(@PathParam("id") long id) {
EntityManager em = PersistUtil.getEntityManager();
Collection c = em.find(Collection.class, id);
+ em.close();
if ( c == null ) {
return Response.status(Status.NOT_FOUND).build();
}
diff --git a/ace-am/src/main/java/edu/umiacs/ace/rest/model/RPluginRequest.java b/ace-am/src/main/java/edu/umiacs/ace/rest/model/RPluginRequest.java
new file mode 100644
index 0000000000000000000000000000000000000000..99ca79b5c57b13bcbe4094bac7d6299a5426f73e
--- /dev/null
+++ b/ace-am/src/main/java/edu/umiacs/ace/rest/model/RPluginRequest.java
@@ -0,0 +1,35 @@
+package edu.umiacs.ace.rest.model;
+
+import java.util.Map;
+
+/**
+ *
+ * Created by shake on 6/21/16.
+ */
+public class RPluginRequest {
+
+ private String namedClass;
+ private Map settings;
+
+ public String getNamedClass() {
+ return namedClass;
+ }
+
+ public RPluginRequest setNamedClass(String namedClass) {
+ this.namedClass = namedClass;
+ return this;
+ }
+
+ public Map getSettings() {
+ return settings;
+ }
+
+ public RPluginRequest setSettings(Map settings) {
+ this.settings = settings;
+ return this;
+ }
+
+ public static boolean isValid(RPluginRequest request) {
+ return request != null && request.namedClass != null;
+ }
+}
diff --git a/ace-am/src/main/resources/META-INF/persistence.xml b/ace-am/src/main/resources/META-INF/persistence.xml
index ff2ccf4b97528f5e09506402c62945bdd404fa75..1119ded74276a19c0377c424f68bc94912c73d70 100644
--- a/ace-am/src/main/resources/META-INF/persistence.xml
+++ b/ace-am/src/main/resources/META-INF/persistence.xml
@@ -20,6 +20,7 @@
edu.umiacs.ace.monitor.core.MonitoredItem
edu.umiacs.ace.driver.swap.SwapSettings
edu.umiacs.ace.monitor.settings.SettingsParameter
+ edu.umiacs.ace.monitor.reporting.ReportPlugin
true
diff --git a/ace-am/src/main/sql/ace-am.sql b/ace-am/src/main/sql/ace-am.sql
index f06618206e8892ec421f27953003a9fbb992658d..27540bd3ac961928db758c712368e77ac6f794c0 100644
--- a/ace-am/src/main/sql/ace-am.sql
+++ b/ace-am/src/main/sql/ace-am.sql
@@ -20,9 +20,9 @@ CREATE TABLE `monitored_item` (
`LASTSEEN` datetime default NULL,
`STATECHANGE` datetime default NULL,
`LASTVISITED` datetime default NULL,
- `PARENTPATH` varchar(512) character set utf8 collate utf8_general_ci default NULL,
+ `PARENTPATH` text character set utf8 collate utf8_general_ci default NULL,
`STATE` char(1) NOT NULL,
- `PATH` varchar(512) character set utf8 collate utf8_general_ci default NULL,
+ `PATH` text character set utf8 collate utf8_general_ci default NULL,
`DIRECTORY` tinyint(1) NOT NULL default '0',
`TOKEN_ID` bigint(20) default NULL,
`PARENTCOLLECTION_ID` bigint(20) NOT NULL,
@@ -218,3 +218,12 @@ CREATE TABLE `system_settings` (
PRIMARY KEY (`ID`),
UNIQUE (`ATTR`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+
+CREATE TABLE `report_plugin` (
+ `ID` bigint(20) NOT NULL auto_increment,
+ `PARENT_ID` bigint(20) NOT NULL,
+ `NAMEDCLASS` varchar(255) NOT NULL,
+ UNIQUE `pc_idx`(`PARENT_ID`, `NAMEDCLASS`),
+ PRIMARY KEY (`ID`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+
diff --git a/ace-am/src/main/webapp/WEB-INF/web.xml b/ace-am/src/main/webapp/WEB-INF/web.xml
index 25b297515b3f31a02db46e821f0b4991dab0c070..035e566f6ed992cfe281ccb09beaeb477a9cc403 100644
--- a/ace-am/src/main/webapp/WEB-INF/web.xml
+++ b/ace-am/src/main/webapp/WEB-INF/web.xml
@@ -80,6 +80,10 @@
Initial ingestion configuration
edu.umiacs.ace.monitor.register.IngestContextListener
+
+ Reporter scanning
+ edu.umiacs.ace.monitor.reporting.ReporterContextListener
+
ServletAdaptor
com.sun.jersey.spi.container.servlet.ServletContainer
@@ -202,6 +206,11 @@
DeleteSettingsServlet
edu.umiacs.ace.monitor.settings.DeleteSettingsServlet
+
+ ManageReporter
+ edu.umiacs.ace.monitor.reporting.ManageReporterServlet
+
+
ServletAdaptor
/rest/*
@@ -323,6 +332,10 @@
DeleteSettingsServlet
/DeleteSettings
+
+ ManageReporter
+ /ManageReporter
+
30
diff --git a/ace-am/src/main/webapp/collectionmodify.jsp b/ace-am/src/main/webapp/collectionmodify.jsp
index e2e735b86c84832e1d46a1a0b1134a87fdb5247a..1afd5625fe83fcfc11209ae0090df5e27be747ac 100644
--- a/ace-am/src/main/webapp/collectionmodify.jsp
+++ b/ace-am/src/main/webapp/collectionmodify.jsp
@@ -145,7 +145,19 @@ Author : toaster
-
+
+
+
+ Configured Plugin |
+ ${plugin.namedClass} Remove |
+
+
+
+
+ Configure reporting |
+ Configure reporting which occurs after auditing |
+
+
Peer Collection |
diff --git a/ace-am/src/main/webapp/configure_reporting.jsp b/ace-am/src/main/webapp/configure_reporting.jsp
new file mode 100644
index 0000000000000000000000000000000000000000..d3c5cbb0750246cc5cc19732a1edbb60b20e3967
--- /dev/null
+++ b/ace-am/src/main/webapp/configure_reporting.jsp
@@ -0,0 +1,98 @@
+
+<%@page pageEncoding="UTF-8"%>
+<%--
+The taglib directive below imports the JSTL library. If you uncomment it,
+you must also add the JSTL library to the project. The Add Library... action
+on Libraries node in Projects view can be used to add the JSTL 1.1 library.
+--%>
+<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
+<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
+
+
+
+
+
+
+
+
+
+ Modify Audit Reporting
+
+
+
+
+
+
+
+
Configure audit reporting for ${workingCollection.collection.name}
+
+
+
+
+
+
+
diff --git a/ace-am/src/main/webapp/settings.jsp b/ace-am/src/main/webapp/settings.jsp
index b672f2fd825023a791bca82153b0c80ea7f53608..fe6c8f45976906d6c5b101506faa9be09d43bf6b 100644
--- a/ace-am/src/main/webapp/settings.jsp
+++ b/ace-am/src/main/webapp/settings.jsp
@@ -157,7 +157,7 @@
-
UMIACS Connection:
+
ACE Log Level:
diff --git a/pom.xml b/pom.xml
index a25e606abb1056a19a4e8b6d048521bedc644ea8..8d0a8879ad7d2718c557dbf2057a5d39cf410b69 100644
--- a/pom.xml
+++ b/pom.xml
@@ -17,10 +17,10 @@
org.apache.maven.plugins
maven-compiler-plugin
- 2.0.2
+ 3.1
- 1.7
- 1.7
+ 1.8
+ 1.8
@@ -91,7 +91,7 @@
- ${project.version} (hudson build:${BUILD_NUMBER} revision:${SVN_REVISION})
+ ${project.version}
@@ -100,6 +100,7 @@
ace-ims-ws
ace-ims-api
ace-am
+
ace-am-api
ace-dist
audit-core
ace-ims-server