Description
I have got a mqtt stream (beacon_stream) and table in PostgresQL (beacon_table), which was added to eKuiper as lookup table. So i created a rule via SQL to query from stream and table (inner join beacon_stream.id = beacon_table.id) which sinks to log file. The rule works but every other time i get error :
sql source meet column id unknown columnType:INT4" file="sql/source.go:278" rule=test_rule
The rule queries data from the same table in PostgresQL...
So i wanted to try to debug app in VSCode and i stumbled across the fact i can't load sql source plugin (i get error when i try to create lookup table "lookup source type sql not found") while debugging. If i build eKuiper via existing Makefile and run /bin/kuiperd sql plugin is loaded fine and lookup sql table can ve created. But when i run the code in VSCode i get error in file /usr/local/go/src/runtime/plugin.go (function plugin_lastmoduleinit(), line 54):
for _, pkghash := range md.pkghashes { if pkghash.linktimehash != *pkghash.runtimehash { md.bad = true return "", nil, nil, "plugin was built with a different version of package " + pkghash.modulename } }
The sql plugin was built as described in docs:
go build -trimpath --buildmode=plugin -o plugins/sources/Sql.so extensions/sources/sql/*.go
The launch.json is:
{ "name": "Launch file", "type": "go", "request": "launch", "mode": "debug", "program": "${file}", "env": { "GO111MODULE": "on", "CGO_ENABLED": "1" } }
Maybe i should apply different launch options to run the app properly?