From: kenstir Date: Mon, 12 Oct 2015 22:50:04 +0000 (-0400) Subject: * added new version of opensrf2 that has parseable log output, X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=d26ea0d49536fc71b45e41de9828af26e42f5c12;p=working%2FEvergreen.git * added new version of opensrf2 that has parseable log output, and a perl script to parse it. This is for my osrf debugging. --- diff --git a/Open-ILS/src/Android/core/libs/opensrf2_android.jar b/Open-ILS/src/Android/core/libs/opensrf2_android.jar index 0c91332338..71af946c4d 100644 Binary files a/Open-ILS/src/Android/core/libs/opensrf2_android.jar and b/Open-ILS/src/Android/core/libs/opensrf2_android.jar differ diff --git a/Open-ILS/src/Android/kenstir_copy_osrf_jar.sh b/Open-ILS/src/Android/kenstir_copy_osrf_jar.sh new file mode 100644 index 0000000000..5c40976b20 --- /dev/null +++ b/Open-ILS/src/Android/kenstir_copy_osrf_jar.sh @@ -0,0 +1,2 @@ +#!/bin/bash +cp -p ../../../../opensrf2_serialized_reg/out/artifacts/jar/opensrf2_android.jar core/libs diff --git a/Open-ILS/src/Android/kenstir_parse_logcat.pl b/Open-ILS/src/Android/kenstir_parse_logcat.pl new file mode 100644 index 0000000000..d8aaba6803 --- /dev/null +++ b/Open-ILS/src/Android/kenstir_parse_logcat.pl @@ -0,0 +1,20 @@ +#!/usr/bin/perl +# +# debug helper for evergreen app +# +# get output from logcat and parse the OSRF JSON output and print it + +use strict; +use warnings; +use Data::Dumper; +use JSON; + +my $logcat = `adb logcat -d`; +my @lines = split(/\n/, $logcat); +foreach my $line (@lines) { + if ($line =~ /org.opensrf.net.http.GatewayRequest.*service:(\S+) method:(\S+) result:(.*)/) { + my($svc,$method,$json) = ($1,$2,$3); + my $obj = decode_json($json); + print "$method $svc -> ", Dumper($obj); + } +}