-
-
Notifications
You must be signed in to change notification settings - Fork 128
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Replace AlamoFire #783
Comments
See openhab#783 Signed-off-by: Dan Cunningham <[email protected]>
See openhab#783 Signed-off-by: Dan Cunningham <[email protected]>
* Uses new HTTPClient for background fetch jobs See #783 Signed-off-by: Dan Cunningham <[email protected]> * Use new HTTPClient class for downloading all data in notifications Signed-off-by: Dan Cunningham <[email protected]> * move download media to new client Signed-off-by: Dan Cunningham <[email protected]> --------- Signed-off-by: Dan Cunningham <[email protected]>
I think URLSession has matured enough over the years. Makes sense to get rid of Alamofire imho. |
Are you still pushing to get rid of Alamofire ? |
Yeah, i think so. My little basic http client that i'm using for the notification calls i think is a good prototype that proves you don't really need a 3rd party library. |
@digitaldan just make sure to use the async functions instead of closures (imho). |
My plan right now is to swap out the alamo bits with URLSession and friends in the NetworkManager class, and keep the calling code mostly unmodified. I think that will be actually pretty easy, i can then remove my little httpclient prototype. Once thats all working, i think a bigger refactor of the networking will be a nice to have. |
I made a first step in the direction of using async version. Not yet for the main networking call but for the delegates URLSessionDelegate and URLSessionTaskDelegate. See #798 |
Hey @weakfl and @timbms , this is probably not a small task, but i am finding that AlamoFire is causing issues in the app, specifically they do not support making http calls while the app is in the background (its a long requested feature). This is causing issues for our new push notifications when we try and send commands to items. I may resort to creating an alternative just for background tasks and use the built in networking with support for credentials, certs, etc.... If that works, maybe we move forward with overhauling the rest of the app to use it. Also i have noticed that AlamoFire does not seem very active as a project, seems like a relic of the past perhaps.
The text was updated successfully, but these errors were encountered: