Skip to content

Commit

Permalink
[TSVB][performance] remove visPayloadSchema.validate (#97091) (#97105)
Browse files Browse the repository at this point in the history
* [TSVB][performance] remove visPayloadSchema.validate

Part of: #97061

* Update vis.ts
  • Loading branch information
alexwizp committed Apr 14, 2021
1 parent 630d4bb commit 2693cf5
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions src/plugins/vis_type_timeseries/server/routes/vis.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
import { schema } from '@kbn/config-schema';
import { ensureNoUnsafeProperties } from '@kbn/std';
import { getVisData } from '../lib/get_vis_data';
import { visPayloadSchema } from '../../common/vis_schema';
import { ROUTES } from '../../common/constants';
import { Framework } from '../plugin';
import type { VisTypeTimeseriesRouter } from '../types';
Expand All @@ -34,14 +33,6 @@ export const visDataRoutes = (router: VisTypeTimeseriesRouter, framework: Framew
});
}

try {
visPayloadSchema.validate(request.body);
} catch (error) {
framework.logger.debug(
`Request validation error: ${error.message}. This most likely means your TSVB visualization contains outdated configuration. You can report this problem under https://github.com/elastic/kibana/issues/new?template=Bug_report.md`
);
}

const results = await getVisData(requestContext, request, framework);
return response.ok({ body: results });
}
Expand Down

0 comments on commit 2693cf5

Please sign in to comment.