On Thu, Jul 17, 2025 at 1:47 PM Savinder Kaur <[email protected]> wrote:
> Hi Team , > > I am currently working on a feature enhancement for Apache Guacamole > (v1.5.5) and would appreciate your guidance. The requirement is to pass a > custom string field (e.g., uniqueString) from the frontend UI to the > backend and persist it in the Guacamole database using the native Java > backend*.* > Pass it where? For what purpose? What kind of data are you trying to pass and store? Is it related to users? Groups? Connections? Connection groups? How are you capturing it - is it something the user is inputting, or something you're gathering from the environment? Without knowing a lot of that information, I'd say the best way to do this is to make use of the "Attributes" supported by various Guacamole objects - for example, user attributes, group attributes, connection attributes, and connection group attributes. These are designed to be arbitrary and extensible - you can name the field whatever you like and store just about any type of data. In the database they are all stored as strings, which should work for you - if you want to do something else (number, boolean, etc.) you have to write the code to convert between string and your data type. I would like to understand the recommended approach and the flow to achieve > this while aligning with the architecture and design patterns followed in > the existing codebase. > What I am trying to do: > > - > > Capture a string field ( uniqueString ) from the UI. > - > > Pass it through the REST layer. > - > > Persist it in the database via the existing JDBC authentication > extension (MySQL). > - > > Follow the existing structure (e.g., how Connection, User, or History > entries are handled) ? > > My Question: > > REST to Backend: What is the cleanest way to pass this to the Java backend > while maintaining the decoupling between REST and JDBC layers? > While attempting to implement this, I ran into an issue where adding > guacamole-auth-jdbc as a dependency in the core guacamole module causes > conflicts—especially around transitive dependencies and service injection. > As per my understanding, the REST layer should not directly depend on JDBC. > I believe this might violate the current architecture where data access is > handled through UserContext, Directory, and associated factories but they > seem to be complex . > > This is sort of true - in general, the REST API for Guacamole is designed to be agnostic to the back-end used to store the connection and user data (LDAP, JDBC, JSON, etc.). That said, that are features that the REST API supports that are only supported with certain back-ends. You'll need to provide some more detail on exactly what you're trying to capture and use the data for. -Nick >
