0

I need to create a Service app,

Requirements

1 a request handler accepts request when it is sent from the other in house apps installed on the same device, saves the data to SQLite,

2 another service, message sender within the service app, polls the SQLite once every 5 secs (configurable) for data and send it to server side.

enter image description here

I want to find out if the option below is the best option, and look for alternatives otherwise. Please correct me if I am wrong.

Implementation Options

1 AIDL is used for communicating between the request handler within Service app and other in-house apps

The reason of using AIDL is

A.It allows multi-threading and accept requests from multiple apps.

B.It might provide better performance

Is there a better option?

2 The request handler

Since it is using AIDL, am I correct that it will be only invoked when request arrives

3 Message sender

What is best option for implementing this?

Option 1: Use Task in C# or Thread in Java to run it in the background

Other options from Android?

4 Service app

A Should the Service app be in a separate APK?

B How to launch Service app without Activity when Android OS starts?

C Should Service app be ran as background service or foreground. It might has problem running as background in Android 8?

OS: Lollipop, Xamarin Android

Thanks in advance.

Community
  • 1
  • 1
Pingpong
  • 7,681
  • 21
  • 83
  • 209
  • This is a really broad Android architectural question (with many sub-questions), it really should be a post over at https://softwareengineering.stackexchange.com/questions/tagged/android – SushiHangover Oct 09 '18 at 00:13
  • It should be easy for someone who has done it before, – Pingpong Oct 09 '18 at 00:18
  • That is not my point, "stackoverflow" is not an architectural design forum and that question is very broad and there is not just one answer for any of it. I could answer all your questions with different answers depending upon usage context, request rates, different API levels, etc... just saying... – SushiHangover Oct 09 '18 at 00:27

0 Answers0