Skip to content
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

Wrong size when generated avatar and object store as primary #9749

Closed
vpecinka opened this issue Jun 5, 2018 · 4 comments
Closed

Wrong size when generated avatar and object store as primary #9749

vpecinka opened this issue Jun 5, 2018 · 4 comments

Comments

@vpecinka
Copy link
Contributor

vpecinka commented Jun 5, 2018

Well, I don't know if report template is useful here. I`m running Nextcloud v13.0.1.1 with Swift as primary storage and connect to the LDAP server with user base.

Nextcloud is generating avatars (most of the users have none) and there is stored size=0 for the record in the database. However, when I run consistency check (my own python script useful to mitigate problems in # #9690) I can see there is object of size=1 in the Swift storage.

So my consistency check says something like this:

WRN: Size mismatch (store=1, db=0, uid=0) for nc_0/id:22234437 => appdata_ocdn3mtk0j94/avatar/16EE33D8-5EF8-4B8C-AA1F-80D099E734E9/generated
WRN: Size mismatch (store=1, db=0, uid=0) for nc_0/id:22234443 => appdata_ocdn3mtk0j94/avatar/16F80F0D-0F3F-4C95-966E-36E7AF24F281/generated
WRN: Size mismatch (store=1, db=0, uid=0) for nc_0/id:22234450 => appdata_ocdn3mtk0j94/avatar/172FE4A0-EA59-4887-8494-E09E45F0C10B/generated
WRN: Size mismatch (store=1, db=0, uid=0) for nc_0/id:22234456 => appdata_ocdn3mtk0j94/avatar/17380353-5A7E-4DC3-80CE-884385779FD6/generated
WRN: Size mismatch (store=1, db=0, uid=0) for nc_0/id:22234462 => appdata_ocdn3mtk0j94/avatar/173A7A49-1AAB-4371-83CE-C288ACC4FD98/generated
WRN: Size mismatch (store=1, db=0, uid=0) for nc_0/id:22234470 => appdata_ocdn3mtk0j94/avatar/174ACD57-2F9E-474C-ADEB-47CA67439EE7/generated
WRN: Size mismatch (store=1, db=0, uid=0) for nc_0/id:22234474 => appdata_ocdn3mtk0j94/avatar/174D6950-EE16-4329-8D8D-86C66DC88856/generated
WRN: Size mismatch (store=1, db=0, uid=0) for nc_0/id:22234480 => appdata_ocdn3mtk0j94/avatar/175C653D-D78E-4EA0-A393-7ED1469E4B3D/generated
...

I suggest not to create object when avatar is generated (from name?) or create and store the image (and cache it) if it needs to be created.

@MorrisJobke
Copy link
Member

cc @rullzer @icewind1991

@nextcloud-bot nextcloud-bot added the stale Ticket or PR with no recent activity label Jul 6, 2018
@nextcloud-bot
Copy link
Member

Hey, this issue has been closed because the label stale is set and there were no updates for 14 days. Feel free to reopen this issue if you deem it appropriate.

(This is an automated comment from GitMate.io.)

@nextcloud-bot nextcloud-bot removed the stale Ticket or PR with no recent activity label Jul 21, 2018
@MorrisJobke
Copy link
Member

This file is there to detect if the avatar is generated (basically a color with a letter on it) or not. Don’t know wh. It is not a DB flag, but @rullzer should know more. So this is the correct behavior

@rullzer
Copy link
Member

rullzer commented Jul 21, 2018

It is not a DB flag because if people have issues with their appdata the state is still consitent.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants