Commit Graph

28 Commits

Author SHA1 Message Date
Hossein
79ce416896
GH-1805: Replace unfurl link with card title (#1869)
* <Jump To Card>

* GOALNG Ci lint error

* ToDo Comment for internationalize Jump To Card
2021-11-25 09:05:32 -05:00
Miguel de la Cruz
e7c38c8822
Adds data migrations and the unique IDs migration (#1776)
* Adds data migrations and the unique IDs migration

* Adds GetSystemSetting tests

* Add log statements to data migrations

* Move migrations to the store and ensure they follow an order mixing database and data migrations

* Fix system settings

* Add tests for unique id migration

* Small comment change

* Make a couple of methods private and wrap the migration in a transaction

* Update public methods

* Add database mutex to data migrations

* Create server params and pass a mutex factory to the store

* Fix plugin linter

* Make isPlugin private

* Fix comment typo

Co-authored-by: Doug Lauder <wiggin77@warpmail.net>

Co-authored-by: Doug Lauder <wiggin77@warpmail.net>
2021-11-11 17:01:43 +01:00
Hossein
520f1e65e7
minimum changes required (#1763) 2021-11-09 14:50:54 -05:00
Scott Bishel
f74eea11ba
Fix for feature flag handling (#1753)
* fix for handling feature flags changing

* update tests

* fix tests

* lint fixes

* feedback updates

* use getConfig instead

* linter fix

* more linter

* revert changes

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2021-11-09 07:56:04 -07:00
Scott Bishel
9b9682f626
Create FeatureFlags in configurations (#1622)
* create FeatureFlags in configurations

* update for unit tests

* update unit tests, go.mod

* update go.sum

* fix lint errors

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2021-11-01 19:12:43 -06:00
Hossein
eed1f86c15
Unfurl Focalboard Link (#1081) 2021-10-22 12:13:31 -04:00
Doug Lauder
d49a802c3c
fix card URLs with no viewid (#1571)
* fix card URLs with no viewid

* revert ServerRoot change
2021-10-15 14:23:35 -04:00
Scott Bishel
838c6f90b7
Config for share board (#1187)
* initial commit for setting shared board configuration

* add unit test

* working again

* update default config

* initial commit for setting shared board configuration

* add unit test

* working again

* update default config

* add unit tests, some clean up

* more cleanup

* more clean up

* remove header text for GH-1105

* remove unnecessary logs

* update text

* fix lint errors

* more lint fixes

* webapp lint fixes

* Update mattermost-plugin/plugin.json

Co-authored-by: Justine Geffen <justinegeffen@users.noreply.github.com>

* Update mattermost-plugin/plugin.json

Co-authored-by: Justine Geffen <justinegeffen@users.noreply.github.com>

* update for review, sync with main

Co-authored-by: Justine Geffen <justinegeffen@users.noreply.github.com>
2021-09-16 13:31:02 -06:00
Miguel de la Cruz
f7946821a0
Propagate block changes to all of the cluster nodes in plugin mode (#1213)
Co-authored-by: Jesús Espino <jespinog@gmail.com>
2021-09-16 12:18:11 +02:00
Doug Lauder
a76385268e
MM-38342 plugin logging (#1193)
- bump chat server version
- plugin logging adapter
2021-09-15 09:01:05 -04:00
Doug Lauder
8425f53b2a
@mention support (#1147) 2021-09-13 15:36:36 -04:00
Harshil Sharma
08db4fed61
Workspace switcher (#1052)
* API WIP

* WIP

* Finished changes

* Fixed colors:

* Don't enforce charset adn collation in migration, pick from database DSN

* Added MySQL query

* Updated mocks

* Added tests

* Lint fixes

* Fixed typo and removed unsed style

* Checked in a snapshot

* Updated snapshot

* Updated Cypress test

* Updated Cypress test

* Updated Cypress test

* Fixed review comments

* Fixed tests

* Added default collation for MySQL

* Added documentation for ensuring correct database collation

* Updated migrations

* Fixed a bug with collation

* Fixed lint errors

* Used correct collation

* debugging

* Updating css

* Minor UI changes

* USe inbuilt default collation

* Used only charset for mysql

* Fixed linter issue:

* Added migration for matching collation

* Reverted local config changes

* Reverted local config changes

* Handled the case of personal server running on MySQL

* WIP

* Now running collation matching migration onlyt for plugins

* Minor optimization

* Multiple review fixes

* Added group by clause to primary query

* Supported for subpacth

Co-authored-by: Asaad Mahmood <asaadmahmood@users.noreply.github.com>
2021-09-08 10:22:03 +05:30
Scott Bishel
94e6e8a9f7
Plugin telemetry (#1069)
* implement webapp telemetry

* cleanup

* remove imports, update events

* change event title

* update for lint

* add test, update filename

* linter fix

* fix field name

* revert changes

* fix test

* update builds

* fix workflows

* fix workflows

* fix workflow

* temp checkin

* remove log lines

* updates from peer review
2021-09-01 15:53:27 -06:00
Miguel de la Cruz
e10229031f
Add a plugin adapter to reuse MM websocket in plugin mode (#1079)
* Add a plugin adapter to reuse MM websocket in plugin mode

* Remove development replace

* Switch all go.mod files to use 1.16

* Fix linter issues

* Fix linter

* Update server version to contain the new hooks
2021-08-27 10:59:14 +02:00
Doug Lauder
b58497e2ea
Replace mlog with server v6 mlog (#1088)
* replace mlog with server v6 mlog
* remove FB mlog from plugin
2021-08-25 16:08:01 -04:00
Miguel de la Cruz
f9c76d8129
Update focalboard to be compatible with mattermost v6 (#1020)
* Update focalboard to be compatible with mattermost v6

* Point to the new plugin API version

* Fix collectors linter issues

* Move all CI jobs to 1.16
2021-08-24 12:13:58 +02:00
Chen-I Lim
904dfc2158
Add server id to plugin telemetry (#903) 2021-08-06 12:03:56 -07:00
Doug Lauder
efedf2f481
Fix nil stringer error (#788)
* fix nil stringer error
* include API path with all API ERROR logs
* enable "caller" field
* disable colour output and min msg length for plugin
* bump Logr version to v2.0.4
2021-07-27 12:57:29 -04:00
Doug Lauder
0dec704ddc
fix linter errors in plugin (#696) 2021-07-09 12:59:44 +02:00
Doug Lauder
ebd477464b
fix remaining golangci linter warnings (#686)
* fix remaining linter warnings
2021-07-08 21:09:02 -04:00
Miguel de la Cruz
4328375324
Prevent plugin from crashing if SiteURL is not set (#677)
* Prevent plugin from crashing if SiteURL is not set

* Change default baseURL to be . instead of empty string

* Revert "Change default baseURL to be . instead of empty string"

This reverts commit cceb380167.
2021-07-07 10:13:06 +05:30
Doug Lauder
6e214ebc3d
Ensure all code paths close *sql.Rows (#679)
* ensure all code paths close *sql.Rows
2021-07-06 16:44:11 -04:00
Jesús Espino
bb7867c2cb Configuring the logs by default in the plugin 2021-07-02 18:07:30 +02:00
Agniva De Sarker
8e72b9c528
Add RPC API support to plugin (#619)
* Add RPC API support to plugin

We use the mattermost-plugin-api client to create the sql.DB object
and pass it to the store.

To keep a common point of entry for both the standalone server
and plugin, we refactor the store creation part out of server.New
and pass the DB as a dependency to the server constructor.

This allow us to create different stores in plugin and standalone,
so that the server code remains unaware of any differences.

https://focalboard-community.octo.mattermost.com/workspace/zyoahc9uapdn3xdptac6jb69ic?id=285b80a3-257d-41f6-8cf4-ed80ca9d92e5&v=495cdb4d-c13a-4992-8eb9-80cfee2819a4&c=c7386db7-65fd-469b-8bcf-8dc8f8e61e4f

* Support linux desktop app

* refactor

* fix typos

* Change authlayer to use existing DB conn too
2021-06-25 16:49:06 +02:00
Miguel de la Cruz
fd9be03445
Use path.Join in plugin's webpath property (#610)
* Use path.Join in plugin's webpath property

* Update mattermost-plugin/server/plugin.go

Co-authored-by: Jesús Espino <jespinog@gmail.com>

Co-authored-by: Jesús Espino <jespinog@gmail.com>
2021-06-21 12:08:33 +02:00
Miguel de la Cruz
bf18d39242
Fixes web files not found when plugin directory is custom (#609) 2021-06-21 11:22:58 +02:00
Doug Lauder
68d492a855
Bump Logr version to fix Windows build (#520)
* bump Logr version to fix Windows build

* fix return args for syslog_unsupported
2021-06-04 08:43:32 +02:00
Jesús Espino
f1b8d88d6b
Changing mattermost-auth method to work based on shared database access (#335)
* Improving mattermost auth implementation

* Making mattermost-auth based on shared database access

* Reverting unneeded changes in the config.json file

* Fixing tiny problems

* Removing the need of using the mattermost session token

* Fixing some bugs and allowing to not-bind the server to any port

* Small fix to correctly get the templates

* Adding the mattermost-plugin code inside focalboard repo

* Adding a not working code part of the cluster websocket communication

* Updating the mattermost version

* Adding the cluster messages for the websockets

* Updating to the new node version

* Making it compatible with S3

* Addressing some tiny problems

* Fixing server tests

* Adds support for MySQL migrations and initialization

Co-authored-by: Miguel de la Cruz <miguel@mcrx.me>
2021-05-24 19:06:11 +02:00