{"id":13691974,"url":"https://github.com/SoftwareAG/adabas-admin-restful-client","last_synced_at":"2025-05-02T16:31:03.163Z","repository":{"id":48232327,"uuid":"152404921","full_name":"SoftwareAG/adabas-admin-restful-client","owner":"SoftwareAG","description":"Software AG Adabas RESTful client administration generated using the Adabas RESTful server SWAGGER definition","archived":false,"fork":false,"pushed_at":"2023-03-07T01:55:47.000Z","size":1059,"stargazers_count":5,"open_issues_count":5,"forks_count":5,"subscribers_count":6,"default_branch":"master","last_synced_at":"2024-08-03T17:13:02.832Z","etag":null,"topics":["adabas","administration","golang","rest-api"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/SoftwareAG.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2018-10-10T10:20:38.000Z","updated_at":"2022-02-02T10:55:33.000Z","dependencies_parsed_at":"2024-04-08T02:03:02.210Z","dependency_job_id":"f01b3e0c-9281-46d5-9663-381366e6dec8","html_url":"https://github.com/SoftwareAG/adabas-admin-restful-client","commit_stats":{"total_commits":44,"total_committers":7,"mean_commits":6.285714285714286,"dds":0.5909090909090908,"last_synced_commit":"73b359dbde3cd1f35a1cc794f871058041836b96"},"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SoftwareAG%2Fadabas-admin-restful-client","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SoftwareAG%2Fadabas-admin-restful-client/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SoftwareAG%2Fadabas-admin-restful-client/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SoftwareAG%2Fadabas-admin-restful-client/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SoftwareAG","download_url":"https://codeload.github.com/SoftwareAG/adabas-admin-restful-client/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224319514,"owners_count":17291855,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["adabas","administration","golang","rest-api"],"created_at":"2024-08-02T17:00:52.177Z","updated_at":"2024-11-12T17:32:33.251Z","avatar_url":"https://github.com/SoftwareAG.png","language":"Go","funding_links":[],"categories":["Adabas and Natural"],"sub_categories":["![icon-Adabas-64x64](https://user-images.githubusercontent.com/23717841/230384852-da5ff0f6-5283-447d-9072-43b2c740d535.png) Adabas","adapya – Adabas Python packages"],"readme":"# Adabas RESTful administration client\n\nThis code contains a sample use case of Adabas RESTful administration.\nThe Swagger definition delivered in the Adabas RESTful administration server can be used to\ngenerate a RESTful clients.\n\nThe example shows how Adabas administration tasks can be generated using Swagger generators.\nThis examples uses the programming language GO but you can use  the Swagger definition with other programming languages like Angular, Python or specific Java frameworks as well.\n\nThis example can be generated using GO 1.8 or higher.\n\nThe result is a command line access to the Adabas RESTful administration.\n\n## Build\n\nThe build process needs an installed GO (golang) compiler. The build works on Linux. It is also possible to build a Windows version using the `GOOS=windows` parameter. The build infrastructure of GO requires web access to download required dependencies.\n\nThe command line is generated using:\n\n```bash\nmake\n```\n\nYou can regenerate sources out of Swagger definitions by using:\n\n```bash\nmake generate\n```\n\nAll directories except the `cmd` directory \ncontain generated source.\n\n## Generate binaries\n\nThe binary are located in the corresponding `bin/${GOOS}_${GOARCH}` directory. You can create cross operating system binaries. On Linux the `make` command will generate a Linux binary call `client`.\n\nIf you'd like to generate a Windows binary, you need to provide an additional environment variable `GOOS`. For example, to build for Windows, the following command needs to be entered.\n\n```bash\nmake GOOS=windows\n```\n\nThe final platform is independent of the platform Adabas is working.\n\n## Runtime\n\nBeside the direct usage of the client you might use the `startAdmin.sh` script for a quick start.  In this case it might be necessary to import dependent packages using the `go get \u003cpackage\u003e` command. The `startAdmin.sh` script provides all help descriptions entering the  `help` command.\n\nThe client has a `-url` option.\nThis option can be used to reference the REST server location. It is possible to use `\u003chost\u003e:\u003cport\u003e` to specify an HTTP access. To connect to an HTTPS connection, the URL needs to specify the SSL connection with `https://\u003chost\u003e:\u003curl\u003e`. A preset URL can be set using the environment variable `ADABAS_ADMIN_URL`. To avoid entering the password for each request, you can set the environment `ADABAS_ADMIN_PASSWORD`.\n\nIf the certificate is for internal use without public certification, you may switch off validation using the `-ignoreTLS` switch.\n\n## List Adabas databases\n\nThis will list all available databases on the remote server.\n\n![Image of usage](images/demo.gif)\n\n```sh\nclient -url \u003chost\u003e:\u003cport\u003e list\n```\n\nExample output would be like this\n\n```sh\n2018/10/10 12:40:54 Adabas Administration RESTful client started\n\n2018/10/10 12:40:54 Server: linhost:8390\n2018/10/10 12:40:54 User:   admin\n\nEnter Password:\n Dbid   Name                  Active    Version\n\n  001 [TestDatabase    ]      false    Adabas v6.6 (20)\n  015 [SAMPLE_DB       ]      false    Adabas v6.6 (20)\n  050 [GENERAL_DATABASE]      false    Adabas v6.5 (19)\n  075 [GENERAL_DATABASE]      false    Adabas v6.7 (21)\n  102 [GENERAL_DATABASE]      false    Adabas v6.6 (20)\n  155 [SAMPLE_DB       ]      false    Adabas v6.7 (21)\n  195 [DEMODB          ]      false    Adabas v6.7 (21)\n\n\n2018/10/10 12:40:57 Adabas Administration RESTful client took 61.262267ms terminated\n```\n\n## Adabas database information\n\nWith `-dbid` and `-fnr` you may define a corresponding database parameter:\n\n```sh\nclient -url \u003chost\u003e:\u003cport\u003e -dbid \u003cdbid\u003e -fnr \u003cfnr\u003e file\n```\n\nExample output would be like this:\n\n```sh\n2018/10/10 12:59:12 Adabas Administration RESTful client started\n\n2018/10/10 12:59:12 Server: linhost:8390\n2018/10/10 12:59:12 User:   admin\n\nEnter Password:\n\nDatabase 195 file 011:\n\nName                : EMPLOYEES-NAT\nNumber              : 11\nLast modification   : 2014-Jul-15 15:46:10:000 UTC\nFlags               : ISN_REUSAGE,SPACE_REUSAGE\nISN count           : 1,107\nTop ISN             : 1,108\nMaximum ISN         : 73,727\nMax.MU Occurence    : 0\nPadding factor ASSO : 5\nPadding factor DATA : 5\nMax.record length   : 32,764\nStructure level     : 4\nRoot file           : 0\nLob file            : 0\nRecord count        : 1,107\nSecurity info       : 0\nAC extents\n - First RABN   : 2,574\n   Last RABN    : 2,582\n   Free or Isn  : 0\nDS extents\n - First RABN   : 267\n   Last RABN    : 298\n   Free or Isn  : 275\nNI extents\n - First RABN   : 229\n   Last RABN    : 318\n   Free or Isn  : 255\nUI extents\n - First RABN   : 319\n   Last RABN    : 333\n   Free or Isn  : 332\n\n2018/10/10 12:59:14 Adabas Administration RESTful client took 102.136227ms terminated\n```\n\n## Parameter usage example\n\nYou may provide a parameter to perform special operations. For example, to set a new Adabas parameter, the parameter needs to be passed using the `-param` parameter. To list all current database on the Adabas server node use:\n\nDynamic parameters and input definitions are entered using the `-param` or `-input` options.\n\nExample to set new parameters in the static Adabas parameter definition:\n\n```sh\nclient -url adahost:8123 -dbid 24 -param type=static,PLOG=YES,NT=5 setparameter\n```\n\nThis example will set new Adabas static parameters for the database `24` on host `adahost` with port `8123`.\n\n## Create Adabas database\n\nTo create a new Adabas database, use an input file with the JSON definition of the new database. Environment variables will be resolved on the remote RESTful server.\n\n```JSON\n{\n    \"CheckpointFile\":1,\n    \"ContainerList\":[\n        {\"BlockSize\":\"8K\",\"ContainerSize\":\"20M\",\"Path\":\"${ADADATADIR/db075/ASSO1.075\"}, \n        {\"BlockSize\":\"32K\",\"ContainerSize\":\"20M\",\"Path\":\"${ADADATADIR}/db075/ASSO2.075\"},\n        {\"BlockSize\":\"32K\",\"ContainerSize\":\"20M\",\"Path\":\"${ADADATADIR}/db075/DATA1.075\"},\n        {\"BlockSize\":\"16K\",\"ContainerSize\":\"20M\",\"Path\":\"${ADADATADIR}/db075/WORK.075\"}\n    ],\n    \"Dbid\":75,\n    \"LoadDemo\":true,\n    \"Name\":\"DEMODB\",\n    \"SecurityFile\":2,\n    \"UserFile\":3\n}\n```\n\nThe corresponding JSON file needs to be referenced using the `-input` option.\n\n## Create Adabas file\n\nTo create a new Adabas file, use an input file with the JSON definition of the new Adabas file:\n\n```JSON\n{\n    \"fileNumber\":350,\n    \"fduOptions\":{\n        \"fduName\":\"GO_TEST\",\n    },\n    \"fdtDefinition\":\"1,AQ%2,AF,15,A,NU%1,NN,20,A,DE,UQ%1,VN,20,A,DE\"\n}\n\n```\n\nThe corresponding JSON file needs to be referenced using the `-input` option.\n______________________\nThese tools are provided as-is and without warranty or support. They do not constitute part of the Software AG product suite. Users are free to use, fork and modify them, subject to the license agreement. While Software AG welcomes contributions, we cannot guarantee to include every contribution in the master project.\n______________________\nFor more information you can Ask a Question in the [TECHcommunity Forums](https://tech.forums.softwareag.com/tags/c/forum/1/Adabas).\n\nYou can find additional information in the [Software AG TECHcommunity](https://tech.forums.softwareag.com/tag/Adabas).\n______________________\nContact us at [TECHcommunity](mailto:technologycommunity@softwareag.com?subject=Github/SoftwareAG) if you have any questions.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FSoftwareAG%2Fadabas-admin-restful-client","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FSoftwareAG%2Fadabas-admin-restful-client","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FSoftwareAG%2Fadabas-admin-restful-client/lists"}