benchmark_app.dart 699 B

123456789101112131415161718
  1. import 'dart:async';
  2. import 'package:angel3_framework/angel3_framework.dart';
  3. import 'package:file/local.dart';
  4. import 'src/config/config.dart' as configuration;
  5. import 'src/routes/routes.dart' as routes;
  6. import 'src/services/services.dart' as services;
  7. /// Configures the server instance.
  8. Future configureServer(Angel app) async {
  9. // Grab a handle to the file system, so that we can do things like
  10. // serve static files.
  11. var fs = const LocalFileSystem();
  12. // Set up our application, using the plug-ins defined with this project.
  13. await app.configure(configuration.configureServer(fs));
  14. await app.configure(services.configureServer);
  15. await app.configure(routes.configureServer(fs));
  16. }