[MAGNOLIA-1680] Exception thrown when samples module is not included Created: 14/Aug/07  Updated: 23/Jan/13  Resolved: 13/Oct/07

Status: Closed
Project: Magnolia
Component/s: None
Affects Version/s: None
Fix Version/s: 3.5 RC1

Type: Bug Priority: Major
Reporter: zam6ak Assignee: Magnolia International
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

3.1-SNAPSHOT
JBoss 4.0.5GA


Attachments: Text File missing-groups-exception.txt    
Issue Links:
dependency
depends upon MAGNOLIA-1164 Clean up default users/groups/roles Closed
duplicate
is duplicated by MAGNOLIA-1747 Missing group reported when starting ... Closed
relation
is related to MAGNOLIA-1164 Clean up default users/groups/roles Closed
Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Date of First Response:

 Description   

To reproduce:

  • package latest 3.1-SNAPSHOT
  • remove samples module
  • deploy
  • log into Admin instance
  • click on Inbox
    Exception is thrown (see attached) file

Cause:

The UUID refers to users.publishers.xml bootstrap file which is in samples module...
Of course, since I don't need samples module I have exculded it from build and and "publishers" and "editors" groups weren't created.
However these 2 groups are used by workflow module....

Workaround:

Import files manually...

Since these 2 bootrstrap files are tied to workflow, perhaps they should be part of the workflow module and not samples module?



 Comments   
Comment by Philipp Bracher [ 15/Aug/07 ]

they must go into the workflow module

Comment by Magnolia International [ 08/Oct/07 ]

I would suggest we fix this with MAGNOLIA-1164, i.e. having sample users with actual sample names (joe, nancy, ...) and group names which are also different from role names to avoid confusion.

Comment by zam6ak [ 09/Oct/07 ]

I agree with Gregory - current naming is a bit confusing...
Are these 2 issues hard to implement? Seems like just creating and moving some bootstrap files around....

Comment by Magnolia International [ 09/Oct/07 ]

and reaching a conclusion on where we put those and what modules depend on which. having the groups in the wf module and the users in the sample modules would mean we'd need a dependency on wf from the sample modules, while we're trying to make the wf module as optional as possible. yuk.

Comment by zam6ak [ 09/Oct/07 ]

WF module will not function properly without 2 group bootstrap files.
In my opinion WF module is "more core" than samples module...Samples module contains "sample" users (not talking about superuser and anonymous...).

However I do agree that both modules should be optional and independent of each other. But how do you accomplish that when their functionality "crosses over" each other?
Another option is to duplicate bootstrap files in both modules, but that is ugly....

I look at it from perspective of: "What is the likelihood of someone not needing workflow vs. samples module"? In production systems, some (like us) will choose not to install samples module, but rarely you will see people not installing workflow module...

Comment by Magnolia International [ 09/Oct/07 ]

True, but you could also consider the default workflow as a "sample". Indeed, the groups are needed by the default workflow definition, because said definition refers to them. If your production has custom workflow definition(s), then the relevance of these 2 specific groups is probably lower.
Does this call for separating sample content and sample/default "data" ?

Comment by zam6ak [ 09/Oct/07 ]

>Does this call for separating sample content and sample/default "data" ?
I think this would be "overkill". Also, if you separate sample "content" and sample "data" that would imply they would be independent, which they are probably not.

Another approach, to consider, is to add WEB-INF/bootstrap/default/ and drop common bootstrap files there (indicating the bootstrap files in this folder are common regardless of the type of installation). In case of our 2 groups, we can store those there and they would be installed regardless of WF or samples module. The only drawback would be if neither samples nor WF modules are installed (how often will this happen?) and even then user has option of deleting the groups after install (which an easier task than importing them manually)

Comment by Magnolia International [ 09/Oct/07 ]

> Also, if you separate sample "content" and sample "data" that would imply they would be independent, which they are probably not.
I'm not sure I'm following you, there.

Comment by zam6ak [ 09/Oct/07 ]

>> Also, if you separate sample "content" and sample "data" that would imply they would be independent, which they are probably not.
>I'm not sure I'm following you, there.

When you mentioned separating sample "content" and sample "data" I assumed you were talking about creating two separate samples modules (one for data and one for content), in which case they would depend on each other and you really would not be able to install one and the the other....

Comment by Magnolia International [ 09/Oct/07 ]

Why would they be dependent ?
One would have sample contents, paragraphs, etc; the other would have groups, sample users and default wf definition, for example.

Comment by zam6ak [ 09/Oct/07 ]

If you put groups bootstrap files in samples "data", we are back to "square one" - not installing samples "data' will break WF....
Ok, I misunderstod dependancy between samples "data" and samples "content" but it does not resolve issue with WF module now, does it?

Comment by Magnolia International [ 13/Oct/07 ]

Ok, so here's how I "fixed" this. Let me know what you think + if it solves your issues.

Sample module now has

  • users
  • bob
  • joe
  • melinda
  • groups
  • developers
  • employees
  • roles
  • base
  • developer
  • editor
  • securitymanager

Workflow module has

  • groups
  • editors
  • publishers

Joe and Melinda are assigned to the editors and publishers groups respectively upon installation of the workflow module, if the sample module is present in the system. (installed previously or being installed at the same time)

The defaut activation workflow definition was adapted to match the new group names. (plural form)

Generated at Mon Feb 12 03:29:16 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.