Skip to content
This repository has been archived by the owner on Jan 28, 2021. It is now read-only.

Commit

Permalink
#115 - fixes compile issues (_republish currently not implemented).
Browse files Browse the repository at this point in the history
  • Loading branch information
danhaywood committed Oct 1, 2019
1 parent d4df0e6 commit 155d05a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 30 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@

import javax.inject.Inject;

import org.apache.isis.applib.annotation.*;
import org.apache.isis.schema.ixn.v1.InteractionDto;
import org.apache.isis.schema.utils.InteractionDtoUtils;

import org.apache.isis.applib.annotation.Action;
import org.apache.isis.applib.annotation.ActionLayout;
import org.apache.isis.applib.annotation.MemberOrder;
import org.apache.isis.applib.annotation.Mixin;
import org.apache.isis.applib.annotation.SemanticsOf;
import org.isisaddons.module.publishmq.PublishMqModule;
import org.isisaddons.module.publishmq.dom.servicespi.PublisherServiceUsingActiveMq;

Expand Down Expand Up @@ -33,22 +34,7 @@ public static class ActionDomainEvent extends PublishMqModule.ActionDomainEvent<
@MemberOrder(name = "transactionId", sequence = "1")
public PublishedEvent $$() {

final String xml = publishedEvent.getSerializedForm();

final PublishedEventType eventType = publishedEvent.getEventType();
switch (eventType) {
case ACTION_INVOCATION:
case PROPERTY_EDIT:
final InteractionDto interactionDto = InteractionDtoUtils.fromXml(xml);
publisherService.republish(interactionDto);
break;
case CHANGED_OBJECTS:
break;
}
return publishedEvent;
throw new RuntimeException("Not yet implemented.");
}

@Inject
PublisherServiceUsingActiveMq publisherService;

}
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
import javax.annotation.PostConstruct;
import javax.annotation.PreDestroy;
import javax.inject.Inject;
import javax.jms.JMSException;
import javax.jms.Session;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
Expand Down Expand Up @@ -55,14 +53,6 @@ public void shutdown() {
}


private static void closeSafely(Session session) {
try {
session.close();
} catch (JMSException e) {
// ignore
}
}

//endregion


Expand Down Expand Up @@ -121,6 +111,7 @@ private void persist(final PublishedObjects publishedObjects) {

@Inject
List<InteractionExecutionRepository> interactionExecutionRepositories;

//endregion

}

0 comments on commit 155d05a

Please sign in to comment.