Title
#fleet
k

Kun Nan

09/08/2021, 1:03 AM
Hi, I find that fleet still import old version of kolide/launcher,and the logger of old version of lancher does not use level to distinguish different level of logshttps://github.com/fleetdm/fleet/blob/main/go.mod#L47 take "RequestQueries" for example • the imported version
func (mw logmw) RequestQueries(ctx context.Context, nodeKey string) (res *distributed.GetQueriesResult, reauth bool, err error) {
	defer func(begin time.Time) {
		resJSON, _ := json.Marshal(res)
		uuid, _ := uuid.FromContext(ctx)
		mw.logger.Log(
			"method", "RequestQueries",
			"uuid", uuid,
			"res", string(resJSON),
			"reauth", reauth,
			"err", err,
			"took", time.Since(begin),
		)
	}(time.Now())

	res, reauth, err = mw.next.RequestQueries(ctx, nodeKey)
	return
}
• the newest version
func (mw logmw) RequestQueries(ctx context.Context, nodeKey string) (res *distributed.GetQueriesResult, reauth bool, err error) {
	defer func(begin time.Time) {
		resJSON, _ := json.Marshal(res)
		uuid, _ := uuid.FromContext(ctx)
		logger := level.Debug(mw.logger)
		if err != nil {
			logger = <http://level.Info|level.Info>(mw.logger)
		}
		logger.Log(
			"method", "RequestQueries",
			"uuid", uuid,
			"res", string(resJSON),
			"reauth", reauth,
			"err", err,
			"took", time.Since(begin),
		)
	}(time.Now())

	res, reauth, err = mw.next.RequestQueries(ctx, nodeKey)
	return res, reauth, err
}
Martavis Parker

Martavis Parker

09/09/2021, 3:05 PM
Hi, Kun. Are you requesting that we update the version of kolide?
k

Kun Nan

09/10/2021, 5:36 AM
Hi,Martavis Parker Yes,if there is any consideration of not upgrading the kolide/launcher version which fleet import ,please let me know,thank you so much!