workunitservices.hpp 4.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. /*##############################################################################
  2. HPCC SYSTEMS software Copyright (C) 2012 HPCC Systems®.
  3. Licensed under the Apache License, Version 2.0 (the "License");
  4. you may not use this file except in compliance with the License.
  5. You may obtain a copy of the License at
  6. http://www.apache.org/licenses/LICENSE-2.0
  7. Unless required by applicable law or agreed to in writing, software
  8. distributed under the License is distributed on an "AS IS" BASIS,
  9. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  10. See the License for the specific language governing permissions and
  11. limitations under the License.
  12. ############################################################################## */
  13. #ifndef _WORKUNITSERVICES_INCL
  14. #define _WORKUNITSERVICES_INCL
  15. #ifdef _WIN32
  16. #define WORKUNITSERVICES_CALL _cdecl
  17. #else
  18. #define WORKUNITSERVICES_CALL
  19. #endif
  20. #ifdef WORKUNITSERVICES_EXPORTS
  21. #define WORKUNITSERVICES_API DECL_EXPORT
  22. #else
  23. #define WORKUNITSERVICES_API DECL_IMPORT
  24. #endif
  25. #include "hqlplugins.hpp"
  26. #include "workunit.hpp"
  27. #include "eclhelper.hpp"
  28. extern "C"
  29. {
  30. WORKUNITSERVICES_API bool getECLPluginDefinition(ECLPluginDefinitionBlock *pb);
  31. WORKUNITSERVICES_API void setPluginContext(IPluginContext * _ctx);
  32. }
  33. WORKUNITSERVICES_API char * WORKUNITSERVICES_CALL wsGetBuildInfo(void);
  34. WORKUNITSERVICES_API bool WORKUNITSERVICES_CALL wsWorkunitExists(ICodeContext *ctx, const char *wuid, bool online, bool archived);
  35. WORKUNITSERVICES_API void WORKUNITSERVICES_CALL wsWorkunitList( ICodeContext *ctx,
  36. size32_t & __lenResult,
  37. void * & __result,
  38. const char *lowwuid,
  39. const char *highwuid,
  40. const char *username,
  41. const char *cluster,
  42. const char *jobname,
  43. const char *state,
  44. const char *priority,
  45. const char *fileread,
  46. const char *filewritten,
  47. const char *roxiecluster,
  48. const char *eclcontains,
  49. bool online,
  50. bool archived,
  51. const char *appvalues);
  52. WORKUNITSERVICES_API char * wsWUIDonDate(unsigned year,unsigned month,unsigned day,unsigned hour,unsigned minute);
  53. WORKUNITSERVICES_API char * wsWUIDdaysAgo(unsigned daysago);
  54. WORKUNITSERVICES_API void WORKUNITSERVICES_CALL wsWorkunitTimeStamps( ICodeContext *ctx, size32_t & __lenResult, void * & __result, const char *wuid );
  55. WORKUNITSERVICES_API void WORKUNITSERVICES_CALL wsWorkunitMessages( ICodeContext *ctx, size32_t & __lenResult, void * & __result, const char *wuid );
  56. WORKUNITSERVICES_API void WORKUNITSERVICES_CALL wsWorkunitFilesRead( ICodeContext *ctx, size32_t & __lenResult, void * & __result, const char *wuid );
  57. WORKUNITSERVICES_API void WORKUNITSERVICES_CALL wsWorkunitFilesWritten( ICodeContext *ctx, size32_t & __lenResult, void * & __result, const char *wuid );
  58. WORKUNITSERVICES_API void WORKUNITSERVICES_CALL wsWorkunitTimings( ICodeContext *ctx, size32_t & __lenResult, void * & __result, const char *wuid );
  59. WORKUNITSERVICES_API IRowStream * WORKUNITSERVICES_CALL wsWorkunitStatistics( ICodeContext *ctx, IEngineRowAllocator * allocator, const char *wuid, bool includeActivities, const char * filterText);
  60. WORKUNITSERVICES_API bool WORKUNITSERVICES_CALL wsWorkunitTimings( ICodeContext *ctx, const char *wuid, const char * appname, const char *key, const char *value, bool overwrrite);
  61. #endif