You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pr@flagon.apache.org by "mdiep-cese (via GitHub)" <gi...@apache.org> on 2024/02/12 17:33:33 UTC
[PR] Pull request for issue #28 (flagon-distill)
mdiep-cese opened a new pull request, #29:
URL: https://github.com/apache/flagon-distill/pull/29
This ticket closes issue #28
The getUUID function is changed so that it can accommodates logs where the field clientTime are not present.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: pr-unsubscribe@flagon.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@flagon.apache.org
For additional commands, e-mail: pr-help@flagon.apache.org
Re: [PR] Pull request for issue #28 (flagon-distill)
Posted by "EandrewJones (via GitHub)" <gi...@apache.org>.
EandrewJones commented on PR #29:
URL: https://github.com/apache/flagon-distill/pull/29#issuecomment-1940146808
Let's move this discussion to a dedicated issue.
@mdiep-cese You can just make the minor changes for now and this should be good to go.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@flagon.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@flagon.apache.org
For additional commands, e-mail: notifications-help@flagon.apache.org
Re: [PR] Pull request for issue #28 (flagon-distill)
Posted by "EandrewJones (via GitHub)" <gi...@apache.org>.
EandrewJones commented on PR #29:
URL: https://github.com/apache/flagon-distill/pull/29#issuecomment-2223029183
Closing this PR as stale given that we're doing a fresh rewrite of Distill from the ground up. #41 solves move issues with unique log IDs.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@flagon.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@flagon.apache.org
For additional commands, e-mail: notifications-help@flagon.apache.org
Re: [PR] Pull request for issue #28 (flagon-distill)
Posted by "EandrewJones (via GitHub)" <gi...@apache.org>.
EandrewJones commented on code in PR #29:
URL: https://github.com/apache/flagon-distill/pull/29#discussion_r1486694293
##########
distill/utils/crud.py:
##########
@@ -38,12 +38,20 @@ def getUUID(log):
:return: A string representing a unique identifier for the log
"""
+ # Add session ID
+ UUID = str(log["sessionID"])
+
+ # Add timestmap from clientTime if exists, otherwise use endTime information
+ if log["logType"] == "interval":
+ UUID = UUID + str(log["endTime"])
+ else:
+ UUID = UUID + str(log["clientTime"])
Review Comment:
Same as above
##########
distill/utils/crud.py:
##########
@@ -38,12 +38,20 @@ def getUUID(log):
:return: A string representing a unique identifier for the log
"""
+ # Add session ID
+ UUID = str(log["sessionID"])
+
+ # Add timestmap from clientTime if exists, otherwise use endTime information
+ if log["logType"] == "interval":
+ UUID = UUID + str(log["endTime"])
Review Comment:
please use incremental syntax here:
`UUID += str(log["endTime"])`
##########
distill/utils/crud.py:
##########
@@ -38,12 +38,20 @@ def getUUID(log):
:return: A string representing a unique identifier for the log
"""
+ # Add session ID
+ UUID = str(log["sessionID"])
+
+ # Add timestmap from clientTime if exists, otherwise use endTime information
+ if log["logType"] == "interval":
+ UUID = UUID + str(log["endTime"])
+ else:
+ UUID = UUID + str(log["clientTime"])
+
+ # Add logtype information
+ UUID = UUID + str(log["logType"])
+
+ # Add type information, if it exists
if "type" in log:
Review Comment:
Is this to differentiate between two logs with the same session ID and same client/endTime but of different types?
##########
distill/utils/crud.py:
##########
@@ -38,12 +38,20 @@ def getUUID(log):
:return: A string representing a unique identifier for the log
"""
+ # Add session ID
+ UUID = str(log["sessionID"])
+
+ # Add timestmap from clientTime if exists, otherwise use endTime information
+ if log["logType"] == "interval":
+ UUID = UUID + str(log["endTime"])
+ else:
+ UUID = UUID + str(log["clientTime"])
+
+ # Add logtype information
+ UUID = UUID + str(log["logType"])
Review Comment:
Here too
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@flagon.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@flagon.apache.org
For additional commands, e-mail: notifications-help@flagon.apache.org
Re: [PR] Pull request for issue #28 (flagon-distill)
Posted by "EandrewJones (via GitHub)" <gi...@apache.org>.
EandrewJones closed pull request #29: Pull request for issue #28
URL: https://github.com/apache/flagon-distill/pull/29
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: pr-unsubscribe@flagon.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@flagon.apache.org
For additional commands, e-mail: pr-help@flagon.apache.org
Re: [PR] Pull request for issue #28 (flagon-distill)
Posted by "Jyyjy (via GitHub)" <gi...@apache.org>.
Jyyjy commented on PR #29:
URL: https://github.com/apache/flagon-distill/pull/29#issuecomment-1940018667
> This indeed fixes the problem. However, it's unclear why we need to construct an id from the individual field values in the log.
>
> Questions:
>
> * How is this function used elsewhere in the codebase?
>
> * Do we want/need to be able to parse the id to retrieve those values in some way?
>
> * Do we want our ids to have a partial-logical ordering?
>
>
> If the only requirement is to generate a uuid, then why not just use `str(uuid.uuid4())` and call it a day? We'll never get a collision.
>
> Tagging @Jyyjy or @amirmghaemi
As the package is written, getUUID has to return the same value when the same log is passed in. `str(uuid.uuid4())` will create a different uuid when the same log is passed. hash() might be a better option.
1. getUUID isn't really used within the distill package. Users are expected to use it to create a dictionary mapping UUID to logs. Then that dictionary is whats passed to the segmentation functions. This is one of the biggest pains of working with distill, you have to manage the UUID's and dictionary of logs yourself.
2. No, all that info is in the log, which the UUID (assuming the user set things up correctly) maps to.
3. Not sure exactly what you mean. One of the assumptions of the segmentation functions is that the user sorts the log dictionary by clienttime.
Also, the reason @mdiep-cese ran into this issue is that interval logs have some inconsistencies in userale, and we have historically filtered out all interval logs. I'm not sure about the details, but that's been josh's guidance. [This](https://github.com/apache/flagon-useralejs/issues/13) may be the relevant ticket. But my point is that nothing in this package is built to deal with interval logs.
Distill is even less mature than userale. The upside is that we can change things a lot without really affecting anyone. I'm team fresh rewrite.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@flagon.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@flagon.apache.org
For additional commands, e-mail: notifications-help@flagon.apache.org