Closed ckertam closed 1 year ago
For circle creation geometry field can be too long unnecessarily.
Need to solve it otherwise it uses to much storage and response size become bigger.
An example response :
{ "id": 18, "author": 1, "author_username": "cano14", "title": "TESTTT", "content": "<p>TESTTT</p>", "story_tags": "TESTTT", "location_ids": [ { "id": 12, "name": "FHQC+V4 Mutnitsa, Komi Republic, Rusya", "point": "SRID=4326;POINT (49.5703125 59.489726035537075)", "line": null, "polygon": null, "circle": null, "radius": null, "geometry": "{ \"type\": \"Point\", \"coordinates\": [ 49.5703125, 59.489726035537075 ] }", "success": true, "msg": "Story ok." }, { "id": 13, "name": "9PR7F4H8+7V", "point": "SRID=4326;POINT (105.1171875 66.47820814385636)", "line": null, "polygon": null, "circle": null, "radius": null, "geometry": "{ \"type\": \"Point\", \"coordinates\": [ 105.1171875, 66.478208143856364 ] }", "success": true, "msg": "Story ok." }, { "id": 14, "name": "968M45C7+CJ", "point": null, "line": null, "polygon": null, "circle": "SRID=4326;POINT (-86.8359375 56.12106042504407)", "radius": "654880.2464004400", "geometry": "{ \"type\": \"Polygon\", \"coordinates\": [ [ [ 654793.410462939995341, 56.121060425044071 ], [ 642210.07015889219474, -127704.67709183820989 ], [ 604943.619957814808004, -250555.699420191085665 ], [ 544426.188641669112258, -363775.850032201851718 ], [ 462983.427157368278131, -463014.142034443153534 ], [ 363745.135155127034523, -544456.903518744045869 ], [ 250524.984543116152054, -604974.334834889741614 ], [ 127673.962214763305383, -642240.785035967128351 ], [ -86.835937499959897, -654824.125340014928952 ], [ -127847.634089763218071, -642240.785035967128351 ], [ -250698.656418116064742, -604974.334834889741614 ], [ -363918.807030126801692, -544456.903518744162284 ], [ -463157.099032368219923, -463014.142034443211742 ], [ -544599.860516669228673, -363775.850032201851718 ], [ -605117.291832814808004, -250555.699420191143872 ], [ -642383.74203389219474, -127704.67709183844272 ], [ -654967.082337939995341, 56.121060424963872 ], [ -642383.74203389219474, 127816.91921268835722 ], [ -605117.291832814808004, 250667.941541041072924 ], [ -544599.860516669228673, 363888.092153051868081 ], [ -463157.099032368336339, 463126.384155293286312 ], [ -363918.807030126918107, 544569.145639594178647 ], [ -250698.656418116472196, 605086.576955739641562 ], [ -127847.634089763523662, 642353.027156817144714 ], [ -86.835937500120295, 654936.36746086506173 ], [ 127673.962214763290831, 642353.02715681726113 ], [ 250524.984543116268469, 605086.576955739757977 ], [ 363745.135155126743484, 544569.145639594295062 ], [ 462983.427157368161716, 463126.384155293402728 ], [ 544426.188641669112258, 363888.092153051984496 ], [ 604943.619957814575173, 250667.941541041538585 ], [ 642210.070158892078325, 127816.919212688590051 ], [ 654793.410462939995341, 56.121060425044071 ] ] ] }", "success": true, "msg": "Story ok." }, { "id": 15, "name": "98FJ4GJQ+8J", "point": null, "line": null, "polygon": null, "circle": "SRID=4326;POINT (-47.4609375 59.13086309725591)", "radius": "630717.7959481197", "geometry": "{ \"type\": \"Polygon\", \"coordinates\": [ [ [ 630670.33501061971765, 59.130863097255911 ], [ 618551.269416784052737, -122987.807049724098761 ], [ 582659.801529597956687, -241306.120144073502161 ], [ 524375.220331798889674, -350348.902001409500372 ], [ 445937.369592448638286, -445925.699666851316579 ], [ 350360.571927006822079, -524363.550406201626174 ], [ 241317.790069670794765, -582648.131604000693187 ], [ 122999.476975321391365, -618539.599491186789237 ], [ -47.460937499961382, -630658.66508502245415 ], [ -123094.398850321304053, -618539.599491186789237 ], [ -241412.711944670736557, -582648.131604000693187 ], [ -350455.493802006647456, -524363.550406201859005 ], [ -446032.291467448580079, -445925.699666851374786 ], [ -524470.14220679900609, -350348.902001409500372 ], [ -582754.723404597956687, -241306.120144073589472 ], [ -618646.191291784052737, -122987.807049724317039 ], [ -630765.25688561971765, 59.130863097178668 ], [ -618646.191291784052737, 123106.068775918669417 ], [ -582754.723404598073103, 241424.381870267970953 ], [ -524470.142206799122505, 350467.163727603910957 ], [ -446032.291467448696494, 446043.961393045843579 ], [ -350455.493802006763872, 524481.812132396153174 ], [ -241412.711944671114907, 582766.393330195103772 ], [ -123094.398850321609643, 618657.861217381316237 ], [ -47.460937500115861, 630776.92681121698115 ], [ 122999.476975321376813, 618657.861217381316237 ], [ 241317.79006967091118, 582766.393330195220187 ], [ 350360.571927006531041, 524481.812132396386005 ], [ 445937.369592448521871, 446043.961393045959994 ], [ 524375.220331798889674, 350467.163727604027372 ], [ 582659.801529597840272, 241424.381870268407511 ], [ 618551.269416784052737, 123106.068775918887695 ], [ 630670.33501061971765, 59.130863097255911 ] ] ] }", "success": true, "msg": "Story ok." }, { "id": 16, "name": "676G7WW9+J5", "point": null, "line": null, "polygon": "SRID=4326;POLYGON ((-69.08203125 -5.703447982149503, -45.87890625 11.781325296112277, -38.14453125 -13.325484885597936, -69.08203125 -5.703447982149503))", "circle": null, "radius": null, "geometry": "{ \"type\": \"Polygon\", \"coordinates\": [ [ [ -69.08203125, -5.703447982149503 ], [ -45.87890625, 11.781325296112277 ], [ -38.14453125, -13.325484885597936 ], [ -69.08203125, -5.703447982149503 ] ] ] }", "success": true, "msg": "Story ok." }, { "id": 17, "name": "3MPM+6C Gatos Güeros, N.L., Meksika", "point": null, "line": null, "polygon": "SRID=4326;POLYGON ((-99.31640625 25.085598897064752, -74.00390625 17.224758206624642, -85.25390625 3.4256915244180624, -99.31640625 25.085598897064752))", "circle": null, "radius": null, "geometry": "{ \"type\": \"Polygon\", \"coordinates\": [ [ [ -99.31640625, 25.085598897064752 ], [ -74.00390625, 17.224758206624642 ], [ -85.25390625, 3.425691524418062 ], [ -99.31640625, 25.085598897064752 ] ] ] }", "success": true, "msg": "Story ok." }, { "id": 18, "name": "885RMW2M+FC", "point": null, "line": "SRID=4326;LINESTRING (-43.06640625 33.65120829920497, -9.31640625 43.004647127794435, -0.87890625 21.861498734372567, -38.14453125 29.45873118535534)", "polygon": null, "circle": null, "radius": null, "geometry": "{ \"type\": \"LineString\", \"coordinates\": [ [ -43.06640625, 33.651208299204967 ], [ -9.31640625, 43.004647127794435 ], [ -0.87890625, 21.861498734372567 ], [ -38.14453125, 29.45873118535534 ] ] }", "success": true, "msg": "Story ok." }, { "id": 19, "name": "W39Q+CW المنجور Suudi Arabistan", "point": null, "line": null, "polygon": "SRID=4326;POLYGON ((22.32421875 15.876809064146757, 51.85546875 15.876809064146757, 51.85546875 35.96022296929667, 22.32421875 35.96022296929667, 22.32421875 15.876809064146757))", "circle": null, "radius": null, "geometry": "{ \"type\": \"Polygon\", \"coordinates\": [ [ [ 22.32421875, 15.876809064146757 ], [ 51.85546875, 15.876809064146757 ], [ 51.85546875, 35.960222969296673 ], [ 22.32421875, 35.960222969296673 ], [ 22.32421875, 15.876809064146757 ] ] ] }", "success": true, "msg": "Story ok." }, { "id": 20, "name": "8MJH9H8J+MR", "point": null, "line": null, "polygon": "SRID=4326;POLYGON ((73.65234375 31.877557643340015, 109.51171875 31.877557643340015, 109.51171875 52.85586417785398, 73.65234375 52.85586417785398, 73.65234375 31.877557643340015))", "circle": null, "radius": null, "geometry": "{ \"type\": \"Polygon\", \"coordinates\": [ [ [ 73.65234375, 31.877557643340015 ], [ 109.51171875, 31.877557643340015 ], [ 109.51171875, 52.855864177853981 ], [ 73.65234375, 52.855864177853981 ], [ 73.65234375, 31.877557643340015 ] ] ] }", "success": true, "msg": "Story ok." } ], "date_type": "year", "season_name": "Winter", "year": 1998, "start_year": null, "end_year": null, "date": null, "creation_date": "2023-11-08T01:45:39.839469Z", "start_date": null, "end_date": null, "decade": null, "include_time": false, "likes": [], "success": true, "msg": "Story ok." }
It is removed so that we handled it by removing it because we are not using it.
For circle creation geometry field can be too long unnecessarily.
Need to solve it otherwise it uses to much storage and response size become bigger.
An example response :
{ "id": 18, "author": 1, "author_username": "cano14", "title": "TESTTT", "content": "<p>TESTTT</p>", "story_tags": "TESTTT", "location_ids": [ { "id": 12, "name": "FHQC+V4 Mutnitsa, Komi Republic, Rusya", "point": "SRID=4326;POINT (49.5703125 59.489726035537075)", "line": null, "polygon": null, "circle": null, "radius": null, "geometry": "{ \"type\": \"Point\", \"coordinates\": [ 49.5703125, 59.489726035537075 ] }", "success": true, "msg": "Story ok." }, { "id": 13, "name": "9PR7F4H8+7V", "point": "SRID=4326;POINT (105.1171875 66.47820814385636)", "line": null, "polygon": null, "circle": null, "radius": null, "geometry": "{ \"type\": \"Point\", \"coordinates\": [ 105.1171875, 66.478208143856364 ] }", "success": true, "msg": "Story ok." }, { "id": 14, "name": "968M45C7+CJ", "point": null, "line": null, "polygon": null, "circle": "SRID=4326;POINT (-86.8359375 56.12106042504407)", "radius": "654880.2464004400", "geometry": "{ \"type\": \"Polygon\", \"coordinates\": [ [ [ 654793.410462939995341, 56.121060425044071 ], [ 642210.07015889219474, -127704.67709183820989 ], [ 604943.619957814808004, -250555.699420191085665 ], [ 544426.188641669112258, -363775.850032201851718 ], [ 462983.427157368278131, -463014.142034443153534 ], [ 363745.135155127034523, -544456.903518744045869 ], [ 250524.984543116152054, -604974.334834889741614 ], [ 127673.962214763305383, -642240.785035967128351 ], [ -86.835937499959897, -654824.125340014928952 ], [ -127847.634089763218071, -642240.785035967128351 ], [ -250698.656418116064742, -604974.334834889741614 ], [ -363918.807030126801692, -544456.903518744162284 ], [ -463157.099032368219923, -463014.142034443211742 ], [ -544599.860516669228673, -363775.850032201851718 ], [ -605117.291832814808004, -250555.699420191143872 ], [ -642383.74203389219474, -127704.67709183844272 ], [ -654967.082337939995341, 56.121060424963872 ], [ -642383.74203389219474, 127816.91921268835722 ], [ -605117.291832814808004, 250667.941541041072924 ], [ -544599.860516669228673, 363888.092153051868081 ], [ -463157.099032368336339, 463126.384155293286312 ], [ -363918.807030126918107, 544569.145639594178647 ], [ -250698.656418116472196, 605086.576955739641562 ], [ -127847.634089763523662, 642353.027156817144714 ], [ -86.835937500120295, 654936.36746086506173 ], [ 127673.962214763290831, 642353.02715681726113 ], [ 250524.984543116268469, 605086.576955739757977 ], [ 363745.135155126743484, 544569.145639594295062 ], [ 462983.427157368161716, 463126.384155293402728 ], [ 544426.188641669112258, 363888.092153051984496 ], [ 604943.619957814575173, 250667.941541041538585 ], [ 642210.070158892078325, 127816.919212688590051 ], [ 654793.410462939995341, 56.121060425044071 ] ] ] }", "success": true, "msg": "Story ok." }, { "id": 15, "name": "98FJ4GJQ+8J", "point": null, "line": null, "polygon": null, "circle": "SRID=4326;POINT (-47.4609375 59.13086309725591)", "radius": "630717.7959481197", "geometry": "{ \"type\": \"Polygon\", \"coordinates\": [ [ [ 630670.33501061971765, 59.130863097255911 ], [ 618551.269416784052737, -122987.807049724098761 ], [ 582659.801529597956687, -241306.120144073502161 ], [ 524375.220331798889674, -350348.902001409500372 ], [ 445937.369592448638286, -445925.699666851316579 ], [ 350360.571927006822079, -524363.550406201626174 ], [ 241317.790069670794765, -582648.131604000693187 ], [ 122999.476975321391365, -618539.599491186789237 ], [ -47.460937499961382, -630658.66508502245415 ], [ -123094.398850321304053, -618539.599491186789237 ], [ -241412.711944670736557, -582648.131604000693187 ], [ -350455.493802006647456, -524363.550406201859005 ], [ -446032.291467448580079, -445925.699666851374786 ], [ -524470.14220679900609, -350348.902001409500372 ], [ -582754.723404597956687, -241306.120144073589472 ], [ -618646.191291784052737, -122987.807049724317039 ], [ -630765.25688561971765, 59.130863097178668 ], [ -618646.191291784052737, 123106.068775918669417 ], [ -582754.723404598073103, 241424.381870267970953 ], [ -524470.142206799122505, 350467.163727603910957 ], [ -446032.291467448696494, 446043.961393045843579 ], [ -350455.493802006763872, 524481.812132396153174 ], [ -241412.711944671114907, 582766.393330195103772 ], [ -123094.398850321609643, 618657.861217381316237 ], [ -47.460937500115861, 630776.92681121698115 ], [ 122999.476975321376813, 618657.861217381316237 ], [ 241317.79006967091118, 582766.393330195220187 ], [ 350360.571927006531041, 524481.812132396386005 ], [ 445937.369592448521871, 446043.961393045959994 ], [ 524375.220331798889674, 350467.163727604027372 ], [ 582659.801529597840272, 241424.381870268407511 ], [ 618551.269416784052737, 123106.068775918887695 ], [ 630670.33501061971765, 59.130863097255911 ] ] ] }", "success": true, "msg": "Story ok." }, { "id": 16, "name": "676G7WW9+J5", "point": null, "line": null, "polygon": "SRID=4326;POLYGON ((-69.08203125 -5.703447982149503, -45.87890625 11.781325296112277, -38.14453125 -13.325484885597936, -69.08203125 -5.703447982149503))", "circle": null, "radius": null, "geometry": "{ \"type\": \"Polygon\", \"coordinates\": [ [ [ -69.08203125, -5.703447982149503 ], [ -45.87890625, 11.781325296112277 ], [ -38.14453125, -13.325484885597936 ], [ -69.08203125, -5.703447982149503 ] ] ] }", "success": true, "msg": "Story ok." }, { "id": 17, "name": "3MPM+6C Gatos Güeros, N.L., Meksika", "point": null, "line": null, "polygon": "SRID=4326;POLYGON ((-99.31640625 25.085598897064752, -74.00390625 17.224758206624642, -85.25390625 3.4256915244180624, -99.31640625 25.085598897064752))", "circle": null, "radius": null, "geometry": "{ \"type\": \"Polygon\", \"coordinates\": [ [ [ -99.31640625, 25.085598897064752 ], [ -74.00390625, 17.224758206624642 ], [ -85.25390625, 3.425691524418062 ], [ -99.31640625, 25.085598897064752 ] ] ] }", "success": true, "msg": "Story ok." }, { "id": 18, "name": "885RMW2M+FC", "point": null, "line": "SRID=4326;LINESTRING (-43.06640625 33.65120829920497, -9.31640625 43.004647127794435, -0.87890625 21.861498734372567, -38.14453125 29.45873118535534)", "polygon": null, "circle": null, "radius": null, "geometry": "{ \"type\": \"LineString\", \"coordinates\": [ [ -43.06640625, 33.651208299204967 ], [ -9.31640625, 43.004647127794435 ], [ -0.87890625, 21.861498734372567 ], [ -38.14453125, 29.45873118535534 ] ] }", "success": true, "msg": "Story ok." }, { "id": 19, "name": "W39Q+CW المنجور Suudi Arabistan", "point": null, "line": null, "polygon": "SRID=4326;POLYGON ((22.32421875 15.876809064146757, 51.85546875 15.876809064146757, 51.85546875 35.96022296929667, 22.32421875 35.96022296929667, 22.32421875 15.876809064146757))", "circle": null, "radius": null, "geometry": "{ \"type\": \"Polygon\", \"coordinates\": [ [ [ 22.32421875, 15.876809064146757 ], [ 51.85546875, 15.876809064146757 ], [ 51.85546875, 35.960222969296673 ], [ 22.32421875, 35.960222969296673 ], [ 22.32421875, 15.876809064146757 ] ] ] }", "success": true, "msg": "Story ok." }, { "id": 20, "name": "8MJH9H8J+MR", "point": null, "line": null, "polygon": "SRID=4326;POLYGON ((73.65234375 31.877557643340015, 109.51171875 31.877557643340015, 109.51171875 52.85586417785398, 73.65234375 52.85586417785398, 73.65234375 31.877557643340015))", "circle": null, "radius": null, "geometry": "{ \"type\": \"Polygon\", \"coordinates\": [ [ [ 73.65234375, 31.877557643340015 ], [ 109.51171875, 31.877557643340015 ], [ 109.51171875, 52.855864177853981 ], [ 73.65234375, 52.855864177853981 ], [ 73.65234375, 31.877557643340015 ] ] ] }", "success": true, "msg": "Story ok." } ], "date_type": "year", "season_name": "Winter", "year": 1998, "start_year": null, "end_year": null, "date": null, "creation_date": "2023-11-08T01:45:39.839469Z", "start_date": null, "end_date": null, "decade": null, "include_time": false, "likes": [], "success": true, "msg": "Story ok." }