Comments (5)
Hello! I recommend posting this question in our Community Slack or Community Forums, we have a lot of talented community members there who could help answer your question more quickly. You can also learn more about Telegraf by enrolling at InfluxDB University for free!
Heads up, this issue will be automatically closed after 7 days of inactivity. Thank you!
from telegraf.
@JW623 without seeing the JSON input data, your (redacted) configuration and the output you expect it is really hard to say anything... Please also use the support channels suggested by our bot (forum & slack) for support questions like this!
from telegraf.
@JW623 without seeing the JSON input data, your (redacted) configuration and the output you expect it is really hard to say anything... Please also use the support channels suggested by our bot (forum & slack) for support questions like this!
Sorry my bad, here is my telegraf configuration
[[inputs.file]]
files = [""]
tagexclude = ["Status"]
data_format = "json"
tag_keys = ["Client", "Asset", "Tag", "Timestamp"]
json_time_key = "Timestamp"
json_time_format = "2006-01-02 02:00:00.0000000"
tagdrop = ["Status"]
[[outputs.postgresql]]
connection = "host=localhost user=s password= dbname="
schema = "public"
name_override = ""
my json data
[
{
"Client": "B",
"Asset": "ABCASSET",
"Tag": "ABCTAG",
"Value": 12.1235,
"Status": 192,
"Timestamp": "2023-08-17 02:00:00.0000000"
},
{
"Client": "A",
"Asset": "ABCASSET",
"Tag": "ABCTAG",
"Value": 13.1235,
"Status": 192,
"Timestamp": "2023-08-17 02:00:00.0000000"
},
{
"Client": "B",
"Asset": "ABCASSET",
"Tag": "ABCTAG",
"Value": 13.1235,
"Status": 192,
"Timestamp": "2023-08-17 03:00:00.0000000"
},
{
"Client": "A",
"Asset": "ABCASSET",
"Tag": "ABCTAG",
"Value": 14.1235,
"Status": 192,
"Timestamp": "2023-08-17 03:00:00.0000000"
}
]
i would like to ignore Status from my data collection
from telegraf.
Status
is not a tag but a field so using
[[inputs.file]]
files = ["test_configs/jsontest_issue_15067.json"]
data_format = "json"
tag_keys = ["Client", "Asset", "Tag"]
json_time_key = "Timestamp"
json_time_format = "2006-01-02 02:00:00.0000000"
fieldexclude = ["Status"]
will solve your issue!
from telegraf.
fieldexclude = ["Status"]
Yes it works ! thanks alot!
from telegraf.
Related Issues (20)
- docs: create a documentation for agent HOT 5
- not reporting when failed index in the opensearch HOT 11
- wrong timestamp in line protocol "influx" file input HOT 1
- telegraf mqtt output plugin. Missing information HOT 2
- feat(processors.parser): Add base64 decode option HOT 4
- feat: exclude tags or fields after input HOT 1
- feat: add path tag to file input HOT 2
- Scale processor example doesn't work HOT 1
- Add metrics to monitor SQL Server Persistent Version Store (PVS) within Accelerated Database Recovery (ADR) HOT 1
- modbus "register" configuration style: registers with 'big' addresses are not read HOT 2
- jolokia2_agent cassandra example config missing per table and all table metrics HOT 2
- add power_limit to nvidia_smi HOT 6
- the gnmi input plugin should support the gRPC Keepalive configuration HOT 1
- [inputs.diskio] diskInfo() is reading from the wrong /sys interface "/sys/block/" should be "/sys/class/block/" HOT 4
- Add Process Filter Rule Type HOT 2
- Timezone Not Inlcuded in Backup in SQL Server input HOT 2
- [aggregators.derivative] plugin not working HOT 1
- inputs.knx_listener: add support for String data type HOT 2
- json_v2 parsers doesn't support object measurement_name_path HOT 3
- Systemd does not wait until telegraf shuts down gracefully HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from telegraf.