appbaseio / appbaseio/abc

src_filter not working

未关闭
#178 2 条评论 2 个 reaction 已指派 0 人 在 GitHub 查看
主要语言
Go
星标
471
派生
47
PR 合并指标
30 天内没有已合并 PR

描述

```
abc --version
Version: 0.6.7
Variant: !oss
Go version: go1.11.1
OS: linux
Arch: amd64
```

I'm trying to import only one collection from a mongodb database which has three collections, but I think because two of my collections are similarly named the regex picks up both, this then fails in elastic because it tries to create two mapping types, e.g. I see this on the import:

```
INFO[0000] Connection to mongo_server:27017 established.
INFO[0000] collection count db="data" num_collections=3
INFO[0000] adding for iteration... collection="market_raw_data" db="data"
INFO[0000] adding for iteration... collection="raw_data" db="data"
INFO[0000] skipping iteration... collection=updateQueue db="data"
INFO[0000] done iterating collections db="data"
```

My transform file looks like:

```
t.Source("source", source, "/raw_data/")
.Mapping({
"raw_data": {
"properties":{
"mongo_id" : {
"properties" : {
"date": {
"type":"date",
"format": "yyyyMMdd"
}
}
}
}
}
})
// more transforms
.Save("sink", sink, "/.*/")
```
How can I exclude it from picking up this collection:

`INFO[0000] adding for iteration... collection="market_raw_data" db="data"
`

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。