Skip to content

Conversation

maksymmalyhin
Copy link
Contributor

No description provided.

@maksymmalyhin maksymmalyhin requested review from paulb777, charlotteliang and ryanwilson and removed request for paulb777 June 7, 2019 18:25
Copy link
Member

@paulb777 paulb777 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please improve the comment I referenced - then LGTM


// TODO: Consider implementation which does not modify UUID.

// A valid FID has exactly 22 base64 characters, which is 132 bits, or 16.5
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

16.5 what?

// TODO: Consider implementation which does not modify UUID.

// A valid FID has exactly 22 base64 characters, which is 132 bits, or 16.5
// Our generated ID has 16 bytes UUID + 1 byte prefix which is 23 base64 characters
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

16+1=23???

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's how base64 encoding works.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated the explanation a bit. Let me know if it is still not exactly clear.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! That clarifies it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@class FIRInstallationsItem;

/**
* The class is responsible for managing FID for a given `FIRApp`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you mean managing FIRInstallationsStore? Because I don't see any local cached FID info. Or should we have a local cached FIRInstallationsItem so we are not reconstruct the object every query.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@chliangGoogle
By managing I mean following:

  • retrieving /saving locally stored FID
  • registering a new FID using FIS API
  • removing FID

The class is not fully implemented yet, it is just an intermediate part without API (sorry, forgot to add a TODO for that).

I'll add more description on the FID lifecycle to the class description later on, so it will be more clear.


- (instancetype)initWithGoogleAppID:(NSString *)appID appName:(NSString *)appName;

- (FBLPromise<FIRInstallationsItem *> *)getInstallationItem;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see it gets called from FIRInstallations so I wonder if we should have a test app that triggers the public API which calls all the new methods you created. Otherwise, it's hard to vision what this new created method for without seeing it called any where from the public API chain. I think it might help us to have a end-to-end flow during development.

Copy link
Contributor Author

@maksymmalyhin maksymmalyhin Jun 7, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is called from here. Yeah it may be easy to miss.

A test app is in my TODO list. I assume it will be used for manual and automated testing. I think to add it when there is something to test end-to-end.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

aha, right it's moved from another class. Got it


- (instancetype)initWithGoogleAppID:(NSString *)appID appName:(NSString *)appName;

- (FBLPromise<FIRInstallationsItem *> *)getInstallationItem;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

aha, right it's moved from another class. Got it

@maksymmalyhin maksymmalyhin merged commit f568326 into mm/fis-master Jun 7, 2019
@maksymmalyhin maksymmalyhin deleted the mm/fid-fid branch June 7, 2019 20:49
@firebase firebase locked and limited conversation to collaborators Oct 14, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants