question

robert avatar image
robert asked

Event History / Search for custom data

Using the analytics/event history tab in the Dashboard, is it possible to search for custom events with custom data?

For example, we write following events:

{
    "EventName": "player_show_offer",
    "EventNamespace": "---",
    "Source": "----",
    "EntityType": "player",
    "TitleId": "----",
    "EventId": "bf3ebc94b3ba4d33bafe5d5c30f03312",
    "EntityId": "---",
    "SourceType": "GameServer",
    "Timestamp": "2017-09-20T04:43:41.922042Z",
    "History": null,
    "CustomTags": null,
    "Reserved": null,
    "ItemID": "OfferStarterPack"
}

We can list all such events with the query "eventData.eventName:player_show_offer".

But it looks like following query doesn't return anything:
"eventData.eventName:player_show_offer AND eventData.itemId:OfferStarterPack"

Is this not supported?

(currently we write additional events in the form "player_show_offer_[offername]" so that we can at least get an overview of all posted offers with "player_show_offer_*"

Thanks

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

brendan avatar image
brendan answered

It looks like the custom data elements don't work quite the same way in our search tool. This query works fine for what you're trying to get to, though:

eventData.eventName:player_show_offer AND eventData.ItemID=OfferStarterPack

I'll file a work item for us to go through and document that better.

5 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

robert avatar image robert commented ·

Ah, thats great. works fine, but one more thing...

Is it possible to group the results based on such a custom data to show the count of each such event in the graph?

e.g. show all player_show_offer events, grouped by eventData.itemID ?

If this works too we can get rid of unique events for each offer/notification/etc... and cleanup our code massively.

Thanks!

0 Likes 0 ·
brendan avatar image brendan robert commented ·

Sorry, no - grouping isn't something you can really do with custom data. However, you can still clean up the code considerably, if you use Snowflake. Bear in mind that the Event History is only the set of events that fall within your retention period. If you're using our Snowflake integration, you can query across all events for the lifetime of the game.

0 Likes 0 ·
robert avatar image robert brendan commented ·

Well, teaching another tool/framework to our team members may be a bit too much for the moment.

With grouping I just mean being able to see the totals in graph for each event, for following query for example:

eventData.eventName:player_show_offer AND eventData.ItemID=*

Would be great if we can get the usual bar graphs to have a glue which event happened how often. Right now it just shows one bar with player_show_offer (2823) for example.

Just one more question, tried following query:

player_disconnected AND eventData.Finished=true (where Finished is a bool, either false or true)

but for some reason this query returns all player_disconnected events, even the one where Finished=false (also tried, 0, 1, TRUE, FALSE, !true, etc..).

Any special syntax required to check for boolean?

Thanks a lot!

0 Likes 0 ·
Show more comments
hromoydron avatar image
hromoydron answered

It's body of my custom event

{
    "EventName": "winLevel",
    "EventNamespace": "title.97E1",
    "Source": "97E1",
    "EntityType": "player",
    "TitleId": "97E1",
    "EntityId": "57F365BA21594CAE",
    "EventId": "c485387c0c274da7ae2ca0ff4b6a6fde",
    "SourceType": "GameClient",
    "Timestamp": "2018-10-30T13:53:43.3441998Z",
    "History": null,
    "CustomTags": null,
    "Reserved": null,
    "PlayFabEnvironment": {
        "Vertical": "master",
        "Cloud": "main",
        "Application": "mainserver",
        "Commit": "285b2c2"
    },
    "levelNumber": 1,
    "complication": "Easy",
    "gameMode": "Income",
    "wave": 3,
    "currentHealth": 19,
    "time": 47.79904,
    "aCount": 10,
    "bCount": 31,
    "mCount": 0,
    "hCount": 0,
    "items": {},
    "skills": {
        "MarksmanRange": 1
    } 

}

How I can get all events with levelNumber=3

Query eventData.levelNumber=3 don't working correctly. Because '=' equal ' ' that equal OR

eventData.levelNumber:3 also don't working

3 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

brendan avatar image brendan commented ·

Interesting. This query seems to work fine for the results you want:

eventData.EventName=StartLevel AND eventData.levelNumber=3

However, you're correct that changing the EventName to your "winLevel" then causes the levelNumber specifier to not apply. I'll open a bug on this, to have the engineering team look into it.

0 Likes 0 ·
hromoydron avatar image hromoydron brendan commented ·

Its very strange

eventData.EventName=StartLevel AND eventData.levelNumber=3
eventData.EventName=StartLevel AND eventData.levelNumber=2

works fine. while

eventData.EventName=StartLevel AND eventData.levelNumber=1

not working correctly as well as query with winLevel

So, thank you for creating bug report.

0 Likes 0 ·
brendan avatar image brendan hromoydron commented ·

Quick follow-up: Since custom data cannot be indexed the same way our pre-existing event fields are in the Elasticsearch cache, we can't support them in search filters (which is also why they aren't supported in Group/Sum operations).

0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.