Skip to content

Commit

Permalink
changes for message structure
Browse files Browse the repository at this point in the history
  • Loading branch information
HariharanAnantharaman committed Jun 17, 2019
1 parent 606ff92 commit e31077d
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -408,22 +408,22 @@ public void listenAssetLocation(ConsumerRecord<?, ?> cr) throws Exception {

KeyValue tag=new KeyValue();
tag.setKey("assetId");
tag.setValue((String)object.get("assetid"));
tag.setValue((String)object.get("aaid"));


tagList.add(tag);

if(object.has("latitude")){
if(object.has("lat")){
KeyValue latitidue=new KeyValue();
latitidue.setKey("latitude");
latitidue.setValue(object.getDouble("latitude"));
latitidue.setValue(object.getDouble("lat"));
valuelist.add(latitidue);
}
if(object.has("longitude")){
if(object.has("long")){

KeyValue longitude=new KeyValue();
longitude.setKey("longitude");
longitude.setValue(object.getDouble("longitude"));
longitude.setValue(object.getDouble("long"));
valuelist.add(longitude);
}

Expand Down

0 comments on commit e31077d

Please sign in to comment.