I want to handle a document added event in Guidewire Cloud Platform by developing an Integration Gateway app. I have been able to create the app and handle the events, but its really time consuming to make changes, push code to BitBucket, Build the app in CI/CD, and deploy to active planet fro each change. Can i do this development and testing all local on my dev machine?

I tried to use the record-replay feature of Guidewire AppEvents. The files I updated is route.properties, and ran this in the cloud but no json file is written to S3 that i can use for local development as stated in the GW docs.

route.properties file:

gw.appevents.record-replay.mode=record
gw.appevents.record-replay.record.enabled.cc-ae-ex=true
gw.appevents.record-replay.record.s3.region=us-east-2
gw.appevents.record-replay.record.s3.bucket=cc-recorded-events
gw.appevents.record-replay.record.s3.prefix=cc-events-docs
gw.appevents.record-replay.record.s3.accessKey=<EXT AWS KEY>
gw.appevents.record-replay.record.s3.secretKey=<EXT AWS SECRET>
gw.appevents.record-replay.replay.dir.cc-docadded=./src/test/resources/replay-log-cc

sample Camel Route:

@Named
    public class SampleAppEventRoute extends RouteBuilder {
        public void configure() throws Exception {
        from("appevents:cc?id=cc-docs-events&events=DocumentAdded")
        .routeId("cc-ae-ex")
        .process(this::processMessage);
    }
1

There are 1 answers

0
Ted Ogrean On

The entry in the route.properties file below does not match the ID in the route file. It can be confusing because there are 2 ID's. After you make this change and run in the cloud the AppEvent json file will show in the S3 bucket as expected

change the route.properties file to: gw.appevents.record-replay.record.enabled.cc-docs-events=true

gw.appevents.record-replay.replay.dir.cc-docs-events=./src/test/resources/replay-log-cc

to match the route ID in the from("appevents:cc?id=cc-docs-events&events=DocumentAdded"") url.

ID Mapping